Class AliasFilter
- java.lang.Object
-
- org.elasticsearch.search.internal.AliasFilter
-
- All Implemented Interfaces:
Writeable,Rewriteable<AliasFilter>
public final class AliasFilter extends java.lang.Object implements Writeable, Rewriteable<AliasFilter>
Represents aQueryBuilderand a list of alias names that filters the builder is composed of.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
Fields Modifier and Type Field Description static AliasFilterEMPTY-
Fields inherited from interface org.elasticsearch.index.query.Rewriteable
MAX_REWRITE_ROUNDS
-
-
Constructor Summary
Constructors Constructor Description AliasFilter(StreamInput input)AliasFilter(QueryBuilder filter, java.lang.String... aliases)
-
Method Summary
Modifier and Type Method Description booleanequals(java.lang.Object o)java.lang.String[]getAliases()Returns the aliases patters that are used to compose theQueryBuilderreturned fromgetQueryBuilder()QueryBuildergetQueryBuilder()Returns the alias filterQueryBuilderornullif there is no such filterinthashCode()AliasFilterrewrite(QueryRewriteContext context)Rewrites this instance based on the provided context.java.lang.StringtoString()voidwriteTo(StreamOutput out)Write this into the StreamOutput.
-
-
-
Field Detail
-
EMPTY
public static final AliasFilter EMPTY
-
-
Constructor Detail
-
AliasFilter
public AliasFilter(QueryBuilder filter, java.lang.String... aliases)
-
AliasFilter
public AliasFilter(StreamInput input) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
rewrite
public AliasFilter rewrite(QueryRewriteContext context) throws java.io.IOException
Description copied from interface:RewriteableRewrites this instance based on the provided context. The returned objects will be the same instance as this if no changes during the rewrite were applied.- Specified by:
rewritein interfaceRewriteable<AliasFilter>- Throws:
java.io.IOException
-
writeTo
public void writeTo(StreamOutput out) throws java.io.IOException
Description copied from interface:WriteableWrite this into the StreamOutput.
-
getAliases
public java.lang.String[] getAliases()
Returns the aliases patters that are used to compose theQueryBuilderreturned fromgetQueryBuilder()
-
getQueryBuilder
public QueryBuilder getQueryBuilder()
Returns the alias filterQueryBuilderornullif there is no such filter
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-