Package org.apache.lucene.index
Interface IndexReader.CacheHelper
-
- Enclosing class:
- IndexReader
public static interface IndexReader.CacheHelperA utility class that gives hooks in order to help build a cache based on the data that is contained in this index.- WARNING: This API is experimental and might change in incompatible ways in the next release.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddClosedListener(IndexReader.ClosedListener listener)Add aIndexReader.ClosedListenerwhich will be called when the resource guarded bygetKey()is closed.IndexReader.CacheKeygetKey()Get a key that the resource can be cached on.
-
-
-
Method Detail
-
getKey
IndexReader.CacheKey getKey()
Get a key that the resource can be cached on. The given entry can be compared using identity, ie.Object.equals(java.lang.Object)is implemented as==andObject.hashCode()is implemented asSystem.identityHashCode(java.lang.Object).
-
addClosedListener
void addClosedListener(IndexReader.ClosedListener listener)
Add aIndexReader.ClosedListenerwhich will be called when the resource guarded bygetKey()is closed.
-
-