|
DLESE Tools v1.6.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.dlese.dpc.index.queryParser.XMLQueryParser
public class XMLQueryParser
Creates a Lucene Query from an XML representation of a query. See sample Query XML file . Currently supports term, phrase, boolean and Lucene query syntax formatted queries, with option to set the boost factor assigned to any query (default boost is 1.0). If a Lucene query syntax based query may be found in the Query XML, then a Lucene QueryParser must be supplied, otherwise it may be ommitted.
VirtualSearchFieldMapper| Constructor Summary | |
|---|---|
XMLQueryParser()
|
|
| Method Summary | |
|---|---|
static org.apache.lucene.search.Query |
getLuceneQuery(Element queryElement,
org.apache.lucene.queryParser.QueryParser queryParser)
Gets the Lucene Query representation for the given XML Query starting at the Query element. |
static org.apache.lucene.search.Query |
getLuceneQuery(File queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
Gets the Lucene Query representation for the given XML Query. |
static org.apache.lucene.search.Query |
getLuceneQuery(String queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
Gets the Lucene Query representation for the given XML Query. |
static org.apache.lucene.search.Query |
getLuceneQuery(URL queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
Gets the Lucene Query representation for the given XML Query. |
static String |
getQueryString(String queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
Gets the Lucene query String representation for the given XML Query. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XMLQueryParser()
| Method Detail |
|---|
public static String getQueryString(String queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
throws Exception
queryXml - A XML QueryqueryParser - QueryParser used to parse Lucene syntax based queries and tokenize the text
Exception - If error
public static org.apache.lucene.search.Query getLuceneQuery(File queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
throws Exception
queryXml - A file containing an XML QueryqueryParser - QueryParser used to parse Lucene syntax based queries and tokenize the text
Exception - If error
public static org.apache.lucene.search.Query getLuceneQuery(URL queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
throws Exception
queryXml - A URL to a file containing an XML QueryqueryParser - QueryParser used to parse Lucene syntax based queries and tokenize the text
Exception - If error
public static org.apache.lucene.search.Query getLuceneQuery(String queryXml,
org.apache.lucene.queryParser.QueryParser queryParser)
throws Exception
queryXml - An XML QueryqueryParser - QueryParser used to parse Lucene syntax based queries and tokenize the text
Exception - If error
public static org.apache.lucene.search.Query getLuceneQuery(Element queryElement,
org.apache.lucene.queryParser.QueryParser queryParser)
throws Exception
queryElement - A dom4j representation of the Query elementqueryParser - QueryParser used to parse Lucene syntax based queries and tokenize the text
Exception - If error
|
DLESE Tools v1.6.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||