@Singleton public class HealthStatusSerde extends java.lang.Object implements NullableSerde<io.micronaut.health.HealthStatus>
Serializer.EncoderContext
Deserializer.DecoderContext
Constructor and Description |
---|
HealthStatusSerde() |
Modifier and Type | Method and Description |
---|---|
io.micronaut.health.HealthStatus |
deserializeNonNull(Decoder decoder,
Deserializer.DecoderContext decoderContext,
io.micronaut.core.type.Argument<? super io.micronaut.health.HealthStatus> type)
A method that is invoked when the value is known not to be null.
|
void |
serialize(Encoder encoder,
Serializer.EncoderContext context,
io.micronaut.core.type.Argument<? extends io.micronaut.health.HealthStatus> type,
io.micronaut.health.HealthStatus value)
Serializes the given value using the passed
Encoder . |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createSpecific, isAbsent, isEmpty
allowNull, deserialize
createSpecific, getDefaultValue
public void serialize(Encoder encoder, Serializer.EncoderContext context, io.micronaut.core.type.Argument<? extends io.micronaut.health.HealthStatus> type, io.micronaut.health.HealthStatus value) throws java.io.IOException
Serializer
Encoder
.serialize
in interface Serializer<io.micronaut.health.HealthStatus>
encoder
- The encoder to usecontext
- The encoder context, never null
type
- Models the generic type of the valuevalue
- The value, can be null
java.io.IOException
- If an error occurs during serializationpublic io.micronaut.health.HealthStatus deserializeNonNull(Decoder decoder, Deserializer.DecoderContext decoderContext, io.micronaut.core.type.Argument<? super io.micronaut.health.HealthStatus> type) throws java.io.IOException
NullableDeserializer
deserializeNonNull
in interface NullableDeserializer<io.micronaut.health.HealthStatus>
decoder
- The decoderdecoderContext
- The decoder contexttype
- The typejava.io.IOException
- if something goes wrong during deserialization