|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--openjava.syntax.AbstractSyntaxRule | +--openjava.syntax.TokenRule
The class TokenRule
represents the syntax
rule of a list separated by an separator.
Suppose there's a syntax rule A and token t. This class can represents the syntax A ( t A )*.
Object
Constructor Summary | |
TokenRule(int token_id)
Allocates a new rule representing a specified token. |
Method Summary | |
ParseTree |
consume(TokenSource token_src)
Consumes token source. |
Methods inherited from class openjava.syntax.AbstractSyntaxRule |
getSyntaxException,
lookahead |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public TokenRule(int token_id)
separator_token
- the id of a token.TokenID
Method Detail |
public final ParseTree consume(TokenSource token_src) throws SyntaxException
token_src
- token source.ObjectList
object.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |