|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectkoala.dynamicjava.classinfo.TreeClassInfo
The instances of this class provides informations about classes not yet compiled to JVM bytecode and represented by a syntax tree
Field Summary | |
static java.lang.String |
ANONYMOUS_DECLARING_CLASS
The declaringClass property is defined for each anonymous inner class/interface declaration It contains a TypeDeclaration |
Constructor Summary | |
TreeClassInfo(TreeClassInfo ci)
Creates a new array class info |
|
TreeClassInfo(TypeDeclaration cd,
ClassFinder cf)
Creates a new class info |
Method Summary | |
boolean |
equals(java.lang.Object obj)
Indicates whether some other object is "equal to" this one |
ClassInfo |
getAnonymousDeclaringClass()
Returns the declaring class of an anonymous class or null |
ClassInfo |
getArrayType()
Returns the array type that contains elements of this class |
ClassFinder |
getClassFinder()
Returns the class finder |
ClassInfo |
getComponentType()
Returns the component type of this array type |
ConstructorInfo[] |
getConstructors()
Returns the constructor infos for the current class |
ClassInfo[] |
getDeclaredClasses()
Returns the classes and interfaces declared as members of the class represented by this ClassInfo object. |
ClassInfo |
getDeclaringClass()
Returns the declaring class or null |
FieldInfo |
getField(FieldDeclaration node)
Returns the field represented by the given node |
FieldInfo[] |
getFields()
Returns the field infos for the current class |
ClassInfo[] |
getInterfaces()
Returns the class infos of the interfaces implemented by the class this info represents |
java.lang.Class |
getJavaClass()
Returns the underlying class |
MethodInfo |
getMethod(MethodDeclaration node)
Returns the method represented by the given node |
MethodInfo[] |
getMethods()
Returns the method infos for the current class |
int |
getModifiers()
Returns the modifiers flags |
java.lang.String |
getName()
Returns the fully qualified name of the underlying class |
ClassInfo |
getSuperclass()
Returns the class info of the superclass of the class represented by this class |
TypeDeclaration |
getTypeDeclaration()
Returns the abstract syntax tree |
boolean |
isArray()
Whether this object represents an array |
boolean |
isCompilable()
Whether the underlying class needs compilation |
boolean |
isInterface()
Whether this object represents an interface |
boolean |
isPrimitive()
Whether this object represents a primitive type |
void |
setCompilable(boolean b)
Sets the compilable property |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String ANONYMOUS_DECLARING_CLASS
Constructor Detail |
public TreeClassInfo(TypeDeclaration cd, ClassFinder cf)
cd
- the class declarationcf
- the class finderpublic TreeClassInfo(TreeClassInfo ci)
ci
- the class infoMethod Detail |
public java.lang.Class getJavaClass()
getJavaClass
in interface ClassInfo
public TypeDeclaration getTypeDeclaration()
public ClassFinder getClassFinder()
public boolean isCompilable()
isCompilable
in interface ClassInfo
public void setCompilable(boolean b)
setCompilable
in interface ClassInfo
public ClassInfo getDeclaringClass()
getDeclaringClass
in interface ClassInfo
public ClassInfo getAnonymousDeclaringClass()
getAnonymousDeclaringClass
in interface ClassInfo
public int getModifiers()
getModifiers
in interface ClassInfo
public java.lang.String getName()
getName
in interface ClassInfo
public ClassInfo getSuperclass()
getSuperclass
in interface ClassInfo
java.lang.NoClassDefFoundError
- if the class cannot be loadedpublic ClassInfo[] getInterfaces()
getInterfaces
in interface ClassInfo
java.lang.NoClassDefFoundError
- if an interface cannot be loadedpublic FieldInfo getField(FieldDeclaration node)
node
- the node that represents the fieldpublic FieldInfo[] getFields()
getFields
in interface ClassInfo
public ConstructorInfo[] getConstructors()
getConstructors
in interface ClassInfo
public MethodInfo getMethod(MethodDeclaration node)
node
- the node that represents the methodpublic MethodInfo[] getMethods()
getMethods
in interface ClassInfo
public ClassInfo[] getDeclaredClasses()
getDeclaredClasses
in interface ClassInfo
public ClassInfo getArrayType()
getArrayType
in interface ClassInfo
public boolean isInterface()
isInterface
in interface ClassInfo
public boolean isArray()
isArray
in interface ClassInfo
public boolean isPrimitive()
isPrimitive
in interface ClassInfo
public ClassInfo getComponentType()
getComponentType
in interface ClassInfo
java.lang.IllegalStateException
- if this type do not represent an arraypublic boolean equals(java.lang.Object obj)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |