Class SourceConfigParam
- java.lang.Object
-
- org.opensearch.client.opensearch.core.search.SourceConfigParam
-
- All Implemented Interfaces:
JsonpSerializable
,TaggedUnion<SourceConfigParam.Kind,java.lang.Object>
@JsonpDeserializable public class SourceConfigParam extends java.lang.Object implements TaggedUnion<SourceConfigParam.Kind,java.lang.Object>, JsonpSerializable
Defines how to fetch a source. Fetching can be disabled entirely, or the source can be filtered. Used as a query parameter along with the_source_includes
and_source_excludes
parameters.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
SourceConfigParam.Builder
static class
SourceConfigParam.Kind
-
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<SourceConfigParam>
_DESERIALIZER
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
_get()
SourceConfigParam.Kind
_kind()
Get the of the kind of variant held by this object.java.lang.String
_toJsonString()
java.lang.Boolean
fetch()
Get thefetch
variant value.java.util.List<java.lang.String>
fields()
Get thefields
variant value.boolean
isFetch()
Is this variant instance of kindfetch
?boolean
isFields()
Is this variant instance of kindfields
?static SourceConfigParam
of(java.util.function.Function<SourceConfigParam.Builder,ObjectBuilder<SourceConfigParam>> fn)
void
serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
-
-
-
Field Detail
-
_DESERIALIZER
public static final JsonpDeserializer<SourceConfigParam> _DESERIALIZER
-
-
Method Detail
-
_kind
public final SourceConfigParam.Kind _kind()
Description copied from interface:TaggedUnion
Get the of the kind of variant held by this object.- Specified by:
_kind
in interfaceTaggedUnion<SourceConfigParam.Kind,java.lang.Object>
- Returns:
- the variant kind
-
_get
public final java.lang.Object _get()
- Specified by:
_get
in interfaceTaggedUnion<SourceConfigParam.Kind,java.lang.Object>
-
_toJsonString
public java.lang.String _toJsonString()
-
of
public static SourceConfigParam of(java.util.function.Function<SourceConfigParam.Builder,ObjectBuilder<SourceConfigParam>> fn)
-
isFields
public boolean isFields()
Is this variant instance of kindfields
?
-
fields
public java.util.List<java.lang.String> fields()
Get thefields
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of thefields
kind.
-
isFetch
public boolean isFetch()
Is this variant instance of kindfetch
?
-
fetch
public java.lang.Boolean fetch()
Get thefetch
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of thefetch
kind.
-
serialize
public void serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
- Specified by:
serialize
in interfaceJsonpSerializable
-
-