Module org.elasticsearch.server
Class IncludeExclude
java.lang.Object
org.elasticsearch.search.aggregations.bucket.terms.IncludeExclude
- All Implemented Interfaces:
Writeable,ToXContent,ToXContentFragment
Defines the include/exclude regular expression filtering for string terms aggregation. In this filtering logic,
exclusion has precedence, where the
include is evaluated first and then the exclude.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classstatic classclassstatic classstatic classNested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.ParamsNested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ParseFieldstatic final ParseFieldstatic final ParseFieldstatic final ParseFieldFields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS -
Constructor Summary
ConstructorsConstructorDescriptionIncludeExclude(int partition, int numPartitions) IncludeExclude(String include, String exclude, SortedSet<org.apache.lucene.util.BytesRef> includeValues, SortedSet<org.apache.lucene.util.BytesRef> excludeValues) Read from a stream. -
Method Summary
Modifier and TypeMethodDescriptionconvertToLongFilter(DocValueFormat format) convertToStringFilter(DocValueFormat format) booleaninthashCode()booleanbooleanstatic IncludeExcludemerge(IncludeExclude include, IncludeExclude exclude) static IncludeExcludeparseExclude(XContentParser parser) static IncludeExcludeparseInclude(XContentParser parser) toXContent(XContentBuilder builder, ToXContent.Params params) voidwriteTo(StreamOutput out) Write this into the StreamOutput.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.xcontent.ToXContentFragment
isFragment
-
Field Details
-
INCLUDE_FIELD
-
EXCLUDE_FIELD
-
PARTITION_FIELD
-
NUM_PARTITIONS_FIELD
-
-
Constructor Details
-
IncludeExclude
public IncludeExclude(@Nullable String include, @Nullable String exclude, @Nullable SortedSet<org.apache.lucene.util.BytesRef> includeValues, @Nullable SortedSet<org.apache.lucene.util.BytesRef> excludeValues) - Parameters:
include- The regular expression pattern for the terms to be includedexclude- The regular expression pattern for the terms to be excluded
-
IncludeExclude
public IncludeExclude(int partition, int numPartitions) -
IncludeExclude
Read from a stream.- Throws:
IOException
-
-
Method Details
-
merge
-
parseInclude
- Throws:
IOException
-
parseExclude
- Throws:
IOException
-
writeTo
Description copied from interface:WriteableWrite this into the StreamOutput.- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
isRegexBased
public boolean isRegexBased() -
isPartitionBased
public boolean isPartitionBased() -
convertToStringFilter
-
convertToOrdinalsFilter
-
convertToLongFilter
-
convertToDoubleFilter
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException - Specified by:
toXContentin interfaceToXContent- Throws:
IOException
-
hashCode
public int hashCode() -
equals
-