public abstract class AbstractTagLibrary extends Object implements TagLibrary
Modifier and Type | Class and Description |
---|---|
protected static class |
AbstractTagLibrary.ComponentConfigWrapper |
Constructor and Description |
---|
AbstractTagLibrary(String namespace) |
Modifier and Type | Method and Description |
---|---|
protected void |
addBehavior(String name,
String behaviorId)
|
protected void |
addBehavior(String name,
String behaviorId,
Class type) |
protected void |
addComponent(String name,
String componentType,
String rendererType)
Add a ComponentHandlerImpl with the specified componentType and rendererType,
aliased by the tag name.
|
protected void |
addComponent(String name,
String componentType,
String rendererType,
Class handlerType)
Add a ComponentHandlerImpl with the specified componentType and rendererType,
aliased by the tag name.
|
protected void |
addCompositeComponentTag(String name,
String resourceId)
Add a CompositeComponentTagHandler for the specified resource.
|
protected void |
addConverter(String name,
String converterId)
Add a ConverterHandler for the specified converterId
|
protected void |
addConverter(String name,
String converterId,
Class type)
Add a ConverterHandler for the specified converterId of a TagHandler type
|
protected void |
addFunction(String name,
Method method)
Add a Method to be used as a Function at Compilation.
|
protected void |
addTagHandler(String name,
Class handlerType)
Use the specified HandlerType in compiling Facelets.
|
protected void |
addUserTag(String name,
URL source)
Add a UserTagHandler specified a the URL source.
|
protected void |
addValidator(String name,
String validatorId)
Add a ValidatorHandler for the specified validatorId
|
protected void |
addValidator(String name,
String validatorId,
Class type)
Add a ValidatorHandler for the specified validatorId
|
boolean |
containsFunction(String ns,
String name)
If this library contains the specified function name
|
boolean |
containsNamespace(String ns,
Tag t)
true if the namespace is used in this library
|
boolean |
containsTagHandler(String ns,
String localName)
If this library contains a TagHandler for the namespace and local name true if handled by this library
|
Method |
createFunction(String ns,
String name)
Return a Method instance for the passed namespace and name
|
TagHandler |
createTagHandler(String ns,
String localName,
TagConfig tag)
Create a new instance of a TagHandler, using the passed TagConfig
|
boolean |
equals(Object obj) |
String |
getNamespace() |
int |
hashCode() |
public AbstractTagLibrary(String namespace)
protected final void addComponent(String name, String componentType, String rendererType)
name
- name to use, "foo" would be <my:foo />componentType
- componentType to userendererType
- rendererType to useApplication.createComponent(java.lang.String)
protected final void addComponent(String name, String componentType, String rendererType, Class handlerType)
name
- name to use, "foo" would be <my:foo />componentType
- componentType to userendererType
- rendererType to usehandlerType
- a Class that extends ComponentHandlerprotected final void addConverter(String name, String converterId)
name
- name to use, "foo" would be <my:foo />converterId
- id to pass to Application instanceConverterHandler
,
Application.createConverter(java.lang.String)
protected final void addConverter(String name, String converterId, Class type)
name
- name to use, "foo" would be <my:foo />converterId
- id to pass to Application instancetype
- TagHandler type that takes in a ConverterConfigConverterHandler
,
ConverterConfig
,
Application.createConverter(java.lang.String)
protected final void addValidator(String name, String validatorId)
name
- name to use, "foo" would be <my:foo />validatorId
- id to pass to Application instanceValidatorHandler
,
Application.createValidator(java.lang.String)
protected final void addValidator(String name, String validatorId, Class type)
name
- name to use, "foo" would be <my:foo />validatorId
- id to pass to Application instancetype
- TagHandler type that takes in a ValidatorConfigValidatorHandler
,
ValidatorConfig
,
Application.createValidator(java.lang.String)
protected final void addBehavior(String name, String behaviorId)
name
- behaviorId
- protected final void addTagHandler(String name, Class handlerType)
name
- name to use, "foo" would be <my:foo />handlerType
- must extend TagHandlerTagHandler
protected final void addUserTag(String name, URL source)
name
- name to use, "foo" would be <my:foo />source
- source where the Facelet (Tag) source isUserTagHandler
protected final void addCompositeComponentTag(String name, String resourceId)
name
- name to use, "foo" would be <my:foo />resourceId
- source where the Facelet (Tag) source isUserTagHandler
protected final void addFunction(String name, Method method)
name
- (suffix) of function namemethod
- method instanceFunctionMapper
public boolean containsNamespace(String ns, Tag t)
TagLibrary
containsNamespace
in interface TagLibrary
ns
- namespacet
- the tag instance currently active at the time
this method is called. May be nullpublic boolean containsTagHandler(String ns, String localName)
TagLibrary
containsTagHandler
in interface TagLibrary
ns
- namespacelocalName
- local namepublic TagHandler createTagHandler(String ns, String localName, TagConfig tag) throws FacesException
TagLibrary
createTagHandler
in interface TagLibrary
ns
- namespacelocalName
- local nametag
- configuration informationFacesException
public boolean containsFunction(String ns, String name)
TagLibrary
containsFunction
in interface TagLibrary
ns
- namespacename
- function namepublic Method createFunction(String ns, String name)
TagLibrary
createFunction
in interface TagLibrary
ns
- namespacename
- function namepublic String getNamespace()
Comments to: faces-dev@eclipse.org.
Copyright © 2019 Eclipse Foundation. All rights reserved.
Use is subject to license terms.