Class SmoothingModel
java.lang.Object
co.elastic.clients.elasticsearch._core.search.SmoothingModel
- All Implemented Interfaces:
JsonpSerializable
,TaggedUnion<java.lang.Object>
@JsonpDeserializable public class SmoothingModel extends java.lang.Object implements TaggedUnion<java.lang.Object>, JsonpSerializable
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
SmoothingModel.Builder
-
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<SmoothingModel>
_DESERIALIZER
static java.lang.String
LAPLACE
static java.lang.String
LINEAR_INTERPOLATION
static java.lang.String
STUPID_BACKOFF
-
Constructor Summary
Constructors Constructor Description SmoothingModel(SmoothingModelVariant value)
SmoothingModel(ObjectBuilder<T> builder)
SmoothingModel(java.util.function.Function<SmoothingModel.Builder,SmoothingModel.Builder> fn)
-
Method Summary
Modifier and Type Method Description java.lang.Object
_get()
java.lang.String
_type()
Get the of the type of the variant held by this union object.LaplaceSmoothingModel
laplace()
Get thelaplace
variant value.LinearInterpolationSmoothingModel
linearInterpolation()
Get thelinear_interpolation
variant value.void
serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
protected static void
setupSmoothingModelDeserializer(DelegatingDeserializer<SmoothingModel.Builder> op)
StupidBackoffSmoothingModel
stupidBackoff()
Get thestupid_backoff
variant value.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface co.elastic.clients.util.TaggedUnion
_is
-
Field Details
-
LAPLACE
public static final java.lang.String LAPLACE- See Also:
- Constant Field Values
-
LINEAR_INTERPOLATION
public static final java.lang.String LINEAR_INTERPOLATION- See Also:
- Constant Field Values
-
STUPID_BACKOFF
public static final java.lang.String STUPID_BACKOFF- See Also:
- Constant Field Values
-
_DESERIALIZER
-
-
Constructor Details
-
SmoothingModel
-
SmoothingModel
-
SmoothingModel
public SmoothingModel(java.util.function.Function<SmoothingModel.Builder,SmoothingModel.Builder> fn)
-
-
Method Details
-
_type
public java.lang.String _type()Description copied from interface:TaggedUnion
Get the of the type of the variant held by this union object.- Specified by:
_type
in interfaceTaggedUnion<java.lang.Object>
- Returns:
- the variant type
-
_get
public java.lang.Object _get()- Specified by:
_get
in interfaceTaggedUnion<java.lang.Object>
-
laplace
Get thelaplace
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of thelaplace
kind.
-
linearInterpolation
Get thelinear_interpolation
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of thelinear_interpolation
kind.
-
stupidBackoff
Get thestupid_backoff
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of thestupid_backoff
kind.
-
serialize
- Specified by:
serialize
in interfaceJsonpSerializable
-
setupSmoothingModelDeserializer
protected static void setupSmoothingModelDeserializer(DelegatingDeserializer<SmoothingModel.Builder> op)
-