public class Tie extends Token
Token that specifies a token to be parsed inside the result of a
provided ValueExpression.
A Tie consists of a token (a Token) and a
dataExpression (a ValueExpression). First
dataExpression is evaluated. Then each value is used as an
input to parse the token in. Tie succeeds if all parses of
token in all results succeed. Tie fails if
dataExpression evaluates to a list of values that is either
empty or contains an invalid value.
ValueExpression| Modifier and Type | Field and Description |
|---|---|
ValueExpression |
dataExpression |
Token |
token |
| Constructor and Description |
|---|
Tie(String name,
Token token,
ValueExpression dataExpression,
Encoding encoding) |
| Modifier and Type | Method and Description |
|---|---|
protected ParseResult |
parseImpl(String scope,
Environment environment,
Encoding encoding) |
String |
toString() |
getCanonical, isLocal, makeNameFragment, parse, parsepublic final Token token
public final ValueExpression dataExpression
public Tie(String name, Token token, ValueExpression dataExpression, Encoding encoding)
protected ParseResult parseImpl(String scope, Environment environment, Encoding encoding) throws IOException
parseImpl in class TokenIOExceptionCopyright © 2017. All rights reserved.