kotlin instanceof
if (myInstance is String) {
// DO SOMETHING
}
Juligum
if (myInstance is String) {
// DO SOMETHING
}