This project has retired. For details please refer to its
Attic page.
QueryConditionProcessor xref
1/*2 * Licensed to the Apache Software Foundation (ASF) under one3 * or more contributor license agreements. See the NOTICE file4 * distributed with this work for additional information5 * regarding copyright ownership. The ASF licenses this file6 * to you under the Apache License, Version 2.0 (the7 * "License"); you may not use this file except in compliance8 * with the License. You may obtain a copy of the License at9 *10 * http://www.apache.org/licenses/LICENSE-2.011 *12 * Unless required by applicable law or agreed to in writing,13 * software distributed under the License is distributed on an14 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY15 * KIND, either express or implied. See the License for the16 * specific language governing permissions and limitations17 * under the License.18 */19package org.apache.chemistry.opencmis.inmemory.query;
2021import java.util.List;
2223import org.antlr.runtime.tree.Tree;
24import org.apache.chemistry.opencmis.server.support.query.PredicateWalkerBase;
2526/**27 * An interface used by the walker when traversing the AST from the grammar.28 * The interface consists of callback methods that are called when a rule29 * is processed (as part of the WHERE statement)30 * @author Jens31 *32 */33publicinterfaceQueryConditionProcessorextends PredicateWalkerBase {
3435void onStartProcessing(Tree whereNode);
36void onStopProcessing();
3738// Compare operators39void onEquals(Tree eqNode, Tree leftNode, Tree rightNode);
40void onNotEquals(Tree neNode, Tree leftNode, Tree rightNode);
41void onGreaterThan(Tree gtNode, Tree leftNode, Tree rightNode);
42void onGreaterOrEquals(Tree geNode, Tree leftNode, Tree rightNode);
43void onLessThan(Tree ltNode, Tree leftNode, Tree rightNode);
44void onLessOrEquals(Tree leqNode, Tree leftNode, Tree rightNode);
4546// Boolean operators47void onPreNot(Tree opNode, Tree leftNode);
48void onNot(Tree opNode, Tree leftNode);
49void onPostNot(Tree opNode, Tree leftNode);
50void onPreAnd(Tree opNode, Tree leftNode, Tree rightNode);
51void onAnd(Tree opNode, Tree leftNode, Tree rightNode);
52void onPostAnd(Tree opNode, Tree leftNode, Tree rightNode);
53void onPreOr(Tree opNode, Tree leftNode, Tree rightNode);
54void onOr(Tree opNode, Tree leftNode, Tree rightNode);
55void onPostOr(Tree opNode, Tree leftNode, Tree rightNode);
5657// Multi-value:58void onIn(Tree node, Tree colNode, Tree listNode);
59void onNotIn(Tree node, Tree colNode, Tree listNode);
60void onInAny(Tree node, Tree colNode, Tree listNode);
61void onNotInAny(Tree node, Tree colNode, Tree listNode);
62void onEqAny(Tree node, Tree literalNode, Tree colNode);
6364// Null comparisons:65void onIsNull(Tree nullNode, Tree colNode);
66void onIsNotNull(Tree notNullNode, Tree colNode);
6768// String matching:69void onIsLike(Tree node, Tree colNode, Tree stringNode);
70void onIsNotLike(Tree node, Tree colNode, Tree stringNode);
7172// Functions:73void onContains(Tree node, Tree typeNode, Tree searchExprNode);
74void onInFolder(Tree node, Tree colNode, Tree paramNode);
75void onInTree(Tree node, Tree colNode, Tree paramNode);
76void onScore(Tree node);
7778// full text search79void onTextAnd(Tree node, List<Tree> conjunctionNodes);
80void onTextOr(Tree node, List<Tree> termNodes);
81void onTextMinus(Tree node, Tree notNode);
82void onTextWord(String word);
83void onTextPhrase(String phrase);
84 }