Firebase\'s snapshot.getValue() expects to be called as follows:
snapshot.getValue()
snapshot?.getValue(Person::class.java)
However I would like t
Using typeOf is another option. (Added in Kotlin 1.3)
Example:
@OptIn(ExperimentalStdlibApi::class) inline fun someMethod(data: T) { val typeClassifier = typeOf().classifier if (typeClassifier == List::class) { //Do something } }