public abstract class AbstractIDValueConverter extends AbstractLexerBasedConverter<String>
IValueConverter.RuleSpecificNO_OP_CONVERTER| Modifier | Constructor and Description |
|---|---|
protected |
AbstractIDValueConverter() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
assertValidValue(String value) |
protected Set<Character> |
collectInvalidCharacters(String value) |
protected abstract Set<String> |
computeValuesToEscape(Grammar grammar) |
protected ValueConverterException |
createTokenContentMismatchException(String value,
String escapedString,
org.antlr.runtime.Token token) |
protected IGrammarAccess |
getGrammarAccess() |
protected String |
getInvalidCharactersMessage(String value,
Set<Character> invalidChars) |
protected Set<String> |
getValuesToEscape() |
protected abstract boolean |
mustEscape(String value) |
void |
setGrammarAccess(IGrammarAccess grammarAccess) |
protected String |
toEscapedString(String value) |
String |
toValue(String string,
INode node)
Creates a value from the given input.
|
assertTokens, assertTokens, createTokenTypeMismatchException, getLexer, getLexerProvider, getRule, getRuleName, getRuleName, getTokenDefMap, getTokenDefProvider, getTokenSource, setLexerProvider, setRule, setTokenDefProvider, toStringprotected abstract boolean mustEscape(String value)
protected String toEscapedString(String value)
toEscapedString in class AbstractLexerBasedConverter<String>protected void assertValidValue(String value)
assertValidValue in class AbstractLexerBasedConverter<String>protected ValueConverterException createTokenContentMismatchException(String value, String escapedString, org.antlr.runtime.Token token)
createTokenContentMismatchException in class AbstractLexerBasedConverter<String>protected String getInvalidCharactersMessage(String value, Set<Character> invalidChars)
public String toValue(String string, INode node)
IValueConverterCreates a value from the given input. The input is conformant to a data type or terminal rule.
The given string
or node may be null but not both of them.
string - the string that was inferred from the node. Usually the node's text
but may be reduced to the parts of the node that are not
hidden.node - the parsed node including hidden parts.null.protected IGrammarAccess getGrammarAccess()
public void setGrammarAccess(IGrammarAccess grammarAccess)
Copyright © 2015. All Rights Reserved.