Package com.yahoo.document.select
Class BucketSet
- All Implemented Interfaces:
Serializable
,Cloneable
,Iterable<BucketId>
,Collection<BucketId>
,Set<BucketId>
A set of bucket ids covered by a document selector.
- Author:
- Simon Thoresen Hult
- See Also:
-
Constructor Summary
-
Method Summary
Methods inherited from class java.util.HashSet
add, clear, clone, contains, isEmpty, iterator, remove, size, spliterator, toArray, toArray
Methods inherited from class java.util.AbstractSet
equals, hashCode, removeAll
Methods inherited from class java.util.AbstractCollection
addAll, containsAll, retainAll, toString
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Constructor Details
-
BucketSet
public BucketSet()Constructs a new bucket set that contains no ids. -
BucketSet
Constructs a new bucket set that contains a single id.- Parameters:
id
- The id to add to this as initial value.
-
BucketSet
Constructs a new bucket set that is a copy of another.- Parameters:
set
- The set to copy.
-
-
Method Details
-
intersection
Returns the intersection between this bucket set and another.- Parameters:
rhs
- The set to form an intersection with.- Returns:
- The intersection.
-
union
Returns the union between this bucket set and another.- Parameters:
rhs
- The set to form a union with.- Returns:
- The union.
-