ipipan.spejd.ruleparser
Class MatchParser

java.lang.Object
  extended by ipipan.spejd.ruleparser.MatchParser
Direct Known Subclasses:
ActionParser

public class MatchParser
extends java.lang.Object

Parser of match specifications.


Field Summary
protected  Config conf
           
 
Constructor Summary
MatchParser(java.io.BufferedReader in, Config conf)
           
MatchParser(Config conf)
           
 
Method Summary
 int attribute(java.lang.String s)
          Moved here from GroupRequirement to avoid "static" property because s can have multiple simultanegous instances
protected  boolean charsLeft()
           
protected  char currentChar()
           
protected  boolean currentCharIs(char c)
           
protected  boolean currentCharIsDigit()
           
protected  boolean currentCharIsIn(java.lang.String set)
           
protected  boolean currentCharNot(char c)
           
protected  boolean currentCharNotIn(java.lang.String set)
           
protected  boolean eat(java.lang.String expected, boolean eatWhite)
           
protected  void eatWhite()
           
protected  void error(java.lang.String desc)
           
protected  boolean feed()
           
protected  void forceEat(java.lang.String expected, boolean eatWhite)
           
protected  boolean preview(java.lang.String expected)
           
protected  AltRequirement readAltRequirement()
           
protected  int readAttrId()
           
protected  EntityRequirement readEntityRequirement()
           
protected  int readEqOperator()
           
protected  java.lang.String readFilename()
           
protected  int readFlags()
           
protected  GroupRequirement readGroupRequirement()
           
protected  java.lang.String readId()
           
 boolean readMacroDef()
           
protected  java.lang.String[] readMatchPattern(java.lang.String part, boolean required)
           
protected  int readNumber(boolean eatWhite)
           
protected  char readQuantifier()
           
protected  java.lang.String readRegexp()
           
protected  Requirement readRequirement()
           
protected  SequenceRequirement readSequenceRequirement()
           
protected  java.lang.String readString()
           
protected  java.lang.String readTag()
           
protected  TokenRequirement readTokenRequirement()
           
protected  java.lang.String readWord(java.lang.String nonLetterChars, boolean allowEmpty)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

conf

protected Config conf
Constructor Detail

MatchParser

public MatchParser(Config conf)

MatchParser

public MatchParser(java.io.BufferedReader in,
                   Config conf)
Method Detail

feed

protected boolean feed()

currentChar

protected char currentChar()

charsLeft

protected boolean charsLeft()

currentCharIs

protected boolean currentCharIs(char c)

currentCharNot

protected boolean currentCharNot(char c)

currentCharIsDigit

protected boolean currentCharIsDigit()

currentCharIsIn

protected boolean currentCharIsIn(java.lang.String set)

currentCharNotIn

protected boolean currentCharNotIn(java.lang.String set)

error

protected void error(java.lang.String desc)

eatWhite

protected void eatWhite()

preview

protected boolean preview(java.lang.String expected)

eat

protected boolean eat(java.lang.String expected,
                      boolean eatWhite)

forceEat

protected void forceEat(java.lang.String expected,
                        boolean eatWhite)

readWord

protected java.lang.String readWord(java.lang.String nonLetterChars,
                                    boolean allowEmpty)

readId

protected java.lang.String readId()

readAttrId

protected int readAttrId()

readTag

protected java.lang.String readTag()

readFilename

protected java.lang.String readFilename()

readRegexp

protected java.lang.String readRegexp()

readString

protected java.lang.String readString()

readFlags

protected int readFlags()

readNumber

protected int readNumber(boolean eatWhite)

readEqOperator

protected int readEqOperator()

readRequirement

protected Requirement readRequirement()

readTokenRequirement

protected TokenRequirement readTokenRequirement()

attribute

public int attribute(java.lang.String s)
Moved here from GroupRequirement to avoid "static" property because s can have multiple simultanegous instances

Parameters:
s -
Returns:

readGroupRequirement

protected GroupRequirement readGroupRequirement()

readEntityRequirement

protected EntityRequirement readEntityRequirement()

readQuantifier

protected char readQuantifier()

readSequenceRequirement

protected SequenceRequirement readSequenceRequirement()

readAltRequirement

protected AltRequirement readAltRequirement()

readMatchPattern

protected java.lang.String[] readMatchPattern(java.lang.String part,
                                              boolean required)

readMacroDef

public boolean readMacroDef()