public abstract class TerminalConsumer extends AbstractConsumer implements ITerminalConsumer
Modifier and Type | Field and Description |
---|---|
protected int |
SUCCESS |
Modifier | Constructor and Description |
---|---|
protected |
TerminalConsumer(ITerminalConsumerConfiguration configuration) |
Modifier and Type | Method and Description |
---|---|
int |
consume()
Scan the configured input source for a consumable terminal at the current offset.
|
int |
consume(ISequenceMatcher notMatching)
Scan the configured input source for a consumable terminal at the current offset.
|
int |
consume(java.lang.String feature,
boolean isMany,
boolean isBoolean,
AbstractElement element,
ISequenceMatcher notMatching,
boolean optional)
Scan the configured input source for a consumable terminal at the current offset.
|
protected AbstractParsedToken |
createParsedToken(java.lang.String feature,
boolean isMany,
boolean isBoolean,
AbstractElement element,
ISequenceMatcher notMatching,
boolean optional,
int prevMarker,
IParsedTokenSource source) |
protected abstract int |
doConsume() |
protected boolean |
eof() |
protected char |
getChar() |
abstract org.eclipse.emf.ecore.EObject |
getGrammarElement() |
protected abstract java.lang.String |
getRuleName() |
protected void |
incOffset() |
boolean |
isHidden() |
protected int |
mark() |
protected boolean |
peekChar(ICharacterClass characterClass) |
protected boolean |
readAnyChar(char... candidates) |
protected boolean |
readAnyChars(char... candidates) |
protected boolean |
readChar(char candidate) |
protected boolean |
readChar(ICharacterClass characterClass) |
protected boolean |
readCharBetween(char min,
char max) |
protected boolean |
readChars(char candidate) |
protected boolean |
readChars(ICharacterClass characterClass) |
protected boolean |
readCharsBetween(char min,
char max) |
protected boolean |
readString(java.lang.CharSequence seq) |
protected boolean |
readUntil(java.lang.CharSequence seq) |
protected void |
rollbackTo(int marker) |
void |
setHidden(boolean hidden) |
java.lang.String |
toString() |
getInput, getOffset, getTokenAcceptor
protected TerminalConsumer(ITerminalConsumerConfiguration configuration)
public final int consume(java.lang.String feature, boolean isMany, boolean isBoolean, AbstractElement element, ISequenceMatcher notMatching, boolean optional)
ITerminalConsumer
consume
in interface ITerminalConsumer
protected AbstractParsedToken createParsedToken(java.lang.String feature, boolean isMany, boolean isBoolean, AbstractElement element, ISequenceMatcher notMatching, boolean optional, int prevMarker, IParsedTokenSource source)
public final int consume()
ITerminalConsumer
consume
in interface ITerminalConsumer
public final int consume(ISequenceMatcher notMatching)
ITerminalConsumer
consume
in interface ITerminalConsumer
protected void incOffset()
protected boolean readAnyChar(char... candidates)
protected boolean readChar(char candidate)
protected boolean readChar(ICharacterClass characterClass)
protected char getChar()
protected boolean peekChar(ICharacterClass characterClass)
protected boolean readCharBetween(char min, char max)
protected boolean readAnyChars(char... candidates)
protected boolean readChars(char candidate)
protected boolean readChars(ICharacterClass characterClass)
protected boolean readCharsBetween(char min, char max)
protected boolean readString(java.lang.CharSequence seq)
protected boolean readUntil(java.lang.CharSequence seq)
protected abstract int doConsume()
public abstract org.eclipse.emf.ecore.EObject getGrammarElement()
protected abstract java.lang.String getRuleName()
public void setHidden(boolean hidden)
setHidden
in interface ITerminalConsumer
public boolean isHidden()
isHidden
in interface ITerminalConsumer
protected boolean eof()
protected int mark()
protected void rollbackTo(int marker)
public java.lang.String toString()
toString
in class java.lang.Object