use of org.geotoolkit.cql.CQLParser.FilterOrExpressionContext in project geotoolkit by Geomatys.
the class CQL method compileFilterOrExpression.
private static Object compileFilterOrExpression(String cql) {
try {
// lexer splits input into tokens
final ANTLRInputStream input = new ANTLRInputStream(cql);
final TokenStream tokens = new CommonTokenStream(new CQLLexer(input));
// parser generates abstract syntax tree
final CQLParser parser = new CQLParser(tokens);
final FilterOrExpressionContext retfilter = parser.filterOrExpression();
return retfilter;
} catch (RecognitionException e) {
throw new IllegalStateException("Recognition exception is never thrown, only declared.");
}
}
Aggregations