org.apache.lucene.index
Class DocValues.SourceCache.DirectSourceCache
java.lang.Object
org.apache.lucene.index.DocValues.SourceCache
org.apache.lucene.index.DocValues.SourceCache.DirectSourceCache
- Enclosing class:
- DocValues.SourceCache
public static final class DocValues.SourceCache.DirectSourceCache
- extends DocValues.SourceCache
Simple per DocValues
instance cache implementation that holds a
DocValues.Source
a member variable.
If a DocValues.SourceCache.DirectSourceCache
instance is closed or invalidated the cached
reference are simply set to null
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DocValues.SourceCache.DirectSourceCache
public DocValues.SourceCache.DirectSourceCache()
- Sole constructor.
load
public DocValues.Source load(DocValues values)
throws IOException
- Description copied from class:
DocValues.SourceCache
- Atomically loads a
DocValues.Source
into the cache from the given
DocValues
and returns it iff no other DocValues.Source
has already
been cached. Otherwise the cached source is returned.
This method will not return null
- Specified by:
load
in class DocValues.SourceCache
- Throws:
IOException
invalidate
public void invalidate(DocValues values)
- Description copied from class:
DocValues.SourceCache
- Atomically invalidates the cached
DocValues.Source
instances if any and empties the cache.
- Specified by:
invalidate
in class DocValues.SourceCache
Copyright © 2000-2012 Apache Software Foundation. All Rights Reserved.