public final class NotDocIdSet extends DocIdSet
DocIdSetencodes the negation of another
DocIdSet. It is cacheable and supports random-access if the underlying set is cacheable and supports random-access.
|Constructor and Description|
|Modifier and Type||Method and Description|
Optionally provides a
This method is a hint for
Return the memory usage of this object in bytes.
public NotDocIdSet(int maxDoc, DocIdSet in)
public boolean isCacheable()
CachingWrapperFilter, if this
DocIdSetshould be cached without copying it. The default is to return
false. If you have an own
DocIdSetimplementation that does its iteration very effective and fast without doing disk I/O, override this method and return
public Bits bits() throws IOException
Bitsinterface for random access to matching documents.
null, if this
DocIdSetdoes not support random access. In contrast to
DocIdSet.iterator(), a return value of
nulldoes not imply that no documents match the filter! The default implementation does not provide random access, so you only need to implement this method if your DocIdSet can guarantee random access to every docid in O(1) time without external disk access (as
Bitsinterface cannot throw
IOException). This is generally true for bit sets like
FixedBitSet, which return itself if they are used as
public long ramBytesUsed()
Copyright © 2000-2017 Apache Software Foundation. All Rights Reserved.