|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Query Parser Interface:
Allows a common language to be parsed into the native tongue of
a SearchSource.
Query Parser has a type - based on the input form which passes the parameters to the processor. Has a protocol (implementation) based on what data source it is searching. The data source is represented by an associated SearchSource object that maintains connection/configuration information.
IQueryParsers are associated with a SearchSource object.
The SearchSource defines
the specific characteristics of a data source such as a web site, Verity collection or SQL-compliant
database. IQueryParser contains the code needed to parse a query in any language into
the source-specific information that is needed for the search source's
IQueryProcessors executeQuery() method.
The sourceLanguage attribute specifies from which language you are translating from.
| Method Summary | |
java.lang.String |
createQuery(OrderedMap params,
java.lang.String language,
ILoginInfo userInfo)
|
java.util.List |
getErrors()
Returns the errors that occurred during the translate() step. |
void |
initialize(org.w3c.dom.Element elem)
Initializes the object from an XML tag or element. |
OrderedMap |
parse(OrderedMap params,
ILoginInfo userInfo)
|
OrderedMap |
parse(OrderedMap params,
java.lang.String language,
ILoginInfo userInfo)
Translate using the input parameters if this is how the query is passed. |
void |
setLanguage(java.lang.String language)
|
void |
setSessionID(java.lang.String id)
Allows QueryParser object to access the sessionData. |
| Method Detail |
public OrderedMap parse(OrderedMap params,
java.lang.String language,
ILoginInfo userInfo)
throws QueryParseException,
UnsupportedLanguageException
params - An ordered map containing the query parameterslanguage - String representing the target language (e.g. VQL)
QueryParseException
UnsupportedLanguageException
public OrderedMap parse(OrderedMap params,
ILoginInfo userInfo)
public void setLanguage(java.lang.String language)
public java.lang.String createQuery(OrderedMap params,
java.lang.String language,
ILoginInfo userInfo)
throws QueryParseException,
UnsupportedLanguageException
QueryParseException
UnsupportedLanguageExceptionpublic java.util.List getErrors()
public void setSessionID(java.lang.String id)
public void initialize(org.w3c.dom.Element elem)
IConfigurable
initialize in interface IConfigurable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||