gh-pages / com.nextfaze.devfun.core / DevFun / instanceOf

instanceOf

fun <T : Any> instanceOf(clazz: KClass<out T>): T (source)

Get an instance of a class using instanceProviders.

Intended for use in Java code, or when type erasure prohibits use of get.

Exceptions

ClassInstanceNotFoundException - When clazz could not be found/instantiated and all providers have been checked.

See Also

get

InstanceProvider