|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object atg.search.routing.command.search.AnswerGroup
public class AnswerGroup
The engine returns a list of answer groups. When grouping by document, an answer group has one result.
When grouping by property, an answer group might have multiple results. Answer groups are distinguished
by their 1-based answer group ids. See getId()
.
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string |
Constructor Summary | |
---|---|
AnswerGroup()
|
Method Summary | |
---|---|
void |
addResult(Result pResult)
Adds the result to this answer group |
int |
getId()
Returns the answer group id, a 1-based identifier. |
Result |
getResult()
Returns the first result in the group. |
java.util.List<Result> |
getResults()
These are the results. |
static java.util.List<AnswerGroup> |
group(java.util.List<Result> pResults)
Utility method that groups a flat list of Results into a list of AnswerGroups. |
boolean |
isEmpty()
Indicates whether the group has any results |
void |
setId(int pId)
Sets the answer group id, a 1-based identifier. |
void |
setResults(java.util.List<Result> pResults)
Sets the results for this answer group |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.lang.String CLASS_VERSION
Constructor Detail |
---|
public AnswerGroup()
Method Detail |
---|
public int getId()
public void setId(int pId)
pId
- the answer group id, a 1-based identifier.public Result getResult()
public java.util.List<Result> getResults()
Result
s. See getResult()
if you want the first result (or when you are not grouping by property and can therefore be certain there is only
one result).
Result
s.public void setResults(java.util.List<Result> pResults)
pResults
- the results for the grouppublic void addResult(Result pResult)
pResult
- the result to addpublic boolean isEmpty()
public static java.util.List<AnswerGroup> group(java.util.List<Result> pResults)
pResults
- flat list of results
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |