SolrIndexSearcher (Solr 3.6.2 API)
Keywords: org.apache.solr.search.SolrIndexSearcher class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.solr.search
Class SolrIndexSearcher

    java.lang.Object
      org.apache.lucene.search.Searcher
          org.apache.lucene.search.IndexSearcher
              org.apache.solr.search.SolrIndexSearcher

All Implemented Interfaces:
  Closeable, Searchable, SolrInfoMBean

    public class SolrIndexSearcher

extends IndexSearcher
implements SolrInfoMBean

SolrIndexSearcher adds schema awareness and caching functionality over the lucene IndexSearcher.

Since:
  solr 0.9
Version:
  $Id: SolrIndexSearcher.java 1381488 2012-09-06 07:28:55Z koji $

Nested Class Summary
`static class` | `SolrIndexSearcher.ProcessedFilter`
`static class` | `SolrIndexSearcher.QueryCommand` A query request command to avoid having to change the method signatures if we want to pass additional information to the searcher.
`static class` | `SolrIndexSearcher.QueryResult` The result of a search.
`static class` | `SolrIndexSearcher.TermDocsState`

Nested classes/interfaces inherited from interface org.apache.solr.core.SolrInfoMBean
`SolrInfoMBean.Category`

Field Summary
`boolean` | `enableLazyFieldLoading`
`static int` | `GET_DOCLIST`
`static int` | `GET_DOCSET`
`static int` | `GET_SCORES`
`static AtomicLong` | `numCloses`
`static AtomicLong` | `numOpens`

Fields inherited from class org.apache.lucene.search.IndexSearcher
`docStarts, subReaders, subSearchers`

Constructor Summary
`SolrIndexSearcher(SolrCore core, IndexSchema schema, String name, Directory directory, boolean enableCache)`
`SolrIndexSearcher(SolrCore core, IndexSchema schema, String name, Directory directory, boolean readOnly, boolean enableCache)` Creates a searcher searching the index in the provided directory.
`SolrIndexSearcher(SolrCore core, IndexSchema schema, String name, IndexReader r, boolean enableCache)` Creates a searcher searching the provided index.
`SolrIndexSearcher(SolrCore core, IndexSchema schema, String name, IndexReader r, boolean closeReader, boolean enableCache)`
`SolrIndexSearcher(SolrCore core, IndexSchema schema, String name, String path, boolean enableCache)` Deprecated. use alternate constructor

