org.mmbase.bridge.jsp.taglib
Class WriterHelper

java.lang.Object
  |
  +--org.mmbase.bridge.jsp.taglib.WriterHelper

public class WriterHelper
extends java.lang.Object

Tags that are Writers can use the this class. It's a pitty that they can't extend, but that's life.

Author:
Michiel Meeuwissen

Constructor Summary
WriterHelper()
           
 
Method Summary
 int doAfterBody()
          A basic afterbody for Writers.
 java.lang.String getJspvar()
           
protected  java.lang.String getPageString()
          Returns a string which can be written to the page.
 java.lang.Object getValue()
           
 int getVartype()
           
 boolean isWrite()
           
 void overrideWrite(boolean w)
          There is a default behavior for what should happen if the 'write' attribute is not set.
 void setBodyContent(javax.servlet.jsp.tagext.BodyContent b)
           
 void setJspvar(javax.servlet.jsp.PageContext pageContext)
          Don't forget to call 'setValue' first!
 void setJspvar(java.lang.String j)
           
 void setValue(java.lang.Object v)
           
 void setVartype(java.lang.String t)
           
 void setWrite(java.lang.Boolean w)
          For implementation of the write attribute.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WriterHelper

public WriterHelper()
Method Detail

setWrite

public void setWrite(java.lang.Boolean w)
For implementation of the write attribute.

overrideWrite

public void overrideWrite(boolean w)
There is a default behavior for what should happen if the 'write' attribute is not set. if you want to override this, then call this function.

isWrite

public boolean isWrite()

setJspvar

public void setJspvar(java.lang.String j)

getJspvar

public java.lang.String getJspvar()

setValue

public void setValue(java.lang.Object v)

setBodyContent

public void setBodyContent(javax.servlet.jsp.tagext.BodyContent b)

getValue

public java.lang.Object getValue()

setJspvar

public void setJspvar(javax.servlet.jsp.PageContext pageContext)
               throws javax.servlet.jsp.JspTagException
Don't forget to call 'setValue' first!

setVartype

public void setVartype(java.lang.String t)
                throws javax.servlet.jsp.JspTagException

getVartype

public int getVartype()

getPageString

protected java.lang.String getPageString()
                                  throws javax.servlet.jsp.JspTagException
Returns a string which can be written to the page.

doAfterBody

public int doAfterBody()
                throws javax.servlet.jsp.JspTagException
A basic afterbody for Writers. It decides if to write or not.


MMBase 2002