com.sun.labs.minion.query
Class Term

java.lang.Object
  extended by com.sun.labs.minion.query.Element
      extended by com.sun.labs.minion.query.Term

public class Term
extends Element

A class for a search term. Various modifiers can be applied to a term to affect how the term should be treated during the search.


Nested Class Summary
static class Term.Modifier
          The modifiers that affect which terms will be pulled from the index for the given query term.
 
Field Summary
 
Fields inherited from class com.sun.labs.minion.query.Element
fields, strict
 
Constructor Summary
Term(java.lang.String term)
           
Term(java.lang.String term, java.util.EnumSet<Term.Modifier> mods)
           
 
Method Summary
 void addModifier(Term.Modifier modifier)
           
 java.util.EnumSet<Term.Modifier> getModifiers()
           
 QueryElement getQueryElement()
          Transduces this query element into a "real" query element, one that can be evaluated by the search engine.
 java.lang.String getTerm()
           
 
Methods inherited from class com.sun.labs.minion.query.Element
addField, getFields, getStrict, setFields, setStrict
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Term

public Term(java.lang.String term)

Term

public Term(java.lang.String term,
            java.util.EnumSet<Term.Modifier> mods)
Method Detail

addModifier

public void addModifier(Term.Modifier modifier)

getTerm

public java.lang.String getTerm()

getModifiers

public java.util.EnumSet<Term.Modifier> getModifiers()

getQueryElement

public QueryElement getQueryElement()
Description copied from class: Element
Transduces this query element into a "real" query element, one that can be evaluated by the search engine.

Specified by:
getQueryElement in class Element
Returns:
an evaluatable query element.