net.ontopia.topicmaps.nav2.taglibs.output
Class BaseOutputProducingTag

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by net.ontopia.topicmaps.nav2.taglibs.output.BaseOutputProducingTag
All Implemented Interfaces:
Serializable, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, javax.servlet.jsp.tagext.Tag, OutputProducingTagIF
Direct Known Subclasses:
ContentTag, CountTag, LinkTag, LocatorTag, NameTag, ObjectIdTag, SymbolicIdTag, TopicMapIdTag

public abstract class BaseOutputProducingTag
extends javax.servlet.jsp.tagext.TagSupport
implements OutputProducingTagIF

INTERNAL: Abstract super-class of an Output-Producing Tag.

See Also:
Serialized Form

Field Summary
protected  ContextTag contextTag
           
protected  boolean escapeEntities
           
protected  int numberOfElements
           
protected  boolean suppressEmptyCollection
           
protected  String variableName
           
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
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
 
Constructor Summary
  BaseOutputProducingTag()
           
protected BaseOutputProducingTag(boolean escapeEntities, boolean suppressEmptyCollection)
           
 
Method Summary
 int doEndTag()
           
 int doStartTag()
          Process the start tag for this instance.
abstract  void generateOutput(javax.servlet.jsp.JspWriter out, Iterator iterator)
          INTERNAL: Generate information extracted from the input collection provided access by specified iterator.
protected  int getCollectionSize()
          INTERNAL: gets number of elements contained in processed input collection.
protected  void print2Writer(javax.servlet.jsp.JspWriter out, String string)
          INTERNAL: prints out string to specified JspWriter object with respect if the entities should be escaped.
 void release()
          reset the state of the Tag.
protected  void setEscapeEntities(boolean escapeEntities)
           
 void setOf(String variableName)
          tag attribute for setting the variable name of the input collection common to all subclasses.
protected  void setSuppressEmptyCollection(boolean suppressEmptyCollection)
           
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

contextTag

protected ContextTag contextTag

numberOfElements

protected int numberOfElements

escapeEntities

protected boolean escapeEntities

suppressEmptyCollection

protected boolean suppressEmptyCollection

variableName

protected String variableName
Constructor Detail

BaseOutputProducingTag

public BaseOutputProducingTag()

BaseOutputProducingTag

protected BaseOutputProducingTag(boolean escapeEntities,
                                 boolean suppressEmptyCollection)
Method Detail

setEscapeEntities

protected final void setEscapeEntities(boolean escapeEntities)

setSuppressEmptyCollection

protected final void setSuppressEmptyCollection(boolean suppressEmptyCollection)

doStartTag

public int doStartTag()
               throws javax.servlet.jsp.JspTagException
Process the start tag for this instance.

Specified by:
doStartTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doStartTag in class javax.servlet.jsp.tagext.TagSupport
Throws:
javax.servlet.jsp.JspTagException

doEndTag

public final int doEndTag()
Specified by:
doEndTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doEndTag in class javax.servlet.jsp.tagext.TagSupport

release

public void release()
reset the state of the Tag.

Specified by:
release in interface javax.servlet.jsp.tagext.Tag
Overrides:
release in class javax.servlet.jsp.tagext.TagSupport

generateOutput

public abstract void generateOutput(javax.servlet.jsp.JspWriter out,
                                    Iterator iterator)
                             throws javax.servlet.jsp.JspTagException,
                                    IOException
Description copied from interface: OutputProducingTagIF
INTERNAL: Generate information extracted from the input collection provided access by specified iterator. This is expected to be written to the JspWriter object.

Specified by:
generateOutput in interface OutputProducingTagIF
Throws:
javax.servlet.jsp.JspTagException
IOException

getCollectionSize

protected final int getCollectionSize()
INTERNAL: gets number of elements contained in processed input collection.


setOf

public final void setOf(String variableName)
tag attribute for setting the variable name of the input collection common to all subclasses.


print2Writer

protected final void print2Writer(javax.servlet.jsp.JspWriter out,
                                  String string)
                           throws IOException
INTERNAL: prints out string to specified JspWriter object with respect if the entities should be escaped.

Throws:
IOException


Copyright © 2000-2012 Ontopia.