Class ValueTag
- java.lang.Object
-
- org.apache.commons.jelly.TagSupport
-
- net.sf.jguiraffe.gui.builder.di.tags.ValueTag
-
- All Implemented Interfaces:
org.apache.commons.jelly.Tag
public class ValueTag extends org.apache.commons.jelly.TagSupport
A tag handler class for defining a value.
This tag handler class can appear in the body of a tag implementing the
ValueSupport
interface. It evaluates its body, transforms it into a string, and passes the result to theValueSupport
tag.Typically tags producing a value (e.g.
ParameterTag
orSetPropertyTag
) allow setting the value through attributes. XML attributes however have some constraints. For instance, it is not possible to specify a string value with newline characters. BecauseValueTag
obtains the value from its body these restrictions do not apply here. So this tag can be used to define more complex values. The values are then passed to the parent tag.- Version:
- $Id: ValueTag.java 205 2012-01-29 18:29:57Z oheger $
- Author:
- Oliver Heger
-
-
Constructor Summary
Constructors Constructor Description ValueTag()
Creates a new instance ofValueTag
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
doTag(org.apache.commons.jelly.XMLOutput out)
Executes this tag.-
Methods inherited from class org.apache.commons.jelly.TagSupport
findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, findAncestorWithClass, getBody, getBodyText, getBodyText, getContext, getParent, invokeBody, isEscapeText, isTrim, setBody, setContext, setEscapeText, setParent, setTrim, trimBody
-
-
-
-
Method Detail
-
doTag
public void doTag(org.apache.commons.jelly.XMLOutput out) throws org.apache.commons.jelly.JellyTagException
Executes this tag. Obtains the parent tag (which must implement theValueSupport
interface) and passes the body of this tag to it as value.- Parameters:
out
- the output object- Throws:
org.apache.commons.jelly.JellyTagException
- if the tag is used incorrectly
-
-