EchoPoint
1.0

echopoint.ui.template.taghandlers
Class TextSubstitutionTagHandler

java.lang.Object
  extended byechopoint.ui.template.taghandlers.AbstractTagHandler
      extended byechopoint.ui.template.taghandlers.TextSubstitutionTagHandler
All Implemented Interfaces:
java.io.Serializable, TagHandler

public class TextSubstitutionTagHandler
extends AbstractTagHandler

This tag handler will replace "TEXT" tags with named values

See Also:
Serialized Form

Constructor Summary
TextSubstitutionTagHandler()
          TextSubstitutionTagHandler constructor.
 
Method Summary
 void executeTag(ParseContext context, PositionReader input, boolean parseTime)
          Looks for a Component associated with the name attribute, finds its Component Peer and then renders it into the template output.
 SGMLTag parseTag(CompilationContext context, PositionReader input, long startPosition, SGMLTag startTag)
          Parse tag.
 
Methods inherited from class echopoint.ui.template.taghandlers.AbstractTagHandler
getEndPos, getLineNumber, getNameProperty, getProperties, getStartPos, getTagLength, getTagStart, isTagClosedProperly, postParsePostProperties, postParsePreProperties, reportClosingTagError, reportError, reportNoComponentPeerError, setEndPos, setLineNumber, setName, setNameProperty, setProperties, setStartPos, setTagClosedProperly, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TextSubstitutionTagHandler

public TextSubstitutionTagHandler()
TextSubstitutionTagHandler constructor.

Method Detail

executeTag

public void executeTag(ParseContext context,
                       PositionReader input,
                       boolean parseTime)
                throws java.lang.Exception
Description copied from class: AbstractTagHandler
Looks for a Component associated with the name attribute, finds its Component Peer and then renders it into the template output.

Specified by:
executeTag in interface TagHandler
Overrides:
executeTag in class AbstractTagHandler
Throws:
java.lang.Exception
See Also:
TagHandler.executeTag(echopoint.ui.template.ParseContext, echopoint.ui.template.PositionReader, boolean)

parseTag

public SGMLTag parseTag(CompilationContext context,
                        PositionReader input,
                        long startPosition,
                        SGMLTag startTag)
                 throws java.io.IOException
Description copied from interface: TagHandler
Parse tag. This method is invoked if a tag with a name this class is registered for is found. The parseTag() method is called before any processing is done. Its purpose is to parse the area this tag spans and probably read in parameters used at execution time.

This method returns the last tag belonging to the area handled by this handler

. For simple one-tag Handlers this is simply the tag passed to this method. If the Handler decides not to handle this tag, this method should return null.

Parameters:
context - The CompilationContext involved
input - The PositionReader, located after the Name token of the Tag
startPosition - The Position parsing of this token began
startTag - the SGMLTag found in the file.
Throws:
java.io.IOException
See Also:
TagHandler.parseTag(echopoint.template.CompilationContext, echopoint.ui.template.PositionReader, long, echopoint.ui.template.SGMLTag)

EchoPoint
1.0