Package org.apache.lucene.search
Class LRUQueryCache.LeafCache
- java.lang.Object
-
- org.apache.lucene.search.LRUQueryCache.LeafCache
-
- All Implemented Interfaces:
Accountable
- Enclosing class:
- LRUQueryCache
private class LRUQueryCache.LeafCache extends java.lang.Object implements Accountable
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Map<Query,DocIdSet>cacheprivate java.lang.Objectkeyprivate longramBytesUsed-
Fields inherited from interface org.apache.lucene.util.Accountable
NULL_ACCOUNTABLE
-
-
Constructor Summary
Constructors Constructor Description LeafCache(java.lang.Object key)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) DocIdSetget(Query query)private voidonDocIdSetCache(long ramBytesUsed)private voidonDocIdSetEviction(long ramBytesUsed)(package private) voidputIfAbsent(Query query, DocIdSet set)longramBytesUsed()Return the memory usage of this object in bytes.(package private) voidremove(Query query)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.lucene.util.Accountable
getChildResources
-
-
-
-
Method Detail
-
onDocIdSetCache
private void onDocIdSetCache(long ramBytesUsed)
-
onDocIdSetEviction
private void onDocIdSetEviction(long ramBytesUsed)
-
remove
void remove(Query query)
-
ramBytesUsed
public long ramBytesUsed()
Description copied from interface:AccountableReturn the memory usage of this object in bytes. Negative values are illegal.- Specified by:
ramBytesUsedin interfaceAccountable
-
-