public class IdsQueryBuilder extends AbstractQueryBuilder<IdsQueryBuilder>
Writeable.Reader<V>, Writeable.Writer<V>
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
NAME |
boost, BOOST_FIELD, DEFAULT_BOOST, NAME_FIELD, queryName
EMPTY_PARAMS
Constructor and Description |
---|
IdsQueryBuilder()
Creates a new IdsQueryBuilder with no types specified upfront
|
IdsQueryBuilder(StreamInput in)
Read from a stream.
|
IdsQueryBuilder(java.lang.String... types)
Deprecated.
Replaced by
types(String...) |
Modifier and Type | Method and Description |
---|---|
IdsQueryBuilder |
addIds(java.lang.String... ids)
Adds ids to the query.
|
protected boolean |
doEquals(IdsQueryBuilder other)
Indicates whether some other
QueryBuilder object of the same type is "equal to" this one. |
protected int |
doHashCode() |
protected org.apache.lucene.search.Query |
doToQuery(QueryShardContext context) |
protected void |
doWriteTo(StreamOutput out) |
protected void |
doXContent(XContentBuilder builder,
ToXContent.Params params) |
static java.util.Optional<IdsQueryBuilder> |
fromXContent(QueryParseContext context) |
java.lang.String |
getWriteableName()
Returns the name of the writeable object
|
java.util.Set<java.lang.String> |
ids()
Returns the ids for the query.
|
java.lang.String[] |
types()
Returns the types used in this query
|
IdsQueryBuilder |
types(java.lang.String... types)
Add types to query
|
addValidationError, boost, boost, convertToBytesRefIfString, convertToStringIfBytesRef, declareStandardFields, doRewrite, equals, extractInnerHitBuilders, getName, hashCode, printBoostAndQueryName, queryName, queryName, readQueries, requireValue, rewrite, throwParsingExceptionOnMultipleFields, toFilter, toQueries, toQuery, toXContent, writeQueries, writeTo
buildAsBytes, buildAsBytes, toString, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
rewriteQuery
isFragment
public static final java.lang.String NAME
public IdsQueryBuilder()
@Deprecated public IdsQueryBuilder(java.lang.String... types)
types(String...)
public IdsQueryBuilder(StreamInput in) throws java.io.IOException
java.io.IOException
protected void doWriteTo(StreamOutput out) throws java.io.IOException
doWriteTo
in class AbstractQueryBuilder<IdsQueryBuilder>
java.io.IOException
public IdsQueryBuilder types(java.lang.String... types)
public java.lang.String[] types()
public IdsQueryBuilder addIds(java.lang.String... ids)
public java.util.Set<java.lang.String> ids()
protected void doXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
doXContent
in class AbstractQueryBuilder<IdsQueryBuilder>
java.io.IOException
public static java.util.Optional<IdsQueryBuilder> fromXContent(QueryParseContext context)
public java.lang.String getWriteableName()
NamedWriteable
protected org.apache.lucene.search.Query doToQuery(QueryShardContext context) throws java.io.IOException
doToQuery
in class AbstractQueryBuilder<IdsQueryBuilder>
java.io.IOException
protected int doHashCode()
doHashCode
in class AbstractQueryBuilder<IdsQueryBuilder>
protected boolean doEquals(IdsQueryBuilder other)
AbstractQueryBuilder
QueryBuilder
object of the same type is "equal to" this one.doEquals
in class AbstractQueryBuilder<IdsQueryBuilder>