polymorphicDefault
open override fun <Base : Any> polymorphicDefault(baseClass: KClass<Base>, defaultSerializerProvider: (className: String?) -> DeserializationStrategy<out Base>?)
Content copied to clipboard
Adds a default serializers provider associated with the given baseClass to the resulting module. defaultSerializerProvider is invoked when no polymorphic serializers associated with the className
were found. className
could be null
for formats that support nullable class discriminators (currently only Json
with useArrayPolymorphism
set to false
)