Method Summary
`void` | `cacheDocSet(Query query, DocSet optionalAnswer, boolean mustCache)` Compute and cache the DocSet that matches a query.
`Object` | `cacheInsert(String cacheName, Object key, Object val)` insert an entry in a generic cache
`Object` | `cacheLookup(String cacheName, Object key)` lookup an entry in a generic cache
`void` | `close()` Free's resources associated with this searcher.
`DocSet` | `convertFilter(Filter lfilter)` Converts a filter into a DocSet.
`Document` | `doc(int i)` Retrieve the `Document` instance corresponding to the document id.
`Document` | `doc(int n, FieldSelector fieldSelector)` Retrieve a `Document` using a `FieldSelector` This method does not currently use the Solr document cache.
`Document` | `doc(int i, Set<String> fields)` Retrieve the `Document` instance corresponding to the document id.
`Explanation` | `explain(Query query, int doc)`
`SolrCache` | `getCache(String cacheName)` return the named generic cache
`SolrInfoMBean.Category` | `getCategory()` Purpose of this Class
`SolrCore` | `getCore()`
`String` | `getDescription()` Simple one or two line description
`DocList` | `getDocList(Query query, DocSet filter, Sort lsort, int offset, int len)` Returns documents matching both `query` and `filter` and sorted by `sort`.
`DocList` | `getDocList(Query query, List<Query> filterList, Sort lsort, int offset, int len, int flags)` Returns documents matching both `query` and the intersection of the `filterList`, sorted by `sort`.
`DocList` | `getDocList(Query query, Query filter, Sort lsort, int offset, int len)` Returns documents matching both `query` and `filter` and sorted by `sort`.
`DocListAndSet` | `getDocListAndSet(Query query, DocSet filter, Sort lsort, int offset, int len)` Returns documents matching both `query` and `filter` and sorted by `sort`.
`DocListAndSet` | `getDocListAndSet(Query query, DocSet filter, Sort lsort, int offset, int len, int flags)` Returns documents matching both `query` and `filter` and sorted by `sort`.
`DocListAndSet` | `getDocListAndSet(Query query, List<Query> filterList, Sort lsort, int offset, int len)` Returns documents matching both `query` and the intersection of `filterList`, sorted by `sort`.
`DocListAndSet` | `getDocListAndSet(Query query, List<Query> filterList, Sort lsort, int offset, int len, int flags)` Returns documents matching both `query` and the intersection of `filterList`, sorted by `sort`.
`DocListAndSet` | `getDocListAndSet(Query query, Query filter, Sort lsort, int offset, int len)` Returns documents matching both `query` and `filter` and sorted by `sort`.
`DocListAndSet` | `getDocListAndSet(Query query, Query filter, Sort lsort, int offset, int len, int flags)` Returns documents matching both `query` and `filter` and sorted by `sort`.
`URL[]` | `getDocs()` Documentation URL list.
`DocSet` | `getDocSet(List<Query> queries)` Returns the set of document ids matching all queries.
`DocSet` | `getDocSet(Query query)` Returns the set of document ids matching a query.
`DocSet` | `getDocSet(Query query, DocSet filter)` Returns the set of document ids matching both the query and the filter.
`protected DocSet` | `getDocSetNC(Query query, DocSet filter)`
`protected DocSet` | `getDocSetNC(Query query, DocSet filter, SolrIndexSearcher.TermDocsState tdState)`
`Collection<String>` | `getFieldNames()` Returns a collection of all field names the index reader knows about.
`SolrCache` | `getFieldValueCache()` expert: internal API, subject to change
`int` | `getFirstMatch(Term t)` Returns the first document number containing the term `t` Returns -1 if no document was found.
`String` | `getIndexDir()`
`String` | `getName()` Simple common usage name, e.g.
`long` | `getOpenTime()`
`DocSet` | `getPositiveDocSet(Query q, SolrIndexSearcher.TermDocsState tdState)`
`SolrIndexSearcher.ProcessedFilter` | `getProcessedFilter(DocSet setFilter, List<Query> queries)`
`SolrIndexReader` | `getReader()` Direct access to the IndexReader used by this searcher
`IndexSchema` | `getSchema()` Direct access to the IndexSchema for use with this searcher
`String` | `getSource()` CVS Source, SVN Source, etc
`String` | `getSourceId()` CVS Id, SVN Id, etc
`NamedList` | `getStatistics()` Any statistics this instance would like to be publicly available via the Solr Administration interface.
`Collection<String>` | `getStoredHighlightFieldNames()` Returns a collection of the names of all stored fields which can be highlighted the index reader knows about.
`String` | `getVersion()` Simple common usage version, e.g.
`static void` | `initRegenerators(SolrConfig solrConfig)`
`int` | `numDocs(Query a, DocSet b)` Returns the number of documents that match both `a` and `b`.
`int` | `numDocs(Query a, Query b)` Returns the number of documents that match both `a` and `b`.
`Document[]` | `readDocs(DocList ids)` Takes a list of docs (the doc ids actually), and returns an array of Documents containing all of the stored fields.
`void` | `readDocs(Document[] docs, DocList ids)` Takes a list of docs (the doc ids actually), and reads them into an array of Documents.
`void` | `readDocs(Document[] docs, DocList ids, Set<String> fields)` Takes a list of docs (the doc ids actually) and a set of fields to load, and reads them into an array of Documents.
`void` | `register()` Register sub-objects such as caches
`SolrIndexSearcher.QueryResult` | `search(SolrIndexSearcher.QueryResult qr, SolrIndexSearcher.QueryCommand cmd)`
`protected DocList` | `sortDocSet(DocSet set, Sort sort, int nDocs)`
`String` | `toString()`
`void` | `warm(SolrIndexSearcher old)` Warm this searcher based on an old one (primarily for auto-cache warming).
`Sort` | `weightSort(Sort sort)` Returns a weighted sort according to this searcher

Methods inherited from class org.apache.lucene.search.IndexSearcher
`createNormalizedWeight, docFreq, explain, gatherSubReaders, getIndexReader, getSimilarity, getSubReaders, maxDoc, rewrite, search, search, search, search, search, search, search, search, search, search, search, searchAfter, searchAfter, setDefaultFieldSortScoring, setSimilarity`

Methods inherited from class org.apache.lucene.search.Searcher
`createWeight, docFreqs`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### numOpens

    public static final AtomicLong numOpens

