Package org.apache.commons.jelly
Class DynaBeanTagSupport
java.lang.Object
org.apache.commons.jelly.TagSupport
org.apache.commons.jelly.DynaTagSupport
org.apache.commons.jelly.DynaBeanTagSupport
- Direct Known Subclasses:
DynamicBeanTag,DynamicDynaBeanTag
DynaBeanTag is a DynaTag implementation which uses a DynaBean
to store its attribute values in. Derived tags can then process this
DynaBean in any way it wishes.
- Version:
- $Revision: 155420 $
- Author:
- James Strachan
-
Field Summary
Fields inherited from class org.apache.commons.jelly.TagSupport
body, context, parent -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCallback to allow processing to occur before the attributes are about to be setgetAttributeType(String name) org.apache.commons.beanutils.DynaBeanvoidsetAttribute(String name, Object value) Sets an attribute value of this tag before the tag is invokedvoidsetContext(JellyContext context) Sets the context in which the tag will be run.voidsetDynaBean(org.apache.commons.beanutils.DynaBean dynaBean) Sets the DynaBean which is used to store the attributes of this tagMethods inherited from class org.apache.commons.jelly.TagSupport
findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, getBody, getBodyText, getBodyText, getContext, getParent, invokeBody, isEscapeText, isTrim, setBody, setEscapeText, setParent, setTrim, trimBodyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.commons.jelly.Tag
doTag, getBody, getContext, getParent, invokeBody, setBody, setParent
-
Constructor Details
-
DynaBeanTagSupport
public DynaBeanTagSupport() -
DynaBeanTagSupport
public DynaBeanTagSupport(org.apache.commons.beanutils.DynaBean dynaBean)
-
-
Method Details
-
setContext
Sets the context in which the tag will be run.- Specified by:
setContextin interfaceTag- Overrides:
setContextin classTagSupport- Throws:
JellyTagException
-
setAttribute
Sets an attribute value of this tag before the tag is invoked- Throws:
JellyTagException
-
getAttributeType
- Specified by:
getAttributeTypein interfaceDynaTag- Overrides:
getAttributeTypein classDynaTagSupport- Returns:
- the type of the given attribute. By default just return Object.class if this is not known.
- Throws:
JellyTagException
-
getDynaBean
public org.apache.commons.beanutils.DynaBean getDynaBean()- Returns:
- the DynaBean which is used to store the attributes of this tag
-
setDynaBean
public void setDynaBean(org.apache.commons.beanutils.DynaBean dynaBean) Sets the DynaBean which is used to store the attributes of this tag -
beforeSetAttributes
Callback to allow processing to occur before the attributes are about to be set- Throws:
JellyTagException
-