public class InitializedClassUtil
extends java.lang.Object
Clazz
that require initialization of the ClassPool
s to work (i.e., ClassReferenceInitializer
, ClassSubHierarchyInitializer
, and ClassSuperHierarchyInitializer
should have run on the
class pools).
The methods provide no guarantee that the initialization has been performed, the callers should make sure of it to avoid unexpected behavior or crashes.
Modifier and Type | Method and Description |
---|---|
static boolean |
isInstanceOf(java.lang.String type,
@NotNull Clazz clazz)
Returns true if the given type is instance of the given clazz (i.e.
|
public static boolean isInstanceOf(java.lang.String type, @NotNull @NotNull Clazz clazz)
If the type is a reference array checks the inheritance of the referenced type (e.g. true for "[Ljava/lang/String;" and Clazz{java/lang/Object}, false for "[Ljava/lang/String;" and Clazz{java/lan/Boolean}).
Requires that at least ClassReferenceInitializer
and ClassSubHierarchyInitializer
have been run on the ClassPool
s.