### numCloses

    public static final AtomicLong numCloses

### enableLazyFieldLoading

    public final boolean enableLazyFieldLoading

### GET_DOCSET

    public static final int GET_DOCSET

See Also:
  Constant Field Values

### GET_DOCLIST

    public static final int GET_DOCLIST

See Also:
  Constant Field Values

### GET_SCORES

    public static final int GET_SCORES

See Also:
  Constant Field Values

Constructor Detail

### SolrIndexSearcher

    @Deprecated
    public SolrIndexSearcher(SolrCore core,
                                        IndexSchema schema,
                                        String name,
                                        String path,
                                        boolean enableCache)
                      throws IOException

  Deprecated. use alternate constructor

  Creates a searcher searching the index in the named directory.

  Throws:
    `IOException`

### SolrIndexSearcher

    public SolrIndexSearcher(SolrCore core,
                             IndexSchema schema,
                             String name,
                             Directory directory,
                             boolean enableCache)
                      throws IOException

Throws:
  `IOException`

### SolrIndexSearcher

    public SolrIndexSearcher(SolrCore core,
                             IndexSchema schema,
                             String name,
                             Directory directory,
                             boolean readOnly,
                             boolean enableCache)
                      throws IOException

  Creates a searcher searching the index in the provided directory.

  Throws:
    `IOException`

### SolrIndexSearcher

    public SolrIndexSearcher(SolrCore core,
                             IndexSchema schema,
                             String name,
                             IndexReader r,
                             boolean enableCache)

  Creates a searcher searching the provided index.

### SolrIndexSearcher

    public SolrIndexSearcher(SolrCore core,
                             IndexSchema schema,
                             String name,
                             IndexReader r,
                             boolean closeReader,
                             boolean enableCache)

Method Detail

### toString

    public String toString()

  Overrides:
    `toString` in class `IndexSearcher`

### getCore

    public SolrCore getCore()

### register

    public void register()

  Register sub-objects such as caches

### close

    public void close()
               throws IOException

  Free's resources associated with this searcher. In particular, the underlying reader and any cache's in use are closed.

  Specified by:
    `close` in interface `Closeable`
  Specified by:
    `close` in interface `Searchable`
  Overrides:
    `close` in class `IndexSearcher`
  Throws:
    `IOException`

### getReader

    public SolrIndexReader getReader()

  Direct access to the IndexReader used by this searcher

### getSchema

    public IndexSchema getSchema()

  Direct access to the IndexSchema for use with this searcher

### getFieldNames

    public Collection<String> getFieldNames()

  Returns a collection of all field names the index reader knows about.

### getStoredHighlightFieldNames

    public Collection<String> getStoredHighlightFieldNames()

  Returns a collection of the names of all stored fields which can be highlighted the index reader knows about.

### initRegenerators

    public static void initRegenerators(SolrConfig solrConfig)

### search

    public SolrIndexSearcher.QueryResult search(SolrIndexSearcher.QueryResult qr,
                                                SolrIndexSearcher.QueryCommand cmd)
                                         throws IOException

  Throws:
    `IOException`

### getIndexDir

    public String getIndexDir()

  Returns:
    the indexDir on which this searcher is opened
  See Also:
    `SolrIndexSearcher(SolrCore, IndexSchema, String, Directory, boolean)`

### doc

    public Document doc(int i)
                 throws IOException

  Retrieve the `Document` instance corresponding to the document id.

  Specified by:
    `doc` in interface `Searchable`
  Overrides:
    `doc` in class `IndexSearcher`
  Throws:
    `IOException`

### doc

    public Document doc(int n,
                        FieldSelector fieldSelector)
                 throws IOException

  Retrieve a `Document` using a `FieldSelector` This method does not currently use the Solr document cache.

  Specified by:
    `doc` in interface `Searchable`
  Overrides:
    `doc` in class `IndexSearcher`
  Throws:
    `IOException`
  See Also:
    `IndexReader.document(int, FieldSelector)`

### doc

    public Document doc(int i,
                        Set<String> fields)
                 throws IOException

  Retrieve the `Document` instance corresponding to the document id. Note: The document will have all fields accessable, but if a field filter is provided, only the provided fields will be loaded (the remainder will be available lazily).

  Throws:
    `IOException`

