|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.singularsys.jep.configurableparser.matchers.RegExpTokenMatcher
com.singularsys.jep.configurableparser.matchers.IdentifierTokenMatcher
public class IdentifierTokenMatcher
Matches identifiers: variables or function names.
| Constructor Summary | |
|---|---|
IdentifierTokenMatcher(java.util.regex.Pattern pattern)
|
|
IdentifierTokenMatcher(java.lang.String regex)
Construct and identifier matcher. |
|
| Method Summary | |
|---|---|
static IdentifierTokenMatcher |
basicIndetifierMatcher()
Matches identifiers which start with a letter or underscore and are followed by 0 or more letters digits or underscores. |
Token |
buildToken(java.lang.String s)
Create the token, if the name matches a function name return a FunctionToken otherwise return an IdentifierToken. |
static IdentifierTokenMatcher |
dottedIndetifierMatcher()
Matches identifiers which start with a letter or underscore and are followed by 0 or more letters digits or underscores or . characters. |
void |
init(Jep j)
Initialize the matcher when the Jep instance is known. |
| Methods inherited from class com.singularsys.jep.configurableparser.matchers.RegExpTokenMatcher |
|---|
match |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IdentifierTokenMatcher(java.util.regex.Pattern pattern)
public IdentifierTokenMatcher(java.lang.String regex)
regex - a regular expression specifying the allowed identifier names.Pattern| Method Detail |
|---|
public Token buildToken(java.lang.String s)
buildToken in interface TokenBuilderbuildToken in class RegExpTokenMatchers - String representing the completed matched token
public static IdentifierTokenMatcher basicIndetifierMatcher()
public static IdentifierTokenMatcher dottedIndetifierMatcher()
public void init(Jep j)
TokenMatcher
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||