public class FacetImpl extends java.lang.Object implements Facet
FacetImpl
is a simple implementation of the Facet
interface, which basically holds a collection of Buckets
.
Note that this class resides in a public package (OSGi) for easy reuse of
custom FacetExtractors
.
Constructor and Description |
---|
FacetImpl()
Creates a facet without any buckets.
|
FacetImpl(java.util.Collection<? extends Bucket> buckets)
Creates a facet with a given list of buckets.
|
Modifier and Type | Method and Description |
---|---|
void |
addBucket(Bucket bucket)
Adds a bucket to the list of buckets that will be returned in
getBuckets() . |
java.util.List<Bucket> |
getBuckets()
Returns the buckets for this facet.
|
boolean |
getContainsHit() |
public FacetImpl()
addBucket(Bucket)
to
add buckets one by one.public FacetImpl(java.util.Collection<? extends Bucket> buckets)
public void addBucket(Bucket bucket)
getBuckets()
.public java.util.List<Bucket> getBuckets()
Facet
getBuckets
in interface Facet
public boolean getContainsHit()
getContainsHit
in interface Facet
true
if any of the buckets contains a hit,
false
otherwise.Copyright © 2010 - 2020 Adobe. All Rights Reserved