org.webmacro.parser
Class ParserBlockBuilder

java.lang.Object
  |
  +--org.webmacro.engine.BlockBuilder
        |
        +--org.webmacro.parser.ParserBlockBuilder
All Implemented Interfaces:
Builder

public class ParserBlockBuilder
extends BlockBuilder

ParserBlockBuilder extends BlockBuilder, and should only be used by the WMParser_impl parser. It adds methods for eating trailing or that precede directives. It assumes that literal text will not span elements (true for the current parser) so if the parser changes, this will need to change too.


Inner classes inherited from class org.webmacro.engine.BlockBuilder
BlockBuilder.BBIterator, BlockBuilder.BlockIterator
 
Constructor Summary
ParserBlockBuilder()
           
ParserBlockBuilder(java.lang.String name)
           
 
Method Summary
 boolean directiveOk()
           
 void eatLeadingWsNl()
           
 void eatOneWs()
           
 void eatTrailingWs()
           
 void eatTrailingWsNl()
           
 void eatTrailingWsNlWs()
           
 void markLiteral()
          Mark the last character in the block as being a literal (quoted with backslash) so we don't eat trailing quoted whitespace.
 
Methods inherited from class org.webmacro.engine.BlockBuilder
addElement, addElement, build, elementAt, remove, setElementAt, size
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ParserBlockBuilder

public ParserBlockBuilder()

ParserBlockBuilder

public ParserBlockBuilder(java.lang.String name)
Method Detail

markLiteral

public final void markLiteral()
Mark the last character in the block as being a literal (quoted with backslash) so we don't eat trailing quoted whitespace.

eatTrailingWs

public final void eatTrailingWs()

eatTrailingWsNl

public final void eatTrailingWsNl()

eatTrailingWsNlWs

public final void eatTrailingWsNlWs()

eatOneWs

public final void eatOneWs()

eatLeadingWsNl

public final void eatLeadingWsNl()

directiveOk

public final boolean directiveOk()