public abstract class AstFunctionClass extends Object implements IClass, ClassConstants
Modifier and Type | Field and Description |
---|---|
protected IMethod |
functionBody |
ACC_ABSTRACT, ACC_FINAL, ACC_INTERFACE, ACC_NATIVE, ACC_PRIVATE, ACC_PROTECTED, ACC_PUBLIC, ACC_STATIC, ACC_STRICT, ACC_SUPER, ACC_SYNCHRONIZED, ACC_TRANSIENT, ACC_VOLATILE, CONSTANT_Class, CONSTANT_Double, CONSTANT_FieldRef, CONSTANT_Float, CONSTANT_Integer, CONSTANT_InterfaceMethodRef, CONSTANT_InvokeDynamic, CONSTANT_Long, CONSTANT_MethodHandle, CONSTANT_MethodRef, CONSTANT_MethodType, CONSTANT_NameAndType, CONSTANT_String, CONSTANT_Utf8, MAGIC, REF_getField, REF_getStatic, REF_invokeInterface, REF_invokeSpecial, REF_invokeStatic, REF_invokeVirtual, REF_newInvokeSpecial, REF_putField, REF_putStatic
Modifier | Constructor and Description |
---|---|
protected |
AstFunctionClass(TypeReference reference,
IClassLoader loader,
CAstSourcePositionMap.Position sourcePosition) |
protected |
AstFunctionClass(TypeReference reference,
TypeReference superReference,
IClassLoader loader,
CAstSourcePositionMap.Position sourcePosition) |
Modifier and Type | Method and Description |
---|---|
Collection<IClass> |
getAllAncestorInterfaces() |
Collection<IField> |
getAllFields()
Compute the instance and static fields declared by this class or any of its superclasses.
|
Collection<IClass> |
getAllImplementedInterfaces() |
Collection<IField> |
getAllInstanceFields()
Compute the instance fields declared by this class or any of its superclasses.
|
Collection<IMethod> |
getAllMethods()
Compute the methods declared by this class or any of its superclasses.
|
Collection<IField> |
getAllStaticFields()
Compute the static fields declared by this class or any of its superclasses.
|
IMethod |
getClassInitializer() |
IClassLoader |
getClassLoader()
Return the object that represents the defining class loader for this class.
|
IMethod |
getCodeBody() |
Collection<IField> |
getDeclaredInstanceFields()
Compute the instance fields declared by this class.
|
Collection<IMethod> |
getDeclaredMethods() |
Collection<IField> |
getDeclaredStaticFields() |
Collection<IClass> |
getDirectInterfaces() |
IField |
getField(Atom name)
Finds a field.
|
IField |
getField(Atom name,
TypeName type)
Finds a field, given a name and a type.
|
IMethod |
getMethod(Selector selector)
Finds method matching signature.
|
int |
getModifiers()
Return the integer that encodes the class's modifiers, as defined by the JVM specification
|
TypeName |
getName() |
TypeReference |
getReference() |
Reader |
getSource() |
String |
getSourceFileName() |
CAstSourcePositionMap.Position |
getSourcePosition() |
URL |
getSourceURL() |
IClass |
getSuperclass() |
boolean |
isAbstract() |
boolean |
isArrayClass() |
boolean |
isInterface()
Is this class a Java interface?
|
boolean |
isPrivate() |
boolean |
isPublic() |
boolean |
isReferenceType()
Does 'this' refer to a reference type? If not, then it refers to a primitive type.
|
boolean |
isStatic() |
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getAnnotations
getClassHierarchy
protected IMethod functionBody
protected AstFunctionClass(TypeReference reference, TypeReference superReference, IClassLoader loader, CAstSourcePositionMap.Position sourcePosition)
protected AstFunctionClass(TypeReference reference, IClassLoader loader, CAstSourcePositionMap.Position sourcePosition)
public IClassLoader getClassLoader()
IClass
getClassLoader
in interface IClass
public boolean isInterface()
IClass
isInterface
in interface IClass
public boolean isAbstract()
isAbstract
in interface IClass
public boolean isPublic()
public boolean isPrivate()
public boolean isStatic()
public int getModifiers()
IClass
getModifiers
in interface IClass
public IClass getSuperclass()
getSuperclass
in interface IClass
public Collection<IClass> getDirectInterfaces()
getDirectInterfaces
in interface IClass
public Collection<IClass> getAllImplementedInterfaces()
getAllImplementedInterfaces
in interface IClass
public Collection<IClass> getAllAncestorInterfaces()
public IMethod getMethod(Selector selector)
IClass
public IField getField(Atom name, TypeName type)
IClass
null
if not found.public TypeReference getReference()
getReference
in interface IClass
public CAstSourcePositionMap.Position getSourcePosition()
public URL getSourceURL()
public String getSourceFileName()
getSourceFileName
in interface IClass
public Reader getSource()
public IMethod getClassInitializer()
getClassInitializer
in interface IClass
public boolean isArrayClass()
isArrayClass
in interface IClass
public Collection<IMethod> getDeclaredMethods()
getDeclaredMethods
in interface IClass
public Collection<IField> getDeclaredInstanceFields()
IClass
getDeclaredInstanceFields
in interface IClass
public Collection<IField> getDeclaredStaticFields()
getDeclaredStaticFields
in interface IClass
public Collection<IField> getAllInstanceFields()
IClass
getAllInstanceFields
in interface IClass
public Collection<IField> getAllStaticFields()
IClass
getAllStaticFields
in interface IClass
public Collection<IField> getAllFields()
IClass
getAllFields
in interface IClass
public Collection<IMethod> getAllMethods()
IClass
getAllMethods
in interface IClass
public TypeName getName()
public boolean isReferenceType()
IClass
isReferenceType
in interface IClass
public IMethod getCodeBody()