### readDocs

    public void readDocs(Document[] docs,
                         DocList ids)
                  throws IOException

  Takes a list of docs (the doc ids actually), and reads them into an array of Documents.

  Throws:
    `IOException`

### readDocs

    public void readDocs(Document[] docs,
                         DocList ids,
                         Set<String> fields)
                  throws IOException

  Takes a list of docs (the doc ids actually) and a set of fields to load, and reads them into an array of Documents.

  Throws:
    `IOException`

### getFieldValueCache

    public SolrCache getFieldValueCache()

  expert: internal API, subject to change

### weightSort

    public Sort weightSort(Sort sort)
                    throws IOException

  Returns a weighted sort according to this searcher

  Throws:
    `IOException`

### getFirstMatch

    public int getFirstMatch(Term t)
                      throws IOException

  Returns the first document number containing the term `t` Returns -1 if no document was found. This method is primarily intended for clients that want to fetch documents using a unique identifier."

  Parameters:
    `t` -
  Returns:
    the first document number containing the term
  Throws:
    `IOException`

### cacheDocSet

    public void cacheDocSet(Query query,
                            DocSet optionalAnswer,
                            boolean mustCache)
                     throws IOException

  Compute and cache the DocSet that matches a query. The normal usage is expected to be cacheDocSet(myQuery, null,false) meaning that Solr will determine if the Query warrants caching, and if so, will compute the DocSet that matches the Query and cache it. If the answer to the query is already cached, nothing further will be done.

  If the optionalAnswer DocSet is provided, it should *not* be modified after this call.

  Parameters:
    `query` - the lucene query that will act as the key
    `optionalAnswer` - the DocSet to be cached - if null, it will be computed.
    `mustCache` - if true, a best effort will be made to cache this entry. if false, heuristics may be used to determine if it should be cached.
  Throws:
    `IOException`

### getDocSet

    public DocSet getDocSet(Query query)
                     throws IOException

  Returns the set of document ids matching a query. This method is cache-aware and attempts to retrieve the answer from the cache if possible. If the answer was not cached, it may have been inserted into the cache as a result of this call. This method can handle negative queries.

  The DocSet returned should not be modified.

  Throws:
    `IOException`

### getPositiveDocSet

    public DocSet getPositiveDocSet(Query q,
                                    SolrIndexSearcher.TermDocsState tdState)
                             throws IOException

  Throws:
    `IOException`
  NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.

### getDocSet

    public DocSet getDocSet(List<Query> queries)
                     throws IOException

  Returns the set of document ids matching all queries. This method is cache-aware and attempts to retrieve the answer from the cache if possible. If the answer was not cached, it may have been inserted into the cache as a result of this call. This method can handle negative queries.

  The DocSet returned should not be modified.

  Throws:
    `IOException`

### getProcessedFilter

    public SolrIndexSearcher.ProcessedFilter getProcessedFilter(DocSet setFilter,
                                                                List<Query> queries)
                                                         throws IOException

  Throws:
    `IOException`

### getDocSetNC

    protected DocSet getDocSetNC(Query query,
                                 DocSet filter)
                          throws IOException

  Throws:
    `IOException`

### getDocSetNC

    protected DocSet getDocSetNC(Query query,
                                 DocSet filter,
                                 SolrIndexSearcher.TermDocsState tdState)
                          throws IOException

  Throws:
    `IOException`

### getDocSet

    public DocSet getDocSet(Query query,
                            DocSet filter)
                     throws IOException

  Returns the set of document ids matching both the query and the filter. This method is cache-aware and attempts to retrieve the answer from the cache if possible. If the answer was not cached, it may have been inserted into the cache as a result of this call.

  Parameters:
    `query` -
    `filter` - may be null
  Returns:
    DocSet meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### convertFilter

    public DocSet convertFilter(Filter lfilter)
                         throws IOException

  Converts a filter into a DocSet. This method is not cache-aware and no caches are checked.

  Throws:
    `IOException`

