isA<T extends JObject?> method
Whether this object is of the given type
.
For example:
if (object.isA(JLong.type)) {
final i = object.as(JLong.type).longValue;
...
}
Implementation
bool isA<T extends JObject?>(JObjType<T> type) {
final targetJClass = type.jClass;
final canBeCasted = isInstanceOf(targetJClass);
targetJClass.release();
return canBeCasted;
}