Package javassist
Class CtArray
java.lang.Object
javassist.CtClass
javassist.CtArray
Array types.
-
Nested Class Summary
Nested classes/interfaces inherited from class javassist.CtClass
CtClass.DelayedFileOutputStream
-
Field Summary
FieldsFields inherited from class javassist.CtClass
booleanType, byteType, charType, debugDump, doubleType, floatType, intType, javaLangObject, longType, primitiveTypes, qualifiedName, shortType, version, voidType
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns aClassPool
for this class.If this object represents an array, this method returns the component type of the array.Returns an array containingCtConstructor
objects representing all the non-private constructors of the class.CtClass[]
Obtains the class objects representing the interfaces implemented by the class or, if this object represents an interface, the interfaces extended by that interface.Returns the method with the given name and signature.CtMethod[]
Returns an array containingCtMethod
objects representing all the non-private methods of the class.int
Returns the modifiers for this class, encoded in an integer.Obtains the class object representing the superclass of the class.boolean
isArray()
Returnstrue
if this object represents an array type.boolean
Returnstrue
if this class extends or implementsclazz
.Methods inherited from class javassist.CtClass
addConstructor, addField, addField, addField, addInterface, addMethod, checkModify, compress, debugWriteFile, debugWriteFile, defrost, detach, extendToString, freeze, getAccessorMaker, getAnnotation, getAnnotations, getAttribute, getAvailableAnnotations, getClassFile, getClassFile2, getClassInitializer, getConstructor, getDeclaredBehaviors, getDeclaredClasses, getDeclaredConstructor, getDeclaredConstructors, getDeclaredField, getDeclaredField, getDeclaredFields, getDeclaredMethod, getDeclaredMethod, getDeclaredMethods, getDeclaredMethods, getDeclaringClass, getEnclosingBehavior, getEnclosingMethod, getField, getField, getField2, getFields, getGenericSignature, getName, getNestedClasses, getPackageName, getRefClasses, getSimpleName, getURL, hasAnnotation, hasAnnotation, incGetCounter, instrument, instrument, isAnnotation, isEnum, isFrozen, isInterface, isKotlin, isModified, isPrimitive, main, makeClassInitializer, makeFileOutput, makeNestedClass, makeUniqueName, prune, rebuildClassFile, removeConstructor, removeField, removeMethod, replaceClassName, replaceClassName, setAttribute, setGenericSignature, setInterfaces, setModifiers, setName, setSuperclass, stopPruning, subclassOf, toBytecode, toBytecode, toClass, toClass, toClass, toClass, toClass, toString, writeFile, writeFile
-
Field Details
-
pool
-
interfaces
-
-
Constructor Details
-
CtArray
-
-
Method Details
-
getClassPool
Description copied from class:CtClass
Returns aClassPool
for this class.- Overrides:
getClassPool
in classCtClass
-
isArray
public boolean isArray()Description copied from class:CtClass
Returnstrue
if this object represents an array type. -
getModifiers
public int getModifiers()Description copied from class:CtClass
Returns the modifiers for this class, encoded in an integer. For decoding, usejavassist.Modifier
.If the class is a static nested class (a.k.a. static inner class), the returned modifiers include
Modifier.STATIC
.- Overrides:
getModifiers
in classCtClass
- See Also:
-
getInterfaces
Description copied from class:CtClass
Obtains the class objects representing the interfaces implemented by the class or, if this object represents an interface, the interfaces extended by that interface.- Overrides:
getInterfaces
in classCtClass
- Throws:
NotFoundException
-
subtypeOf
Description copied from class:CtClass
Returnstrue
if this class extends or implementsclazz
. It also returnstrue
if this class is the same asclazz
.- Overrides:
subtypeOf
in classCtClass
- Throws:
NotFoundException
-
getComponentType
Description copied from class:CtClass
If this object represents an array, this method returns the component type of the array. Otherwise, it returnsnull
.- Overrides:
getComponentType
in classCtClass
- Throws:
NotFoundException
-
getSuperclass
Description copied from class:CtClass
Obtains the class object representing the superclass of the class. It returns null if this object represents thejava.lang.Object
class and thus it does not have the super class.If this object represents an interface, this method always returns the
java.lang.Object
class. To obtain the super interfaces extended by that interface, callgetInterfaces()
.- Overrides:
getSuperclass
in classCtClass
- Throws:
NotFoundException
-
getMethods
Description copied from class:CtClass
Returns an array containingCtMethod
objects representing all the non-private methods of the class. That array includes non-private methods inherited from the superclasses.- Overrides:
getMethods
in classCtClass
-
getMethod
Description copied from class:CtClass
Returns the method with the given name and signature. The returned method may be declared in a super class. The method signature is represented by a character string called method descriptor, which is defined in the JVM specification.- Overrides:
getMethod
in classCtClass
- Parameters:
name
- method namedesc
- method descriptor- Throws:
NotFoundException
- See Also:
-
getConstructors
Description copied from class:CtClass
Returns an array containingCtConstructor
objects representing all the non-private constructors of the class.- Overrides:
getConstructors
in classCtClass
-