Package com.yahoo.document.select
Class BucketSelector
java.lang.Object
com.yahoo.document.select.BucketSelector
This class is used to find out in which locations a document might be in, if
it matches a given document selection string.
- Author:
- Håkon Humberset
-
Constructor Summary
ConstructorDescriptionBucketSelector
(BucketIdFactory factory) The bucket selector needs to be instantiated to be used, as it will depend on config. -
Method Summary
Modifier and TypeMethodDescriptiongetBucketList
(String selector) Get the set of buckets that may contain documents that match the given document selection, as long as the document selection does not result in an unknown set of buckets.
-
Constructor Details
-
BucketSelector
The bucket selector needs to be instantiated to be used, as it will depend on config.- Parameters:
factory
- The bucket factory is needed to get information of how bucket ids are put together.
-
-
Method Details
-
getBucketList
Get the set of buckets that may contain documents that match the given document selection, as long as the document selection does not result in an unknown set of buckets. If it does,null
will be returned. This requires the caller to be aware of the meaning of these return values, but also removes the need for redundant space utilization when dealing with unknown bucket sets.- Parameters:
selector
- The document selection string- Returns:
- a list of buckets with arbitrary number of location bits set,
or,
null
if the document selection resulted in an unknown set - Throws:
ParseException
- ifselector
couldn't be parsed
-