net.sf.xmlmatcher.rex
Interface Position

All Known Implementing Classes:
AnyElementPosition, PositionImpl, TemplateElementPosition

public interface Position


Method Summary
 void addNext(Position sibling)
          Used by Glushkov graph builder to add sibling position that may *follow* this one in some valid input sequence
 org.w3c.dom.Element getElement()
           
 java.util.List<Position> getNextSiblings()
           
 boolean isFinal()
           
 boolean match(org.w3c.dom.Element symbol, Matcher comparer)
          Used during input sequence matching phase.
 void setFinal()
          Used by Glushkov graph builder to mark position as final
 

Method Detail

getNextSiblings

java.util.List<Position> getNextSiblings()
Returns:
set of sibling positions that may follow this position in some valid input sequence

addNext

void addNext(Position sibling)
Used by Glushkov graph builder to add sibling position that may *follow* this one in some valid input sequence


isFinal

boolean isFinal()
Returns:
true if this position may terminate sequence of siblings in some valid input sequence. (Derived from 'Last' set during Glushkov graph building phase.)

setFinal

void setFinal()
Used by Glushkov graph builder to mark position as final


match

boolean match(org.w3c.dom.Element symbol,
              Matcher comparer)
              throws InvalidTemplateException
Used during input sequence matching phase.

Returns:
true if this position accepts given symbol
Throws:
InvalidTemplateException

getElement

org.w3c.dom.Element getElement()
Returns:
Element of pattern DOM tree that corresponds to this position. Each position has an element, but some elements like xr:choice may not have corresponding position.


Copyright © 2007. All Rights Reserved.