com.rapidtransform.core.search.lucene
Class SearchResultsCompass

java.lang.Object
  extended by com.rapidtransform.core.search.lucene.SearchResultsCompass
All Implemented Interfaces:
SearchResults

public class SearchResultsCompass
extends java.lang.Object
implements SearchResults

The results object returned by com.rapidtransform.core.search.lucene.SearchServiceCompass when executing a search. This class encapsulates the hits returned from the Lucene query as well as the pages if pagination is being used. The search time is also include for performance monitoring.

Author:
Steve

Nested Class Summary
static class SearchResultsCompass.Page
          SearchResultsCompass internal class used for pagination.
 
Constructor Summary
SearchResultsCompass(org.compass.core.CompassHit[] hits)
          Constructor specifing only the hits returned from the search
SearchResultsCompass(org.compass.core.CompassHit[] hits, long time)
          Constructor using the hits returned from Compass search and time for the search to execute.
 
Method Summary
 org.compass.core.CompassHit[] getHits()
           
 SearchResultsCompass.Page[] getPages()
           
 long getSearchTime()
           
 void setHits(org.compass.core.CompassHit[] hits)
           
 void setPages(SearchResultsCompass.Page[] pages)
           
 void setSearchTime(long searchTime)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SearchResultsCompass

public SearchResultsCompass(org.compass.core.CompassHit[] hits,
                            long time)
Constructor using the hits returned from Compass search and time for the search to execute.

Parameters:
hits -
time -

SearchResultsCompass

public SearchResultsCompass(org.compass.core.CompassHit[] hits)
Constructor specifing only the hits returned from the search

Parameters:
hits -
Method Detail

getHits

public org.compass.core.CompassHit[] getHits()
Returns:
Returns the hits.

setHits

public void setHits(org.compass.core.CompassHit[] hits)
Parameters:
hits - The hits to set.

getPages

public SearchResultsCompass.Page[] getPages()
Returns:
Returns the pages.

setPages

public void setPages(SearchResultsCompass.Page[] pages)
Parameters:
pages - The pages to set.

getSearchTime

public long getSearchTime()
Returns:
Returns the searchTime.

setSearchTime

public void setSearchTime(long searchTime)
Parameters:
searchTime - The searchTime to set.