public class TermsFacetMap extends JsonFacetMap<TermsFacetMap>
JsonQueryRequest.withFacet(String, Map)
Modifier and Type | Class and Description |
---|---|
static class |
TermsFacetMap.FacetMethod |
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
Constructor and Description |
---|
TermsFacetMap(String fieldName) |
Modifier and Type | Method and Description |
---|---|
TermsFacetMap |
getThis() |
TermsFacetMap |
includeAllBucketsUnionBucket(boolean shouldInclude)
Creates a bucket representing the union of all other buckets.
|
TermsFacetMap |
includeMissingBucket(boolean missingBucket)
Indicates that Solr should create a bucket corresponding to documents missing the field used by this facet.
|
TermsFacetMap |
includeTotalNumBuckets(boolean numBuckets)
Indicates that Solr should include the total number of buckets for this facet.
|
TermsFacetMap |
setBucketOffset(int numToSkip)
Indicates that Solr should skip over the N buckets for this facet.
|
TermsFacetMap |
setFacetMethod(TermsFacetMap.FacetMethod method)
Indicate which method should be used to compute the facet.
|
TermsFacetMap |
setLimit(int maximumBuckets)
Indicates the maximum number of buckets to be returned by this facet.
|
TermsFacetMap |
setMinCount(int minCount)
Indicates that the facet results should not include any buckets with a count less than
minCount . |
TermsFacetMap |
setOverRefine(int numExtraBuckets)
Indicates how many extra buckets to request during distributed-facet-refining beyond those required by
setLimit(int)
Defaults to -1 if not specified, which triggers some heuristic guessing based on other settings. |
TermsFacetMap |
setOverRequest(int numExtraBuckets)
Indicates the number of additional buckets to request internally beyond those required by
setLimit(int) . |
TermsFacetMap |
setPreliminarySort(String preliminarySort)
Indicates an approximate sort calculation to be performed during initial bucket generation and collection.
|
TermsFacetMap |
setSort(String sortString)
Indicates the desired ordering for the returned buckets.
|
TermsFacetMap |
setTermPrefix(String termPrefix)
Indicates that the facet should only produce buckets for terms that start with the specified prefix.
|
TermsFacetMap |
useDistributedFacetRefining(boolean useRefining)
Indicates whether this facet should use distributed facet refining.
|
withDomain, withStatSubFacet, withSubFacet
clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
equals, hashCode, toString
public TermsFacetMap(String fieldName)
public TermsFacetMap getThis()
getThis
in class JsonFacetMap<TermsFacetMap>
public TermsFacetMap setBucketOffset(int numToSkip)
numToSkip
- the number of buckets to skip over before selecting the buckets to returnpublic TermsFacetMap setLimit(int maximumBuckets)
public TermsFacetMap setSort(String sortString)
sort
is calculated for all buckets generated by all shards. If sort
is expensive a
cheaper approximation can be provided using setPreliminarySort(String)
that will be run instead during
bucket collection.setPreliminarySort(String)
public TermsFacetMap setPreliminarySort(String preliminarySort)
prelim_sort
is provided, sort
is calculated on all buckets generated by all shards. If
sort
is expensive, prelim_sort
can be used to provide a cheaper approximation calculation that is
run instead on initial bucket collection. sort
is still used when assembling the final list of buckets.setSort(String)
public TermsFacetMap setOverRequest(int numExtraBuckets)
setLimit(int)
.
Defaults to -1 if not specified, which triggers some heuristic guessing based on other settings.public TermsFacetMap useDistributedFacetRefining(boolean useRefining)
useRefining
- true if distributed facet refining should be used; false otherwisepublic TermsFacetMap setOverRefine(int numExtraBuckets)
setLimit(int)
Defaults to -1 if not specified, which triggers some heuristic guessing based on other settings.public TermsFacetMap setMinCount(int minCount)
minCount
.
Defaults to 1 if not specified.public TermsFacetMap includeMissingBucket(boolean missingBucket)
missingBucket
- true if the special "missing" bucket should be created; false otherwisepublic TermsFacetMap includeTotalNumBuckets(boolean numBuckets)
numBuckets
- true if the "numBuckets" field should be computed; false otherwisepublic TermsFacetMap includeAllBucketsUnionBucket(boolean shouldInclude)
shouldInclude
- true if the union bucket "allBuckets" should be computed; false otherwisepublic TermsFacetMap setTermPrefix(String termPrefix)
public TermsFacetMap setFacetMethod(TermsFacetMap.FacetMethod method)
Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.