|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.cocoon.bean.query.SimpleLuceneCriterionBean
public class SimpleLuceneCriterionBean
The criterion bean.
This object defines a Bean for holding a query criterion.
The idea is to abstract the process of searching into a Bean to be manipulated by CForms.
This Bean is designed to be persistable.
| Field Summary | |
|---|---|
protected String |
field
The Bean's index field to seach in. |
protected Long |
id
The Bean's ID. |
protected String |
match
The Bean's match value. |
protected String |
term
The Bean's search term. |
| Fields inherited from interface org.apache.cocoon.bean.query.SimpleLuceneCriterion |
|---|
ALL_MATCH, ANY_FIELD, ANY_MATCH, LIKE_MATCH, NOT_MATCH, PHRASE_MATCH |
| Constructor Summary | |
|---|---|
SimpleLuceneCriterionBean()
Default constructor. |
|
SimpleLuceneCriterionBean(String field,
String match,
String term)
Utility constructor. |
|
| Method Summary | |
|---|---|
Object |
clone()
|
String |
getField()
Gets the Bean's field |
Long |
getId()
Gets the Bean's ID |
String |
getMatch()
Gets the Bean's match |
org.apache.lucene.search.Query |
getQuery(org.apache.lucene.analysis.Analyzer analyzer)
Gets the org.apache.lucene.search.Query from the Criterion
The analyzer specifies which org.apache.lucene.analysis.Analyzer to use for this search. |
String |
getTerm()
Gets the Bean's term |
boolean |
isProhibited()
Gets the prohibited status from the Criterion |
void |
setField(String field)
Sets the Bean's field. |
void |
setId(Long id)
Sets the Bean's ID |
void |
setMatch(String match)
Sets the Bean's match. |
void |
setTerm(String term)
Sets the Bean's term. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Long id
protected String field
protected String match
protected String term
| Constructor Detail |
|---|
public SimpleLuceneCriterionBean()
public SimpleLuceneCriterionBean(String field,
String match,
String term)
match - the kind of match to usefield - the field to searchterm - the terms to search for| Method Detail |
|---|
public Object clone()
throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedExceptionpublic org.apache.lucene.search.Query getQuery(org.apache.lucene.analysis.Analyzer analyzer)
org.apache.lucene.search.Query from the Criterion
The analyzer specifies which org.apache.lucene.analysis.Analyzer to use for this search.
getQuery in interface SimpleLuceneCriterionanalyzer - The org.apache.lucene.analysis.Analyzer to use to extract the Terms from this Criterionpublic boolean isProhibited()
isProhibited in interface SimpleLuceneCriterionpublic Long getId()
Long ID of the Bean.public void setId(Long id)
id - the Long ID of the Bean.public String getField()
String field of the Bean.public void setField(String field)
field - the String field of the Bean.public String getMatch()
String match of the Bean.public void setMatch(String match)
match - the String match of the Bean.public String getTerm()
String term of the Bean.public void setTerm(String term)
Criterion.
term - the String term of the Bean.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||