Top Description Fields Constructors Methods
com.sun.faces.facelets.util

public Class FunctionLibrary

extends Object
implements TagLibrary
Class Inheritance
All Implemented Interfaces
com.sun.faces.facelets.tag.TagLibrary
Static Imports
com.sun.faces.util.Util.unmodifiableSet

This TagLibrary exposes the public static methods defined on the functionsClass provided to the constructor as EL functions.

Field Summary

Modifier and TypeField and Description
private String
public static final String
private Map<String, Method>
private static final String
private static final String
public static final Set<String>
private static final String

Constructor Summary

AccessConstructor and Description
public
FunctionLibrary(Class<?> functionsClass, String namespace)

Method Summary

Modifier and TypeMethod and Description
public boolean
containsFunction(String
namespace
ns
,
String
function name
name
)

Implements com.sun.faces.facelets.tag.TagLibrary.containsFunction.

If this library contains the specified function name

public boolean
containsNamespace(String
namespace
ns
,
Tag
the tag instance currently active at the time this method is called. May be null
t
)

Implements com.sun.faces.facelets.tag.TagLibrary.containsNamespace.

true if the namespace is used in this library

public boolean
containsTagHandler(String
namespace
ns
,
String
local name
localName
)

Implements com.sun.faces.facelets.tag.TagLibrary.containsTagHandler.

If this library contains a TagHandler for the namespace and local name true if handled by this library

public Method
createFunction(String
namespace
ns
,
String
function name
name
)

Implements com.sun.faces.facelets.tag.TagLibrary.createFunction.

Return a Method instance for the passed namespace and name

public TagHandler
createTagHandler(String
namespace
ns
,
String
local name
localName
,
TagConfig
configuration information
tag
)

Implements com.sun.faces.facelets.tag.TagLibrary.createTagHandler.

Create a new instance of a TagHandler, using the passed TagConfig

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

_namespaceback to summary
private String _namespace
DEFAULT_NAMESPACEback to summary
public static final String DEFAULT_NAMESPACE
functionsback to summary
private Map<String, Method> functions
JakartaNamespaceback to summary
private static final String JakartaNamespace
JcpNamespaceback to summary
private static final String JcpNamespace
NAMESPACESback to summary
public static final Set<String> NAMESPACES
SunNamespaceback to summary
private static final String SunNamespace

Constructor Detail

FunctionLibraryback to summary
public FunctionLibrary(Class<?> functionsClass, String namespace)

Method Detail

containsFunctionback to summary
public boolean containsFunction(String ns, String name)

Implements com.sun.faces.facelets.tag.TagLibrary.containsFunction.

Doc from com.sun.faces.facelets.tag.TagLibrary.containsFunction.

If this library contains the specified function name

Parameters
ns:String

namespace

name:String

function name

Returns:boolean

true if handled

Annotations
@Override
containsNamespaceback to summary
public boolean containsNamespace(String ns, Tag t)

Implements com.sun.faces.facelets.tag.TagLibrary.containsNamespace.

Doc from com.sun.faces.facelets.tag.TagLibrary.containsNamespace.

true if the namespace is used in this library

Parameters
ns:String

namespace

t:Tag

the tag instance currently active at the time this method is called. May be null

Returns:boolean

whether the namespace is used in this library

Annotations
@Override
containsTagHandlerback to summary
public boolean containsTagHandler(String ns, String localName)

Implements com.sun.faces.facelets.tag.TagLibrary.containsTagHandler.

Doc from com.sun.faces.facelets.tag.TagLibrary.containsTagHandler.

If this library contains a TagHandler for the namespace and local name true if handled by this library

Parameters
ns:String

namespace

localName:String

local name

Returns:boolean

whether handled by this library

Annotations
@Override
createFunctionback to summary
public Method createFunction(String ns, String name)

Implements com.sun.faces.facelets.tag.TagLibrary.createFunction.

Doc from com.sun.faces.facelets.tag.TagLibrary.createFunction.

Return a Method instance for the passed namespace and name

Parameters
ns:String

namespace

name:String

function name

Returns:Method

a Method instance for the passed namespace and name

Annotations
@Override
createTagHandlerback to summary
public TagHandler createTagHandler(String ns, String localName, TagConfig tag) throws FacesException

Implements com.sun.faces.facelets.tag.TagLibrary.createTagHandler.

Doc from com.sun.faces.facelets.tag.TagLibrary.createTagHandler.

Create a new instance of a TagHandler, using the passed TagConfig

Parameters
ns:String

namespace

localName:String

local name

tag:TagConfig

configuration information

Returns:TagHandler

a new TagHandler instance

Annotations
@Override
Exceptions
FacesException:
when a Faces exception occurs