Name
TagData Class
Class name:
javax.servlet.jsp.tagext.TagData
Extends:
None
Implements:
Cloneable
Implemented by:
Internal container-dependent class. Most containers use the reference implementation of the class (developed in the Apache Jakarta project).
Description
TagData
instances are created by the web container
during the translation phase. They provide information about the
attribute values specified for a custom action to the
TagExtraInfo
subclass for the corresponding tag
handler, if any.
Constructors
-
public TagData(Object[][] atts)
Creates a new instance with the attribute name/value pairs specified by the
Object[][]
. Element 0 of eachObject[]
contains the name; element 1 contains the value orREQUEST_TIME_VALUE
(if the attribute value is defined as a request-time value, or JSP expression).-
public TagData(java.util.Hashtable attrs)
Creates a new instance with the attribute name/value pairs specified by the
Hashtable
.
Methods
-
public Object getAttribute(String attName)
Returns the specified attribute value as a
String
or as theREQUEST_TIME_VALUE
object (if the attribute value is defined as a request-time value, or JSP expression).-
public String getAttributeString(String attName)
Returns the specified attribute value as a
String
. AClassCastException
is thrown if the attribute value is defined as a request-time value (a JSP expression).-
public String getId()
Returns the attribute named
id
as aString
, ornull
if it is not found.-
public void setAttribute(String attName, ...
Get JavaServer Pages Pocket Reference now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.