convertToCustomClass
fun <T : Any> convertToCustomClass(value: Any?, type: KClass<T>, documentReference: Any? = null): T?(source)
Decodes plain values to an instance of type, found by its serializer, as the Android SDK's CustomClassMapper.convertToCustomClass(Object, Class, DocumentReference) does; null stays null. Any and the product's own value types are returned as they are, like Object and a Timestamp on Android.