|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Parser
This defines the MillScript parser interface.
| Field Summary | |
|---|---|
static int |
ARITH_PREC
Constant value for arithmetic precedence. |
static int |
COMMA_PREC
Constant value for comma precedence. |
static int |
COMMA_PREC1
Constant value for slightly tighter than comma precedence. |
static int |
LOW_PREC
Constant value for low precedence. |
static int |
NOT_PREC
Constant value for not syntax precedence. |
static int |
RELOP_PREC
Constant value for relation operator precedence. |
static int |
TIGHT_PREC
Constant value for tight precedence. |
| Method Summary | |
|---|---|
NameExpr |
getEnclosingClass()
Returns the enclosing class for this parser. |
Expr |
makeInterpolatedExpr()
Returns the current string, as an application of the format function with the current interpolation map values as arguments. |
java.lang.String |
readAttributeName()
Reads the next token from the source as an attribute name and returns it. |
Expr |
readBlock()
Reads a sequence of expressions from the source as a Block. |
Expr |
readBlockTo(java.lang.String sym)
Reads a sequence of expressions, followed by the specified symbol, from the source as a Block. |
Expr |
readExpr()
Reads the next expression from the source. |
Expr |
readExprComma()
Reads the next expression from the source at the COMMA_PREC1 precedence level. |
Expr |
readExprPrec(int prec)
Reads the next expression from the source at the specified precedence level. |
Expr |
readExprTo(java.lang.String sym)
Reads the next expression from the source, which must be followed by the specified symbol. |
NameExpr |
readName()
Reads the next token from the source as a name and returns a name expression for it. |
Expr |
readOptExpr()
Reads the optional next expression from the source. |
Expr |
readOptExprPrec(int prec)
Reads the optional next expression from the source at the specified precedence level. |
Expr |
readOptPrimary()
Reads the next token from the source as the optional primary expression in a potential sequence of expressions. |
Expr |
readPrimary()
Reads the next token from the source as the primary expression in a potential sequence of expressions. |
Expr |
readStmnts()
Reads a sequence of expressions from the source. |
Expr |
readStmntsTo(java.lang.String sym)
Reads a sequence of expressions from the source, which must be followed by the specified symbol. |
java.lang.String |
readSymbol()
Reads the next token from the source as a symbol and returns it. |
java.lang.String |
readTagName()
Reads the next token from the source as a tag name and returns it. |
| Methods inherited from interface org.millscript.millscript.syntax.Tokenizer |
|---|
checkWhere, dropToken, getAttributeName, getErrorString, getInt, getLineNumber, getName, getOrigin, getQuoteChar, getString, getStringNoQuotes, getStringNoQuotes, getTagName, makePattern, markReader, mustRead, nextToken, peekRead, peekToken, resetReader, setWhere, tryRead |
| Methods inherited from interface org.millscript.commons.alert.AlertOrigin |
|---|
setContext, setLineNumber, setOrigin |
| Field Detail |
|---|
static final int LOW_PREC
static final int COMMA_PREC
static final int COMMA_PREC1
static final int RELOP_PREC
static final int NOT_PREC
static final int ARITH_PREC
static final int TIGHT_PREC
| Method Detail |
|---|
NameExpr getEnclosingClass()
Expr makeInterpolatedExpr()
TokenizerImpl.interpolationMap,
FormatFunctionjava.lang.String readAttributeName()
Expr readBlock()
readStmnts()Expr readBlockTo(java.lang.String sym)
sym - the symbol which must follow the block
readStmntsTo(String)Expr readExpr()
Expr readExprComma()
COMMA_PREC1 precedence level. Hence this will read up to
the next comma.
Expr readExprPrec(int prec)
prec - the precedence level to read the next expression at
Expr readExprTo(java.lang.String sym)
sym - the symbol which must follow the expression
NameExpr readName()
Expr readOptExpr()
Expr readOptExprPrec(int prec)
prec - the precedence level to read the next expression at
Expr readOptPrimary()
Expr readPrimary()
Expr readStmnts()
Expr readStmntsTo(java.lang.String sym)
sym - the symbol which must follow the statements
readStmnts()java.lang.String readSymbol()
java.lang.String readTagName()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||