org.carrot2.source
Class SearchEngineResponse

java.lang.Object
  extended by org.carrot2.source.SearchEngineResponse

public final class SearchEngineResponse
extends Object

A single search engine response. This includes typical information returned by a search engine: documents, total number of results, time of processing the query, etc.


Field Summary
static String COMPRESSION_KEY
          Metadata key for the compression algorithm used to decompress the returned stream.
 HashMap<String,Object> metadata
          All meta data returned in the response.
 ArrayList<Document> results
          All documents returned in the response.
static String RESULTS_TOTAL_KEY
          Total number of results available in the source (possibly an approximation).
 
Constructor Summary
SearchEngineResponse()
           
 
Method Summary
 long getResultsTotal()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESULTS_TOTAL_KEY

public static final String RESULTS_TOTAL_KEY
Total number of results available in the source (possibly an approximation).

See Also:
Constant Field Values

COMPRESSION_KEY

public static final String COMPRESSION_KEY
Metadata key for the compression algorithm used to decompress the returned stream.

See Also:
Constant Field Values

metadata

public final HashMap<String,Object> metadata
All meta data returned in the response.


results

public final ArrayList<Document> results
All documents returned in the response.

Constructor Detail

SearchEngineResponse

public SearchEngineResponse()
Method Detail

getResultsTotal

public long getResultsTotal()
Returns:
Returns an estimate of the total number of results or -1 if not available.


Copyright (c) Dawid Weiss, Stanislaw Osinski