public class CqlTranslatorImpl extends Object implements CqlTranslator
| Constructor and Description |
|---|
CqlTranslatorImpl() |
| Modifier and Type | Method and Description |
|---|---|
TranslatedQuery |
getTranslatedQuery(org.z3950.zing.cql.CQLNode queryRoot,
CqlValueTransformerMap valueTransformerMap)
method performs the translation and returns a TranslatedQuery object which contains the translated query and the
cql-related options.
|
TranslatedQuery |
getTranslatedQuery(org.z3950.zing.cql.CQLNode queryRoot,
CqlValueTransformerMap valueTransformerMap,
Map<String,List<String>> options,
com.google.common.collect.BiMap<String,String> aliases,
Map<String,String> weights)
method performs the translation and returns a TranslatedQuery object which contains the translated query and the
cql-related options.
|
TranslatedQuery |
getTranslatedQuery(String cqlQuery)
method performs the translation and returns a TranslatedQuery object which contains the translated query and the
cql-related options.
|
TranslatedQuery |
getTranslatedQuery(String cqlQuery,
CqlValueTransformerMap valueTransformerMap)
method performs the translation and returns a TranslatedQuery object which contains the translated query and the
cql-related options.
|
TranslatedQuery |
getTranslatedQuery(String cqlQuery,
CqlValueTransformerMap valueTransformerMap,
Map<String,List<String>> options)
method performs the translation and returns a TranslatedQuery object which contains the translated query and the
cql-related options.
|
TranslatedQuery |
getTranslatedQuery(String cqlQuery,
Map<String,List<String>> options)
method performs the translation and returns a TranslatedQuery object which contains the translated query and the
cql-related options.
|
protected static org.z3950.zing.cql.CQLNode |
parse(String query)
helper parsing method
|
String |
toLucene(org.z3950.zing.cql.CQLNode queryRoot)
main translator method
|
String |
toLucene(org.z3950.zing.cql.CQLNode queryRoot,
CqlValueTransformerMap valueTransformerMap)
main translator method
|
String |
toLucene(org.z3950.zing.cql.CQLNode queryRoot,
CqlValueTransformerMap valueTransformerMap,
Map<String,List<String>> options)
main translator method
|
String |
toLucene(String queryRoot)
|
String |
toLucene(String queryRoot,
CqlValueTransformerMap valueTransformerMap)
main translator method
|
String |
toLucene(String queryRoot,
Map<String,List<String>> options)
main translator method
|
org.bson.conversions.Bson |
toMongo(String cqlQuery)
Translates a cql query in a mongodb query.
|
public String toLucene(String queryRoot) throws org.z3950.zing.cql.CQLParseException, IOException
toLucene in interface CqlTranslatorqueryRoot - String representation of the cql queryorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic String toLucene(String queryRoot, Map<String,List<String>> options) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatortoLucene in interface CqlTranslatorqueryRoot - String representation of the cql queryorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic String toLucene(String queryRoot, CqlValueTransformerMap valueTransformerMap) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatortoLucene in interface CqlTranslatorqueryRoot - String representation of the cql queryvalueTransformerMap - callbacks which allow us to normalize field values when we know about themorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic String toLucene(org.z3950.zing.cql.CQLNode queryRoot) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatortoLucene in interface CqlTranslatorqueryRoot - Pre-parsed representation of the cql queryorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic String toLucene(org.z3950.zing.cql.CQLNode queryRoot, CqlValueTransformerMap valueTransformerMap) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatortoLucene in interface CqlTranslatorqueryRoot - Pre-parsed representation of the cql queryvalueTransformerMap - callbacks which allow us to normalize field values when we know about themorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic String toLucene(org.z3950.zing.cql.CQLNode queryRoot, CqlValueTransformerMap valueTransformerMap, Map<String,List<String>> options) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatortoLucene in interface CqlTranslatorqueryRoot - Pre-parsed representation of the cql queryvalueTransformerMap - callbacks which allow us to normalize field values when we know about themoptions - options that modify the behavior of cql parsingorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic TranslatedQuery getTranslatedQuery(org.z3950.zing.cql.CQLNode queryRoot, CqlValueTransformerMap valueTransformerMap) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatorgetTranslatedQuery in interface CqlTranslatorqueryRoot - Pre-parsed representation of the cql queryvalueTransformerMap - callbacks which allow us to normalize field values when we know about themorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic TranslatedQuery getTranslatedQuery(org.z3950.zing.cql.CQLNode queryRoot, CqlValueTransformerMap valueTransformerMap, Map<String,List<String>> options, com.google.common.collect.BiMap<String,String> aliases, Map<String,String> weights) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatorgetTranslatedQuery in interface CqlTranslatorqueryRoot - Pre-parsed representation of the cql queryvalueTransformerMap - callbacks which allow us to normalize field values when we know about themoptions - options that modify the behavior of cql parsingorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic TranslatedQuery getTranslatedQuery(String cqlQuery) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatorgetTranslatedQuery in interface CqlTranslatororg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic TranslatedQuery getTranslatedQuery(String cqlQuery, Map<String,List<String>> options) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatorgetTranslatedQuery in interface CqlTranslatoroptions - options that modify the behavior of cql parsingorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic TranslatedQuery getTranslatedQuery(String cqlQuery, CqlValueTransformerMap valueTransformerMap) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatorgetTranslatedQuery in interface CqlTranslatorvalueTransformerMap - callbacks which allow us to normalize field values when we know about themorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic TranslatedQuery getTranslatedQuery(String cqlQuery, CqlValueTransformerMap valueTransformerMap, Map<String,List<String>> options) throws org.z3950.zing.cql.CQLParseException, IOException
CqlTranslatorgetTranslatedQuery in interface CqlTranslatorvalueTransformerMap - callbacks which allow us to normalize field values when we know about themoptions - options that modify the behavior of cql parsingorg.z3950.zing.cql.CQLParseExceptionIOExceptionpublic org.bson.conversions.Bson toMongo(String cqlQuery) throws IOException, org.z3950.zing.cql.CQLParseException
CqlTranslatortoMongo in interface CqlTranslatorcqlQuery - the query to be translated.IOExceptionorg.z3950.zing.cql.CQLParseExceptionprotected static org.z3950.zing.cql.CQLNode parse(String query) throws org.z3950.zing.cql.CQLParseException, IOException
query - org.z3950.zing.cql.CQLParseExceptionIOExceptionCopyright © 2017. All rights reserved.