com.indexdata.torus2.query
Class QueryMatcher
java.lang.Object
com.indexdata.torus2.query.QueryMatcher
public class QueryMatcher
- extends Object
Document querying logic, TODO turn this into a non-static class and cache
compiled regexes and whatnot.
- Author:
- jakub
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
QueryMatcher
public QueryMatcher()
parseQuery
public static org.z3950.zing.cql.CQLNode parseQuery(String query)
throws QueryException
- Parses query string into tree representation
- Parameters:
query
-
- Returns:
- parsed query or null if query string was null or empty
- Throws:
QueryException
- when query is malformed or cannot be read
normalizeTokens
public static String normalizeTokens(String src,
String sep,
QueryMatcher.Tokenizer.TokenizerType type)
equalsWildcard
public static boolean equalsWildcard(String pattern,
int patternAt,
String text,
int textAt)
matchQuery
public static boolean matchQuery(Record.Layer layer,
org.z3950.zing.cql.CQLNode query)
throws QueryException
- Throws:
QueryException
matchIp
public static boolean matchIp(String low,
String high,
String value)
Copyright © 2008-2012 Index Data. All Rights Reserved.