Typed Serializer
A serializer that includes type information in the serialized output. This allows polymorphic serialization where the exact type is preserved in the output as a "type" field alongside the "value" field.
The serialized format is: {"type": "TypeName", "value": {...}}
Parameters
The Kotlin class of the base type
A map of type names to their serializers for known subtypes
Type Parameters
The base type that this serializer handles
Constructors
Functions
Will create MapperDeserializationStrategy to allow you to map I to O using deserialize lambda during deserialization process
Will create MapperSerializer to allow you to map O to I and vice verse using serialize/deserialize lambda during serialization/deserialization process
Will create MapperSerializationStrategy to allow you to map O to I using serialize lambda during serialization process
Removes a type from this TypedSerializer using its class name.
Adds a type to this TypedSerializer using its class name as the type identifier.