Is it possible to cast a value to a `KType` or che...
# reflect
f
Is it possible to cast a value to a
KType
or check whether a value is of the type (or if necessary the classifier)?
d
You can only check it for raw types, e.g. you can check if something is a
List
, but not if it's a
List<String>
. You can use
KType.classifier
to get the classifier (which can be a class or type parameter) and then check that.