SerializersModuleCollector can introspect and accumulate content of any SerializersModule via SerializersModule.dumpTo, using a visitor-like pattern: contextual and polymorphic functions are invoked for each registered serializer.
Not stable for inheritance
SerializersModuleCollector interface is not stable for inheritance in 3rd party libraries, as new methods might be added to this interface or contracts of the existing methods can be changed.
Accept a provider, associated with generic kClass for contextual serialization.
Accept a serializer, associated with kClass for contextual serialization.
Accept a default deserializer provider, associated with the baseClass for polymorphic deserialization.
Accept a default serializer provider, associated with the baseClass for polymorphic serialization.