Interface FormattedSerializer<T>
- Type Parameters:
T- The type to be serialized
- All Superinterfaces:
Serializer<T>
- All Known Subinterfaces:
FormattedSerde<T>, NumberSerde<N>, TemporalSerde<T>
- All Known Implementing Classes:
DefaultFormattedTemporalSerde, InstantSerde, LocalDateSerde, LocalDateTimeSerde, LocalTimeSerde, ObjectArraySerde, OffsetDateTimeSerde, YearSerde, ZonedDateTimeSerde
A serializer that can react to format metadata.
- Since:
- 3.0
- Author:
- Denis Stepanov
-
Nested Class Summary
Nested classes/interfaces inherited from interface Serializer
Serializer.EncoderContext -
Method Summary
Modifier and TypeMethodDescriptiondefault Serializer<T> createSpecific(Serializer.EncoderContext context, io.micronaut.core.type.Argument<? extends T> type, FormatConfiguration format) Create a more specific serializer for the given definition and format configuration.Methods inherited from interface Serializer
createSpecific, isAbsent, isDefault, isEmpty, serialize
-
Method Details
-
createSpecific
default Serializer<T> createSpecific(Serializer.EncoderContext context, io.micronaut.core.type.Argument<? extends T> type, FormatConfiguration format) throws SerdeException Create a more specific serializer for the given definition and format configuration.- Parameters:
context- The encoder contexttype- The type definition including any annotation metadataformat- The format configuration- Returns:
- The more specific serializer
- Throws:
SerdeException- If the serializer cannot be selected
-