|
Terrier IR Platform 1.1.1 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.ac.gla.terrier.querying.parser.Query
uk.ac.gla.terrier.querying.parser.MultiTermQuery
public class MultiTermQuery
Represents a query consisting of more than one terms or other sub-queries, qualified with field, requirement or phrase operators.
| Constructor Summary | |
|---|---|
MultiTermQuery()
A default constructor. |
|
| Method Summary | |
|---|---|
void |
add(Query query)
Adds a subquery to this query. |
void |
add(java.lang.String term)
|
boolean |
applyTermPipeline(TermPipelineAccessor tpa)
Applies the given term pipeline to the query terms and sub-queries that construct this query. |
java.lang.Object |
clone()
Deep copy this Query object |
int |
getNumberOfTerms()
Returns the number of terms, or subqueries. |
void |
getTermsOf(java.lang.Class c,
java.util.ArrayList alist,
boolean req)
Returns all the query terms, in subqueries that are instances of a given class |
void |
obtainAllOf(java.lang.Class c,
java.util.ArrayList a)
|
boolean |
obtainControls(java.util.HashSet allowed,
java.util.Hashtable controls)
Checks all child objects to see if they are FieldQuery objects, they are each called to see if the are controls. |
void |
obtainQueryTerms(MatchingQueryTerms terms)
Prepares the query for matching by transforming the query objects to a set of query terms. |
void |
obtainQueryTerms(MatchingQueryTerms terms,
boolean required)
Prepares the query for matching by transforming the query objects to a set of query terms. |
java.lang.String |
toString()
Returns a string representation of the query. |
| Methods inherited from class uk.ac.gla.terrier.querying.parser.Query |
|---|
setChild |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MultiTermQuery()
| Method Detail |
|---|
public int getNumberOfTerms()
public java.lang.Object clone()
Query
clone in class Querypublic void add(java.lang.String term)
public void add(Query query)
query - Query a subquery.public java.lang.String toString()
toString in class Querypublic boolean applyTermPipeline(TermPipelineAccessor tpa)
applyTermPipeline in class Querytpa - TermPipelineAccessor the object that gives access
to a term pipeline.
public void obtainQueryTerms(MatchingQueryTerms terms)
obtainQueryTerms in class Queryterms - MatchingQueryTerms the object which holds the
query terms and their modifiers.
public void obtainQueryTerms(MatchingQueryTerms terms,
boolean required)
obtainQueryTerms in class Queryterms - MatchingQueryTerms the object which holds the
query terms and their modifiers.required - boolean indicates whether the field query
is required or not.
public boolean obtainControls(java.util.HashSet allowed,
java.util.Hashtable controls)
obtainControls in class Queryallowed - The HashSet of control names that are allowed to be set.controls - The Hashtable into which child objects much add
found controls
public void getTermsOf(java.lang.Class c,
java.util.ArrayList alist,
boolean req)
getTermsOf in class Queryc - Class a class of queries.alist - ArrayList the list of query terms.req - boolean indicates whether the subqueries
are required or not.
public void obtainAllOf(java.lang.Class c,
java.util.ArrayList a)
obtainAllOf in class Query
|
Terrier IR Platform 1.1.1 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||