Package com.ibm.wala.classLoader
Class SyntheticClass
- java.lang.Object
-
- com.ibm.wala.classLoader.SyntheticClass
-
- All Implemented Interfaces:
IClass
,IClassHierarchyDweller
- Direct Known Subclasses:
AndroidModelClass
,BypassSyntheticClass
,FakeRootClass
,LambdaSummaryClass
public abstract class SyntheticClass extends Object implements IClass
AnIClass
that exists nowhere in bytecode.
-
-
Constructor Summary
Constructors Constructor Description SyntheticClass(TypeReference T, IClassHierarchy cha)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
Collection<Annotation>
getAnnotations()
get annotations, if anyIClassHierarchy
getClassHierarchy()
IClassLoader
getClassLoader()
By default, a synthetic class is "loaded" by the primordial loader.IField
getField(Atom name, TypeName typeName)
we assume synthetic classes do not need to have multiple fields with the same name.TypeName
getName()
TypeReference
getReference()
Reader
getSource()
String
getSourceFileName()
int
hashCode()
boolean
isAbstract()
boolean
isArrayClass()
boolean
isInterface()
Is this class a Java interface?-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.ibm.wala.classLoader.IClass
getAllFields, getAllImplementedInterfaces, getAllInstanceFields, getAllMethods, getAllStaticFields, getClassInitializer, getDeclaredInstanceFields, getDeclaredMethods, getDeclaredStaticFields, getDirectInterfaces, getField, getMethod, getModifiers, getSuperclass, isPrivate, isPublic, isReferenceType
-
-
-
-
Constructor Detail
-
SyntheticClass
public SyntheticClass(TypeReference T, IClassHierarchy cha)
- Parameters:
T
- type reference describing this class
-
-
Method Detail
-
getClassLoader
public IClassLoader getClassLoader()
By default, a synthetic class is "loaded" by the primordial loader. Subclasses may override as necessary.- Specified by:
getClassLoader
in interfaceIClass
- Returns:
- the object that represents the defining class loader for this class.
- See Also:
IClass.getClassLoader()
-
isInterface
public boolean isInterface()
Description copied from interface:IClass
Is this class a Java interface?- Specified by:
isInterface
in interfaceIClass
-
isAbstract
public boolean isAbstract()
- Specified by:
isAbstract
in interfaceIClass
- Returns:
- true iff this class is abstract
-
getReference
public TypeReference getReference()
- Specified by:
getReference
in interfaceIClass
- Returns:
- canonical TypeReference corresponding to this class
-
getSourceFileName
public String getSourceFileName()
- Specified by:
getSourceFileName
in interfaceIClass
- Returns:
- String holding the name of the source file that defined this class, or null if none found
-
getSource
public Reader getSource()
-
isArrayClass
public boolean isArrayClass()
- Specified by:
isArrayClass
in interfaceIClass
- Returns:
- true iff the class is an array class.
-
getClassHierarchy
public IClassHierarchy getClassHierarchy()
- Specified by:
getClassHierarchy
in interfaceIClassHierarchyDweller
-
getName
public TypeName getName()
-
getField
public IField getField(Atom name, TypeName typeName)
we assume synthetic classes do not need to have multiple fields with the same name.
-
getAnnotations
public Collection<Annotation> getAnnotations()
Description copied from interface:IClass
get annotations, if any- Specified by:
getAnnotations
in interfaceIClass
-
-