public class TokenFactory extends Object
Tokens can be instantiated from an expression which is specific to each token.
TokenLiteral,
TokenVariable,
TokenOperatorD3,
TokenOperatorPS| Modifier and Type | Class and Description |
|---|---|
static class |
TokenFactory.Syntax
A syntax to use for creating tokens.
|
| Modifier and Type | Method and Description |
|---|---|
static TokenFactory |
getInstance()
Returns a token factory instance using the default syntax (DRAFTX).
|
static TokenFactory |
getInstance(TokenFactory.Syntax syntax)
Returns a token factory instance.
|
Token |
newToken(String exp)
Generates the token corresponding to the specified expression.
|
static Token |
newToken(String exp,
TokenFactory.Syntax syntax)
Generates the token corresponding to the specified expression.
|
public Token newToken(String exp)
exp - The expression.URITemplateSyntaxException - If the expression could not be parsed as a valid token.public static Token newToken(String exp, TokenFactory.Syntax syntax)
exp - The expression.URITemplateSyntaxException - If the expression could not be parsed as a valid token.public static TokenFactory getInstance()
public static TokenFactory getInstance(TokenFactory.Syntax syntax)
Copyright © 2021. All rights reserved.