|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ow2.opensuit.cel.impl.tree.impl.Scanner
public class Scanner
Handcrafted scanner.
| Nested Class Summary | |
|---|---|
static class |
Scanner.ExtensionToken
|
static class |
Scanner.ScanException
Scan exception type |
static class |
Scanner.Symbol
Symbol type |
static class |
Scanner.Token
|
| Field Summary | |
|---|---|
protected java.lang.StringBuilder |
builder
|
protected java.lang.String |
input
|
| Constructor Summary | |
|---|---|
protected |
Scanner(java.lang.String input)
Constructor. |
| Method Summary | |
|---|---|
protected Scanner.Token |
fixed(Scanner.Symbol symbol)
|
protected int |
getPosition()
|
protected Scanner.Token |
getToken()
|
protected boolean |
isDigit(char c)
|
protected boolean |
isEval()
|
protected Scanner.Token |
keyword(java.lang.String s)
|
Scanner.Token |
next()
Scan next token. |
protected Scanner.Token |
nextEval()
token inside an eval expression |
protected Scanner.Token |
nextNumber()
number token |
protected Scanner.Token |
nextString()
string token |
protected Scanner.Token |
nextText()
text token |
protected Scanner.Token |
nextToken()
|
protected Scanner.Token |
token(Scanner.Symbol symbol,
java.lang.String value,
int length)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final java.lang.String input
protected final java.lang.StringBuilder builder
| Constructor Detail |
|---|
protected Scanner(java.lang.String input)
input - expression string| Method Detail |
|---|
protected Scanner.Token getToken()
protected int getPosition()
protected boolean isDigit(char c)
true iff the specified character is a digitprotected Scanner.Token keyword(java.lang.String s)
s - name
nullprotected Scanner.Token fixed(Scanner.Symbol symbol)
symbol -
protected Scanner.Token token(Scanner.Symbol symbol,
java.lang.String value,
int length)
protected boolean isEval()
protected Scanner.Token nextText()
throws Scanner.ScanException
Scanner.ScanException
protected Scanner.Token nextString()
throws Scanner.ScanException
Scanner.ScanException
protected Scanner.Token nextNumber()
throws Scanner.ScanException
Scanner.ScanException
protected Scanner.Token nextEval()
throws Scanner.ScanException
Scanner.ScanException
protected Scanner.Token nextToken()
throws Scanner.ScanException
Scanner.ScanException
public Scanner.Token next()
throws Scanner.ScanException
getToken() and getPosition()
can be used to retreive the token's image and input position.
Scanner.ScanException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||