Package javax.servlet.jsp.tagext
Class TagInfo
- java.lang.Object
-
- javax.servlet.jsp.tagext.TagInfo
-
public class TagInfo extends java.lang.Object
Tag information for a tag in a Tag Library; this class is instantiated from the Tag Library Descriptor file (TLD).
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
BODY_CONTENT_EMPTY
static constant for getBodyContent() when it is emptystatic java.lang.String
BODY_CONTENT_JSP
static constant for getBodyContent() when it is JSPstatic java.lang.String
BODY_CONTENT_TAG_DEPENDENT
static constant for getBodyContent() when it is Tag dependent
-
Constructor Summary
Constructors Constructor Description TagInfo(java.lang.String tagName, java.lang.String tagClassName, java.lang.String bodycontent, java.lang.String infoString, TagLibraryInfo taglib, TagExtraInfo tagExtraInfo, TagAttributeInfo[] attributeInfo)
Constructor for TagInfo.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TagAttributeInfo[]
getAttributes()
A null return means no information on attributesjava.lang.String
getBodyContent()
java.lang.String
getInfoString()
java.lang.String
getTagClassName()
Name of the class that provides the (run-time handler for this tagTagExtraInfo
getTagExtraInfo()
The instance (if any) for extra tag informationTagLibraryInfo
getTagLibrary()
java.lang.String
getTagName()
Tag nameVariableInfo[]
getVariableInfo(TagData data)
Information on the object created by this tag at runtime.boolean
isValid(TagData data)
Translation-time validation of the attributes.java.lang.String
toString()
Stringify for debug purposes...
-
-
-
Field Detail
-
BODY_CONTENT_JSP
public static final java.lang.String BODY_CONTENT_JSP
static constant for getBodyContent() when it is JSP- See Also:
- Constant Field Values
-
BODY_CONTENT_TAG_DEPENDENT
public static final java.lang.String BODY_CONTENT_TAG_DEPENDENT
static constant for getBodyContent() when it is Tag dependent- See Also:
- Constant Field Values
-
BODY_CONTENT_EMPTY
public static final java.lang.String BODY_CONTENT_EMPTY
static constant for getBodyContent() when it is empty- See Also:
- Constant Field Values
-
-
Constructor Detail
-
TagInfo
public TagInfo(java.lang.String tagName, java.lang.String tagClassName, java.lang.String bodycontent, java.lang.String infoString, TagLibraryInfo taglib, TagExtraInfo tagExtraInfo, TagAttributeInfo[] attributeInfo)
Constructor for TagInfo. No public constructor; this class is to be instantiated only from the TagLibrary code under request from some JSP code that is parsing a TLD (Tag Library Descriptor).- Parameters:
tagName
- The name of this tagtagClassName
- The name of the tag handler classbodycontent
- Information on the body content of these tagsinfoString
- The (optional) string information for this tagtaglib
- The instance of the tag library that contains us.tagExtraInfo
- The instance providing extra Tag info. May be nullattributeInfo
- An array of AttributeInfo data from descriptor. May be null;
-
-
Method Detail
-
getTagName
public java.lang.String getTagName()
Tag name
-
getAttributes
public TagAttributeInfo[] getAttributes()
A null return means no information on attributes
-
getVariableInfo
public VariableInfo[] getVariableInfo(TagData data)
Information on the object created by this tag at runtime. Null means no such object created. Default is null if the tag has no "id" attribute, otherwise, {"id", Object}
-
isValid
public boolean isValid(TagData data)
Translation-time validation of the attributes. The argument is a translation-time, so request-time attributes are indicated as such.- Parameters:
data
- The translation-time TagData instance.
-
getTagExtraInfo
public TagExtraInfo getTagExtraInfo()
The instance (if any) for extra tag information
-
getTagClassName
public java.lang.String getTagClassName()
Name of the class that provides the (run-time handler for this tag
-
getBodyContent
public java.lang.String getBodyContent()
- Returns:
- the body content (hint) string
-
getInfoString
public java.lang.String getInfoString()
- Returns:
- the info string
-
getTagLibrary
public TagLibraryInfo getTagLibrary()
- Returns:
- the tab library instance we belong to
-
toString
public java.lang.String toString()
Stringify for debug purposes...- Overrides:
toString
in classjava.lang.Object
-
-