| 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectatg.search.routing.command.SearchXMLObject
atg.search.routing.command.SearchEngineCommandResponse
atg.search.routing.command.search.SearchResponse
atg.search.routing.command.search.SearchResultsResponse
public abstract class SearchResultsResponse
A SearchEngineCommandResponse that also provides search result specific information. The response for
 search-type commands (i.e. QueryRequest, SimilarDocsRequest or StructureQueryRequest) should sub-type this class so
 that callers can polymorphically process the search response results.
| Field Summary | |
|---|---|
static java.lang.String | 
CLASS_VERSION
Class version string  | 
| Fields inherited from class atg.search.routing.command.search.SearchResponse | 
|---|
mMultiPartitionSearch | 
| Constructor Summary | |
|---|---|
protected  | 
SearchResultsResponse()
 | 
protected  | 
SearchResultsResponse(atg.search.routing.command.SearchEngineResponse response)
 | 
| Method Summary | |
|---|---|
 void | 
addResult(Result pResult)
Adds a result to the existing list.  | 
 void | 
addResults(java.util.Collection<Result> pResults)
Adds every element in the list to the existing list of results.  | 
 boolean | 
equals(java.lang.Object pObject)
 | 
abstract  int | 
getGroupCount()
Returns the total number of answer groups in the results, regardless of paging.  | 
 java.util.List<AnswerGroup> | 
getGroups()
Returns the list of answer groups.  | 
 boolean | 
getHasMoreResults()
Returns true if there are more results for fast paging.  | 
 int | 
getMinScore()
Returns the minimum score  | 
 int | 
getPageNum()
Returns the zero-based page number of this response  | 
 atg.search.routing.command.search.PageOffsetInfo | 
getPageOffsetInfo()
If the response is the result of a merge, this holds the last response index per partition  | 
 int | 
getPageSize()
Returns the page size  | 
 java.util.List<Result> | 
getResults()
These are the results.  | 
 java.util.List<java.util.List<Result>> | 
getResultsWithGrouping()
These are the same results available via getResults(), but they are returned grouped into one List per
 answer group (as defined by Result.getAnswerGroup(). | 
 java.util.List<SpellingTerm> | 
getSpellingTerms()
Returns a list of spelling terms  | 
 java.util.List<SuggestedCategory> | 
getSuggestedCategories()
Returns the List of SuggestedCategory objects | 
 void | 
setMinScore(int pMinScore)
Sets the minimum score  | 
 void | 
setPageNum(int pPageNum)
Sets the zero-based page number of this response  | 
 void | 
setPageOffsetInfo(atg.search.routing.command.search.PageOffsetInfo pageOffsetInfo)
Sets the page offset info  | 
 void | 
setPageSize(int pPageSize)
Sets the page size  | 
 void | 
setResults(java.util.List<Result> pResults)
Sets the list of Results. | 
 void | 
setSpellingTerms(java.util.List<SpellingTerm> spellingTerms)
Sets the list of spelling terms  | 
 void | 
setSuggestedCategories(java.util.List<SuggestedCategory> suggestedCategories)
Sets the list of suggested categories  | 
| Methods inherited from class atg.search.routing.command.SearchEngineCommandResponse | 
|---|
getNextResponse, getNonSAXParser, getRequestTag, getSearchEngineResponse, parseResponse, setNextResponse, setSearchEngineResponse | 
| Methods inherited from class atg.search.routing.command.SearchXMLObject | 
|---|
appendComplexXml, appendOptionalAttr, appendOptionalElem, appendOptionalElem, appendOptionalElem, appendRequiredAttr, appendRequiredElem, appendRequiredElem, appendRequiredValue, getAllAttributeXML, getAllBodyXML, getAttributeXML, getBodyXML, getDefaultXmlBytes, getParentXMLObject, getXmlPath, setParentXMLObject, toXML, toXML | 
| Methods inherited from class java.lang.Object | 
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait | 
| Field Detail | 
|---|
public static java.lang.String CLASS_VERSION
| Constructor Detail | 
|---|
protected SearchResultsResponse()
protected SearchResultsResponse(atg.search.routing.command.SearchEngineResponse response)
| Method Detail | 
|---|
public boolean equals(java.lang.Object pObject)
equals in class java.lang.Objectpublic abstract int getGroupCount()
SimilarDocsRequest, this is simply the number of
 results.
getGroupCount in interface PagedResponsepublic java.util.List<Result> getResults()
Results. See getResultsWithGrouping() if you want the individual Results grouped by answer groups.
Results.public java.util.List<AnswerGroup> getGroups()
getResults(). This is not a
 'live' list of groups (or results).  That is, changes to this list will not be reflected in the flat list of
 results.  However, changes to the flat list will be reflected in the list. And changes to individual Results will
 be reflected in the flat list.
AnswerGroupspublic java.util.List<java.util.List<Result>> getResultsWithGrouping()
getResults(), but they are returned grouped into one List per
 answer group (as defined by Result.getAnswerGroup(). Thus the return
 value is a List of Lists, where each sub-List corresponds to a specific answer group.
Results.public boolean getHasMoreResults()
getHasMoreResults in interface PagedResponsepublic void setResults(java.util.List<Result> pResults)
Results.
pResults - the resultspublic void addResult(Result pResult)
pResult - a resultpublic void addResults(java.util.Collection<Result> pResults)
pResults - list of resultspublic int getMinScore()
public void setMinScore(int pMinScore)
pMinScore - the minimum scorepublic int getPageNum()
PagedResponse
getPageNum in interface PagedResponsepublic void setPageNum(int pPageNum)
PagedResponse
setPageNum in interface PagedResponsepublic int getPageSize()
PagedResponse
getPageSize in interface PagedResponsepublic void setPageSize(int pPageSize)
PagedResponse
setPageSize in interface PagedResponsepublic atg.search.routing.command.search.PageOffsetInfo getPageOffsetInfo()
PagedResponse
getPageOffsetInfo in interface PagedResponsepublic void setPageOffsetInfo(atg.search.routing.command.search.PageOffsetInfo pageOffsetInfo)
PagedResponse
setPageOffsetInfo in interface PagedResponsepageOffsetInfo - page offset informationpublic java.util.List<SpellingTerm> getSpellingTerms()
SpellingTermpublic void setSpellingTerms(java.util.List<SpellingTerm> spellingTerms)
spellingTerms - list of spelling termspublic java.util.List<SuggestedCategory> getSuggestedCategories()
SuggestedCategory objects
SuggestedCategory objectspublic void setSuggestedCategories(java.util.List<SuggestedCategory> suggestedCategories)
suggestedCategories - the list of suggested categories
  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||