Class SimpleObjectSerializer<T>
java.lang.Object
io.micronaut.serde.support.serializers.SimpleObjectSerializer<T>
- Type Parameters:
T
- The bean type
- All Implemented Interfaces:
Serializer<T>
Simple object serializer.
- Since:
- 1.0
- Author:
- Denis Stepanov
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.micronaut.serde.Serializer
Serializer.EncoderContext
-
Constructor Summary
ConstructorDescriptionSimpleObjectSerializer
(io.micronaut.serde.support.serializers.SerBean<Object> serBean) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.micronaut.serde.Serializer
createSpecific, isAbsent, isEmpty
-
Constructor Details
-
SimpleObjectSerializer
-
-
Method Details
-
serialize
public void serialize(Encoder encoder, Serializer.EncoderContext context, io.micronaut.core.type.Argument<? extends T> type, T value) throws IOException Description copied from interface:Serializer
Serializes the given value using the passedEncoder
.- Specified by:
serialize
in interfaceSerializer<T>
- Parameters:
encoder
- The encoder to usecontext
- The encoder context, nevernull
type
- Models the generic type of the valuevalue
- The value, can benull
- Throws:
IOException
- If an error occurs during serialization
-