xdoclet.tagshandler
Class IdTagsHandler
java.lang.Object
xdoclet.template.TemplateTagHandler
xdoclet.XDocletTagSupport
xdoclet.tagshandler.IdTagsHandler
- public class IdTagsHandler
- extends XDocletTagSupport
- Version:
- $Revision: 1.8 $
- Author:
- Ara Abrahamian (ara_e@email.com)
- xdoclet.taghandler
- namespace="Id"
- created
- Oct 15, 2001
Method Summary |
String |
id(Properties attributes)
Generates an id attribute based on the given tag values. |
String |
prefixedId(Properties attributes)
Generates an id attribute based on the given prefix. |
static void |
reset()
Resets the hashtable which backs the prefixId tag. |
Methods inherited from class xdoclet.XDocletTagSupport |
delimit, expandClassName, generate, getCurrentClass, getCurrentClassTag, getCurrentConstructor, getCurrentField, getCurrentFieldTag, getCurrentMethod, getCurrentMethodTag, getCurrentPackage, getDocletContext, getEngine, getExpandedDelimitedTagValue, getTagValue, getTagValue, getTagValue, hasTag, isTagValueEqual, mandatoryParamNotFound, mandatoryTemplateTagParamNotFound, modifiers, popCurrentClass, pushCurrentClass, setCurrentClass, setCurrentClassTag, setCurrentConstructor, setCurrentField, setCurrentFieldTag, setCurrentMethod, setCurrentMethodTag, setCurrentPackage |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
IdTagsHandler
public IdTagsHandler()
reset
public static void reset()
- Resets the hashtable which backs the prefixId tag.
prefixedId
public String prefixedId(Properties attributes)
throws XDocletException
- Generates an id attribute based on the given prefix. This is used for generating id attribute for XML elements.
- Parameters:
attributes
- The attributes of the template tag
- Returns:
- An id in the form of <prefix>_<num>
- Throws:
XDocletException
- Description of Exception- doc.tag
- type="content"
- doc.param
- name="prefix" optional="false" description="The tag from which the value of the id
is calculated."
id
public String id(Properties attributes)
throws XDocletException
- Generates an id attribute based on the given tag values. This is used for generating id attribute for XML
elements.
- Parameters:
attributes
- The attributes of the template tag
- Returns:
- Description of the Returned Value
- Throws:
XDocletException
- Description of Exception- doc.tag
- type="content"
- doc.param
- name="tagName" optional="false" description="The tag from which the value of the id
is calculated.", name="paramNames" optional="false" description="Comma separated list of parameter
names. The list is ordered, preferred param is before another param which is less important. If the param
exists, its value is taken and used as the id value."