|
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object jpicedt.format.input.util.AbstractRegularExpression jpicedt.format.input.util.SequenceExpression
public class SequenceExpression
An expression that represents a sequence of expressions to be matched exactly in the same order they're being added to the sequence.
Constructor Summary | |
---|---|
SequenceExpression()
constructs a sequence that contains no sub-expression and doesn't throw IncompleteSequenceException |
|
SequenceExpression(AbstractRegularExpression expr)
constructs a sequence with the given expression as the first sub-expression and which doesn't throw IncompleteSequenceException. |
|
SequenceExpression(AbstractRegularExpression expr1,
AbstractRegularExpression expr2)
constructs a sequence with the given expression as the first and second sub-expression and which doesn't throw Exception |
|
SequenceExpression(AbstractRegularExpression expr1,
AbstractRegularExpression expr2,
AbstractRegularExpression expr3,
boolean throwIncompleteSequenceException)
constructs a sequence with three sub-expressions |
|
SequenceExpression(AbstractRegularExpression expr1,
AbstractRegularExpression expr2,
boolean throwIncompleteSequenceException)
constructs a sequence with the given expression as the first and second sub-expression |
|
SequenceExpression(AbstractRegularExpression expr,
boolean throwIncompleteSequenceException)
constructs a sequence with the given expression as the first sub-expression. |
|
SequenceExpression(boolean throwIncompleteSequenceException)
constructs a sequence that contains no sub-expression. |
Method Summary | |
---|---|
void |
add(AbstractRegularExpression expr)
add the given expression to the sequence |
boolean |
interpret(Context c)
Parses this expression, possibly using the given Context to fetch the String to interpret if this Expression is a leaf expression. |
String |
toString()
|
Methods inherited from class jpicedt.format.input.util.AbstractRegularExpression |
---|
action |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public SequenceExpression()
public SequenceExpression(boolean throwIncompleteSequenceException)
throwIncompleteSequenceException
- if TRUE, and if the first sub-expression has been found but
any ensuing expression hasn't been found, throw a REParserException.IncompleteSequenceException.public SequenceExpression(AbstractRegularExpression expr)
public SequenceExpression(AbstractRegularExpression expr, boolean throwIncompleteSequenceException)
throwIncompleteSequenceException
- if TRUE, and if the first sub-expression has been found but
any ensuing sub-expression hasn't been found, throw a REParserException.IncompleteSequenceException.public SequenceExpression(AbstractRegularExpression expr1, AbstractRegularExpression expr2)
public SequenceExpression(AbstractRegularExpression expr1, AbstractRegularExpression expr2, boolean throwIncompleteSequenceException)
throwIncompleteSequenceException
- if TRUE, and if the first sub-expression has been found but
any ensuing sub-expression hasn't been found, throw a REParserException.IncompleteSequenceException.public SequenceExpression(AbstractRegularExpression expr1, AbstractRegularExpression expr2, AbstractRegularExpression expr3, boolean throwIncompleteSequenceException)
throwIncompleteSequenceException
- if TRUE, and if the first sub-expression has been found but
any ensuing sub-expression hasn't been found, throw a REParserException.IncompleteSequenceException.Method Detail |
---|
public void add(AbstractRegularExpression expr)
public boolean interpret(Context c) throws REParserException
AbstractRegularExpression
interpret
in class AbstractRegularExpression
REParserException.IncompleteSequence
- if flag throwIncompleteSequenceException is TRUE
and any expression but the first one wasn't found
Whether TRUE or FALSE, calls action with key="&" and value=new Integer(index of last expression
parsed with success)
REParserException
- if an error occur during parsingpublic String toString()
toString
in class Object
|
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |