Class Preprocessor
java.lang.Object
co.elastic.clients.elasticsearch.ml.put_trained_model.Preprocessor
- All Implemented Interfaces:
JsonpSerializable
,TaggedUnion<Preprocessor.Kind,java.lang.Object>
@JsonpDeserializable public class Preprocessor extends java.lang.Object implements TaggedUnion<Preprocessor.Kind,java.lang.Object>, JsonpSerializable
- See Also:
- API specification
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Preprocessor.Builder
static class
Preprocessor.Kind
Preprocessor
variant kinds. -
Field Summary
Fields Modifier and Type Field Description static JsonpDeserializer<Preprocessor>
_DESERIALIZER
-
Constructor Summary
Constructors Constructor Description Preprocessor(PreprocessorVariant value)
-
Method Summary
Modifier and Type Method Description java.lang.Object
_get()
Preprocessor.Kind
_kind()
Get the of the kind of variant held by this object.FrequencyEncodingPreprocessor
frequencyEncoding()
Get thefrequency_encoding
variant value.boolean
isFrequencyEncoding()
Is this variant instance of kindfrequency_encoding
?boolean
isOneHotEncoding()
Is this variant instance of kindone_hot_encoding
?boolean
isTargetMeanEncoding()
Is this variant instance of kindtarget_mean_encoding
?static Preprocessor
of(java.util.function.Function<Preprocessor.Builder,ObjectBuilder<Preprocessor>> fn)
OneHotEncodingPreprocessor
oneHotEncoding()
Get theone_hot_encoding
variant value.void
serialize(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper)
protected static void
setupPreprocessorDeserializer(ObjectDeserializer<Preprocessor.Builder> op)
TargetMeanEncodingPreprocessor
targetMeanEncoding()
Get thetarget_mean_encoding
variant value.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
_DESERIALIZER
-
-
Constructor Details
-
Preprocessor
-
-
Method Details
-
_kind
Description copied from interface:TaggedUnion
Get the of the kind of variant held by this object.- Specified by:
_kind
in interfaceTaggedUnion<Preprocessor.Kind,java.lang.Object>
- Returns:
- the variant kind
-
_get
public final java.lang.Object _get()- Specified by:
_get
in interfaceTaggedUnion<Preprocessor.Kind,java.lang.Object>
-
of
public static Preprocessor of(java.util.function.Function<Preprocessor.Builder,ObjectBuilder<Preprocessor>> fn) -
isFrequencyEncoding
public boolean isFrequencyEncoding()Is this variant instance of kindfrequency_encoding
? -
frequencyEncoding
Get thefrequency_encoding
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of thefrequency_encoding
kind.
-
isOneHotEncoding
public boolean isOneHotEncoding()Is this variant instance of kindone_hot_encoding
? -
oneHotEncoding
Get theone_hot_encoding
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of theone_hot_encoding
kind.
-
isTargetMeanEncoding
public boolean isTargetMeanEncoding()Is this variant instance of kindtarget_mean_encoding
? -
targetMeanEncoding
Get thetarget_mean_encoding
variant value.- Throws:
java.lang.IllegalStateException
- if the current variant is not of thetarget_mean_encoding
kind.
-
serialize
- Specified by:
serialize
in interfaceJsonpSerializable
-
setupPreprocessorDeserializer
-