Class Filter
java.lang.Object
org.apache.uima.collection.impl.cpm.utils.Filter
Parses the filter expression associated with a Cas Processor in the cpe descriptor.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclass
Object containing single filter.class
Left part of filter expression.class
Operand.class
Right part of the filter expression. -
Field Summary
FieldsModifier and TypeFieldDescription(package private) LinkedList
The expression list.protected boolean
The filter initialized.protected boolean
The is and filter.protected boolean
The is or filter.(package private) Stack
The stack. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate void
Builds filter expression from values from the stack.static void
The main method.Parses filter expression.private void
parseTokens
(StringTokenizer aTokenizer) Parses tokens.
-
Field Details
-
stack
Stack stackThe stack. -
expressionList
LinkedList expressionListThe expression list. -
isAndFilter
protected boolean isAndFilterThe is and filter. -
isOrFilter
protected boolean isOrFilterThe is or filter. -
filterInitialized
protected boolean filterInitializedThe filter initialized.
-
-
Constructor Details
-
Filter
public Filter()
-
-
Method Details
-
parse
Parses filter expression.- Parameters:
expression
- - filter expression to parse- Returns:
- - list of filters
- Throws:
ParseException
- -
-
parseTokens
Parses tokens.- Parameters:
aTokenizer
- - tokenized filter expression- Throws:
ParseException
- -
-
evaluate
Builds filter expression from values from the stack.- Parameters:
anOp
- the an op- Throws:
ParseException
- -
-
main
The main method.- Parameters:
args
- the arguments
-