org.mmbase.bridge.jsp.taglib
Class FormatterTag
java.lang.Object
|
+--javax.servlet.jsp.tagext.TagSupport
|
+--javax.servlet.jsp.tagext.BodyTagSupport
|
+--org.mmbase.bridge.jsp.taglib.ContextReferrerTag
|
+--org.mmbase.bridge.jsp.taglib.FormatterTag
- All Implemented Interfaces:
- javax.servlet.jsp.tagext.BodyTag, javax.servlet.jsp.tagext.IterationTag, java.io.Serializable, javax.servlet.jsp.tagext.Tag, Writer
- public class FormatterTag
- extends ContextReferrerTag
- implements Writer
The formatter can reformat its body. It usually uses XSL for this.
- Since:
- MMBase-1.6
- Author:
- Michiel Meeuwissen
- See Also:
- Serialized Form
| Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport |
bodyContent |
| Fields inherited from class javax.servlet.jsp.tagext.TagSupport |
id, pageContext |
| Fields inherited from interface javax.servlet.jsp.tagext.BodyTag |
EVAL_BODY_BUFFERED, EVAL_BODY_TAG |
| Fields inherited from interface javax.servlet.jsp.tagext.IterationTag |
EVAL_BODY_AGAIN |
| Fields inherited from interface javax.servlet.jsp.tagext.Tag |
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE |
|
Method Summary |
int |
doAfterBody()
|
int |
doEndTag()
|
int |
doStartTag()
|
Generator |
getGenerator()
Subtags can write themselves as XML to the DOM document of this
tag. |
java.lang.Object |
getWriterValue()
Subtags of 'Writer' tag can request the value. |
void |
haveBody()
To be used by child tags. |
void |
setFormat(java.lang.String f)
Predefined formattings. |
void |
setJspvar(java.lang.String j)
JspVar to Create, and write to |
void |
setOptions(java.lang.String o)
The 'options' attribute can be used to provide option to the transformation to be done |
void |
setPageContext(javax.servlet.jsp.PageContext pageContext)
|
void |
setVartype(java.lang.String t)
Type of the jspvar. |
void |
setWants(java.lang.String w)
|
void |
setWrite(java.lang.String w)
Wether to write to page or not. |
void |
setXslt(java.lang.String x)
You can give the path the the XSLT-file by this attribute. |
void |
setXsltSource(javax.xml.transform.Source xs)
The Xslt tag will call this, to inform this tag about the XSLT which must be done. |
boolean |
wantXML()
Subtags need to know how they must communicate there content to
this tag. |
| Methods inherited from class org.mmbase.bridge.jsp.taglib.ContextReferrerTag |
findParentTag, findParentTag, findWriter, findWriter, getAttributeBoolean, getAttributeInteger, getAttributeInteger, getAttributeValue, getContextTag, getObject, getReferid, getString, release, setContext, setReferid, setWriter |
| Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport |
doInitBody, getBodyContent, getPreviousOut, setBodyContent |
| Methods inherited from class javax.servlet.jsp.tagext.TagSupport |
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setParent, setValue |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.servlet.jsp.tagext.Tag |
getParent, setParent |
helper
protected WriterHelper helper
xslt
protected java.lang.String xslt
format
protected int format
options
protected java.lang.String options
wants
protected int wants
xsltSource
protected javax.xml.transform.Source xsltSource
timerHandle
protected int timerHandle
- A handle necessary when using the Timer Tag;
FormatterTag
public FormatterTag()
setVartype
public void setVartype(java.lang.String t)
throws javax.servlet.jsp.JspTagException
- Description copied from interface:
Writer
- Type of the jspvar.
- Specified by:
setVartype in interface Writer
setJspvar
public void setJspvar(java.lang.String j)
- Description copied from interface:
Writer
- JspVar to Create, and write to
- Specified by:
setJspvar in interface Writer
setWrite
public void setWrite(java.lang.String w)
throws javax.servlet.jsp.JspTagException
- Description copied from interface:
Writer
- Wether to write to page or not. This has to default to 'false'
if the tag has a body, and to 'true' if it hasn't.
- Specified by:
setWrite in interface Writer
getWriterValue
public java.lang.Object getWriterValue()
throws javax.servlet.jsp.JspTagException
- Description copied from interface:
Writer
- Subtags of 'Writer' tag can request the value.
- Specified by:
getWriterValue in interface Writer
haveBody
public void haveBody()
- Description copied from interface:
Writer
- To be used by child tags. If they are present, they say to the
writer tag that it has body, which it can use to determine a
default for the write property.
- Specified by:
haveBody in interface Writer
setXslt
public void setXslt(java.lang.String x)
throws javax.servlet.jsp.JspTagException
- You can give the path the the XSLT-file by this attribute.
setFormat
public void setFormat(java.lang.String f)
throws javax.servlet.jsp.JspTagException
- Predefined formattings.
setOptions
public void setOptions(java.lang.String o)
throws javax.servlet.jsp.JspTagException
- The 'options' attribute can be used to provide option to the transformation to be done
setWants
public void setWants(java.lang.String w)
throws javax.servlet.jsp.JspTagException
setXsltSource
public void setXsltSource(javax.xml.transform.Source xs)
- The Xslt tag will call this, to inform this tag about the XSLT which must be done.
getGenerator
public Generator getGenerator()
- Subtags can write themselves as XML to the DOM document of this
tag. This functions returns this document.
wantXML
public final boolean wantXML()
- Subtags need to know how they must communicate there content to
this tag. If wantXML evaluates false, they must simply write to
the page, and formatter will pick it up.
setPageContext
public void setPageContext(javax.servlet.jsp.PageContext pageContext)
- Overrides:
setPageContext in class ContextReferrerTag
doStartTag
public int doStartTag()
throws javax.servlet.jsp.JspTagException
- Overrides:
doStartTag in class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody
public int doAfterBody()
throws javax.servlet.jsp.JspException
- Overrides:
doAfterBody in class javax.servlet.jsp.tagext.BodyTagSupport
doEndTag
public int doEndTag()
throws javax.servlet.jsp.JspTagException
- Overrides:
doEndTag in class javax.servlet.jsp.tagext.BodyTagSupport
MMBase build 1.6.5.20030923