### getDocList

    public DocList getDocList(Query query,
                              Query filter,
                              Sort lsort,
                              int offset,
                              int len)
                       throws IOException

  Returns documents matching both `query` and `filter` and sorted by `sort`.

  This method is cache aware and may retrieve `filter` from the cache or make an insertion into the cache as a result of this call.

  FUTURE: The returned DocList may be retrieved from a cache.

  Parameters:
    `query` -
    `filter` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
  Returns:
    DocList meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocList

    public DocList getDocList(Query query,
                              List<Query> filterList,
                              Sort lsort,
                              int offset,
                              int len,
                              int flags)
                       throws IOException

  Returns documents matching both `query` and the intersection of the `filterList`, sorted by `sort`.

  This method is cache aware and may retrieve `filter` from the cache or make an insertion into the cache as a result of this call.

  FUTURE: The returned DocList may be retrieved from a cache.

  Parameters:
    `query` -
    `filterList` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
  Returns:
    DocList meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocList

    public DocList getDocList(Query query,
                              DocSet filter,
                              Sort lsort,
                              int offset,
                              int len)
                       throws IOException

  Returns documents matching both `query` and `filter` and sorted by `sort`. FUTURE: The returned DocList may be retrieved from a cache.

  Parameters:
    `query` -
    `filter` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
  Returns:
    DocList meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocListAndSet

    public DocListAndSet getDocListAndSet(Query query,
                                          Query filter,
                                          Sort lsort,
                                          int offset,
                                          int len)
                                   throws IOException

  Returns documents matching both `query` and `filter` and sorted by `sort`. Also returns the complete set of documents matching `query` and `filter` (regardless of `offset` and `len`).

  This method is cache aware and may retrieve `filter` from the cache or make an insertion into the cache as a result of this call.

  FUTURE: The returned DocList may be retrieved from a cache.

  The DocList and DocSet returned should not be modified.

  Parameters:
    `query` -
    `filter` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
  Returns:
    DocListAndSet meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocListAndSet

    public DocListAndSet getDocListAndSet(Query query,
                                          Query filter,
                                          Sort lsort,
                                          int offset,
                                          int len,
                                          int flags)
                                   throws IOException

  Returns documents matching both `query` and `filter` and sorted by `sort`. Also returns the compete set of documents matching `query` and `filter` (regardless of `offset` and `len`).

  This method is cache aware and may retrieve `filter` from the cache or make an insertion into the cache as a result of this call.

  FUTURE: The returned DocList may be retrieved from a cache.

  The DocList and DocSet returned should not be modified.

  Parameters:
    `query` -
    `filter` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
    `flags` - user supplied flags for the result set
  Returns:
    DocListAndSet meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocListAndSet

    public DocListAndSet getDocListAndSet(Query query,
                                          List<Query> filterList,
                                          Sort lsort,
                                          int offset,
                                          int len)
                                   throws IOException

  Returns documents matching both `query` and the intersection of `filterList`, sorted by `sort`. Also returns the compete set of documents matching `query` and `filter` (regardless of `offset` and `len`).

  This method is cache aware and may retrieve `filter` from the cache or make an insertion into the cache as a result of this call.

  FUTURE: The returned DocList may be retrieved from a cache.

  The DocList and DocSet returned should not be modified.

  Parameters:
    `query` -
    `filterList` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
  Returns:
    DocListAndSet meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocListAndSet

    public DocListAndSet getDocListAndSet(Query query,
                                          List<Query> filterList,
                                          Sort lsort,
                                          int offset,
                                          int len,
                                          int flags)
                                   throws IOException

  Returns documents matching both `query` and the intersection of `filterList`, sorted by `sort`. Also returns the compete set of documents matching `query` and `filter` (regardless of `offset` and `len`).

  This method is cache aware and may retrieve `filter` from the cache or make an insertion into the cache as a result of this call.

  FUTURE: The returned DocList may be retrieved from a cache.

  The DocList and DocSet returned should not be modified.

  Parameters:
    `query` -
    `filterList` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
    `flags` - user supplied flags for the result set
  Returns:
    DocListAndSet meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocListAndSet

    public DocListAndSet getDocListAndSet(Query query,
                                          DocSet filter,
                                          Sort lsort,
                                          int offset,
                                          int len)
                                   throws IOException

  Returns documents matching both `query` and `filter` and sorted by `sort`. Also returns the compete set of documents matching `query` and `filter` (regardless of `offset` and `len`).

  FUTURE: The returned DocList may be retrieved from a cache.

  Parameters:
    `query` -
    `filter` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
  Returns:
    DocListAndSet meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### getDocListAndSet

    public DocListAndSet getDocListAndSet(Query query,
                                          DocSet filter,
                                          Sort lsort,
                                          int offset,
                                          int len,
                                          int flags)
                                   throws IOException

  Returns documents matching both `query` and `filter` and sorted by `sort`. Also returns the compete set of documents matching `query` and `filter` (regardless of `offset` and `len`).

  This method is cache aware and may make an insertion into the cache as a result of this call.

  FUTURE: The returned DocList may be retrieved from a cache.

  The DocList and DocSet returned should not be modified.

  Parameters:
    `query` -
    `filter` - may be null
    `lsort` - criteria by which to sort (if null, query relevance is used)
    `offset` - offset into the list of documents to return
    `len` - maximum number of documents to return
    `flags` - user supplied flags for the result set
  Returns:
    DocListAndSet meeting the specified criteria, should not be modified by the caller.
  Throws:
    `IOException`

### sortDocSet

    protected DocList sortDocSet(DocSet set,
                                 Sort sort,
                                 int nDocs)
                          throws IOException

  Throws:
    `IOException`

### numDocs

    public int numDocs(Query a,
                       DocSet b)
                throws IOException

  Returns the number of documents that match both `a` and `b`.

  This method is cache-aware and may check as well as modify the cache.

  Parameters:
    `a` -
    `b` -
  Returns:
    the numer of documents in the intersection between `a` and `b`.
  Throws:
    `IOException`

### numDocs

    public int numDocs(Query a,
                       Query b)
                throws IOException

  Returns the number of documents that match both `a` and `b`.

  This method is cache-aware and may check as well as modify the cache.

  Parameters:
    `a` -
    `b` -
  Returns:
    the numer of documents in the intersection between `a` and `b`.
  Throws:
    `IOException`

### readDocs

    public Document[] readDocs(DocList ids)
                        throws IOException

  Takes a list of docs (the doc ids actually), and returns an array of Documents containing all of the stored fields.

  Throws:
    `IOException`

### warm

    public void warm(SolrIndexSearcher old)
              throws IOException

  Warm this searcher based on an old one (primarily for auto-cache warming).

  Throws:
    `IOException`

### getCache

    public SolrCache getCache(String cacheName)

  return the named generic cache

### cacheLookup

    public Object cacheLookup(String cacheName,
                              Object key)

  lookup an entry in a generic cache

### cacheInsert

    public Object cacheInsert(String cacheName,
                              Object key,
                              Object val)

  insert an entry in a generic cache

### getOpenTime

    public long getOpenTime()

### explain

    public Explanation explain(Query query,
                               int doc)
                        throws IOException

  Overrides:
    `explain` in class `IndexSearcher`
  Throws:
    `IOException`

### getName

    public String getName()

  Description copied from interface: `SolrInfoMBean`
  Simple common usage name, e.g. BasicQueryHandler, or fully qualified clas name.

  Specified by:
    `getName` in interface `SolrInfoMBean`

### getVersion

    public String getVersion()

  Description copied from interface: `SolrInfoMBean`
  Simple common usage version, e.g. 2.0

  Specified by:
    `getVersion` in interface `SolrInfoMBean`

### getDescription

    public String getDescription()

  Description copied from interface: `SolrInfoMBean`
  Simple one or two line description

  Specified by:
    `getDescription` in interface `SolrInfoMBean`

### getCategory

    public SolrInfoMBean.Category getCategory()

  Description copied from interface: `SolrInfoMBean`
  Purpose of this Class

  Specified by:
    `getCategory` in interface `SolrInfoMBean`

### getSourceId

    public String getSourceId()

  Description copied from interface: `SolrInfoMBean`
  CVS Id, SVN Id, etc

  Specified by:
    `getSourceId` in interface `SolrInfoMBean`

### getSource

    public String getSource()

  Description copied from interface: `SolrInfoMBean`
  CVS Source, SVN Source, etc

  Specified by:
    `getSource` in interface `SolrInfoMBean`

### getDocs

    public URL[] getDocs()

  Description copied from interface: `SolrInfoMBean`
  Documentation URL list.

  Suggested documentation URLs: Homepage for sponsoring project, FAQ on class usage, Design doc for class, Wiki, bug reporting URL, etc...

  Specified by:
    `getDocs` in interface `SolrInfoMBean`

### getStatistics

    public NamedList getStatistics()

  Description copied from interface: `SolrInfoMBean`
  Any statistics this instance would like to be publicly available via the Solr Administration interface.

  Any Object type may be stored in the list, but only the `toString()` representation will be used.

  Specified by:
    `getStatistics` in interface `SolrInfoMBean`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD