com.ibm.wala.cast.java.translator.jdt
Class FakeExceptionTypeBinding
java.lang.Object
com.ibm.wala.cast.java.translator.jdt.FakeExceptionTypeBinding
- All Implemented Interfaces:
- org.eclipse.jdt.core.dom.IBinding, org.eclipse.jdt.core.dom.ITypeBinding
public class FakeExceptionTypeBinding
- extends java.lang.Object
- implements org.eclipse.jdt.core.dom.ITypeBinding
This is a hack to get around the fact that AST.resolveWellKnownTypes() doesn't know about some implicitly declared exceptions,
such as ArithmeticException (implicitly thrown in a division operation) and NullPointerException (implicitly thrown in a field
access). We need to know the lineage of these types to determine possible catch targets.
| Fields inherited from interface org.eclipse.jdt.core.dom.IBinding |
ANNOTATION, MEMBER_VALUE_PAIR, METHOD, PACKAGE, TYPE, VARIABLE |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.eclipse.jdt.core.dom.IBinding |
toString |
arithmetic
public static final FakeExceptionTypeBinding arithmetic
nullPointer
public static final FakeExceptionTypeBinding nullPointer
classCast
public static final FakeExceptionTypeBinding classCast
noClassDef
public static final FakeExceptionTypeBinding noClassDef
initException
public static final FakeExceptionTypeBinding initException
outOfMemory
public static final FakeExceptionTypeBinding outOfMemory
isAssignmentCompatible
public boolean isAssignmentCompatible(org.eclipse.jdt.core.dom.ITypeBinding variableType)
- Specified by:
isAssignmentCompatible in interface org.eclipse.jdt.core.dom.ITypeBinding
equals
public boolean equals(java.lang.Object o)
- Specified by:
equals in interface org.eclipse.jdt.core.dom.IBinding- Overrides:
equals in class java.lang.Object
createArrayType
public org.eclipse.jdt.core.dom.ITypeBinding createArrayType(int dimension)
- Specified by:
createArrayType in interface org.eclipse.jdt.core.dom.ITypeBinding
getBinaryName
public java.lang.String getBinaryName()
- Specified by:
getBinaryName in interface org.eclipse.jdt.core.dom.ITypeBinding
getBound
public org.eclipse.jdt.core.dom.ITypeBinding getBound()
- Specified by:
getBound in interface org.eclipse.jdt.core.dom.ITypeBinding
getComponentType
public org.eclipse.jdt.core.dom.ITypeBinding getComponentType()
- Specified by:
getComponentType in interface org.eclipse.jdt.core.dom.ITypeBinding
getDeclaredFields
public org.eclipse.jdt.core.dom.IVariableBinding[] getDeclaredFields()
- Specified by:
getDeclaredFields in interface org.eclipse.jdt.core.dom.ITypeBinding
getDeclaredMethods
public org.eclipse.jdt.core.dom.IMethodBinding[] getDeclaredMethods()
- Specified by:
getDeclaredMethods in interface org.eclipse.jdt.core.dom.ITypeBinding
getDeclaredModifiers
public int getDeclaredModifiers()
- Specified by:
getDeclaredModifiers in interface org.eclipse.jdt.core.dom.ITypeBinding
getDeclaredTypes
public org.eclipse.jdt.core.dom.ITypeBinding[] getDeclaredTypes()
- Specified by:
getDeclaredTypes in interface org.eclipse.jdt.core.dom.ITypeBinding
getDeclaringClass
public org.eclipse.jdt.core.dom.ITypeBinding getDeclaringClass()
- Specified by:
getDeclaringClass in interface org.eclipse.jdt.core.dom.ITypeBinding
getDeclaringMethod
public org.eclipse.jdt.core.dom.IMethodBinding getDeclaringMethod()
- Specified by:
getDeclaringMethod in interface org.eclipse.jdt.core.dom.ITypeBinding
getDimensions
public int getDimensions()
- Specified by:
getDimensions in interface org.eclipse.jdt.core.dom.ITypeBinding
getElementType
public org.eclipse.jdt.core.dom.ITypeBinding getElementType()
- Specified by:
getElementType in interface org.eclipse.jdt.core.dom.ITypeBinding
getErasure
public org.eclipse.jdt.core.dom.ITypeBinding getErasure()
- Specified by:
getErasure in interface org.eclipse.jdt.core.dom.ITypeBinding
getInterfaces
public org.eclipse.jdt.core.dom.ITypeBinding[] getInterfaces()
- Specified by:
getInterfaces in interface org.eclipse.jdt.core.dom.ITypeBinding
getModifiers
public int getModifiers()
- Specified by:
getModifiers in interface org.eclipse.jdt.core.dom.IBinding- Specified by:
getModifiers in interface org.eclipse.jdt.core.dom.ITypeBinding
getName
public java.lang.String getName()
- Specified by:
getName in interface org.eclipse.jdt.core.dom.IBinding- Specified by:
getName in interface org.eclipse.jdt.core.dom.ITypeBinding
getPackage
public org.eclipse.jdt.core.dom.IPackageBinding getPackage()
- Specified by:
getPackage in interface org.eclipse.jdt.core.dom.ITypeBinding
getQualifiedName
public java.lang.String getQualifiedName()
- Specified by:
getQualifiedName in interface org.eclipse.jdt.core.dom.ITypeBinding
getSuperclass
public org.eclipse.jdt.core.dom.ITypeBinding getSuperclass()
- Specified by:
getSuperclass in interface org.eclipse.jdt.core.dom.ITypeBinding
getTypeArguments
public org.eclipse.jdt.core.dom.ITypeBinding[] getTypeArguments()
- Specified by:
getTypeArguments in interface org.eclipse.jdt.core.dom.ITypeBinding
getTypeBounds
public org.eclipse.jdt.core.dom.ITypeBinding[] getTypeBounds()
- Specified by:
getTypeBounds in interface org.eclipse.jdt.core.dom.ITypeBinding
getTypeDeclaration
public org.eclipse.jdt.core.dom.ITypeBinding getTypeDeclaration()
- Specified by:
getTypeDeclaration in interface org.eclipse.jdt.core.dom.ITypeBinding
getTypeParameters
public org.eclipse.jdt.core.dom.ITypeBinding[] getTypeParameters()
- Specified by:
getTypeParameters in interface org.eclipse.jdt.core.dom.ITypeBinding
getWildcard
public org.eclipse.jdt.core.dom.ITypeBinding getWildcard()
- Specified by:
getWildcard in interface org.eclipse.jdt.core.dom.ITypeBinding
isAnnotation
public boolean isAnnotation()
- Specified by:
isAnnotation in interface org.eclipse.jdt.core.dom.ITypeBinding
isAnonymous
public boolean isAnonymous()
- Specified by:
isAnonymous in interface org.eclipse.jdt.core.dom.ITypeBinding
isArray
public boolean isArray()
- Specified by:
isArray in interface org.eclipse.jdt.core.dom.ITypeBinding
isCapture
public boolean isCapture()
- Specified by:
isCapture in interface org.eclipse.jdt.core.dom.ITypeBinding
isCastCompatible
public boolean isCastCompatible(org.eclipse.jdt.core.dom.ITypeBinding type)
- Specified by:
isCastCompatible in interface org.eclipse.jdt.core.dom.ITypeBinding
isClass
public boolean isClass()
- Specified by:
isClass in interface org.eclipse.jdt.core.dom.ITypeBinding
isEnum
public boolean isEnum()
- Specified by:
isEnum in interface org.eclipse.jdt.core.dom.ITypeBinding
isFromSource
public boolean isFromSource()
- Specified by:
isFromSource in interface org.eclipse.jdt.core.dom.ITypeBinding
isGenericType
public boolean isGenericType()
- Specified by:
isGenericType in interface org.eclipse.jdt.core.dom.ITypeBinding
isInterface
public boolean isInterface()
- Specified by:
isInterface in interface org.eclipse.jdt.core.dom.ITypeBinding
isLocal
public boolean isLocal()
- Specified by:
isLocal in interface org.eclipse.jdt.core.dom.ITypeBinding
isMember
public boolean isMember()
- Specified by:
isMember in interface org.eclipse.jdt.core.dom.ITypeBinding
isNested
public boolean isNested()
- Specified by:
isNested in interface org.eclipse.jdt.core.dom.ITypeBinding
isNullType
public boolean isNullType()
- Specified by:
isNullType in interface org.eclipse.jdt.core.dom.ITypeBinding
isParameterizedType
public boolean isParameterizedType()
- Specified by:
isParameterizedType in interface org.eclipse.jdt.core.dom.ITypeBinding
isPrimitive
public boolean isPrimitive()
- Specified by:
isPrimitive in interface org.eclipse.jdt.core.dom.ITypeBinding
isRawType
public boolean isRawType()
- Specified by:
isRawType in interface org.eclipse.jdt.core.dom.ITypeBinding
isSubTypeCompatible
public boolean isSubTypeCompatible(org.eclipse.jdt.core.dom.ITypeBinding type)
- Specified by:
isSubTypeCompatible in interface org.eclipse.jdt.core.dom.ITypeBinding
isTopLevel
public boolean isTopLevel()
- Specified by:
isTopLevel in interface org.eclipse.jdt.core.dom.ITypeBinding
isTypeVariable
public boolean isTypeVariable()
- Specified by:
isTypeVariable in interface org.eclipse.jdt.core.dom.ITypeBinding
isUpperbound
public boolean isUpperbound()
- Specified by:
isUpperbound in interface org.eclipse.jdt.core.dom.ITypeBinding
isWildcardType
public boolean isWildcardType()
- Specified by:
isWildcardType in interface org.eclipse.jdt.core.dom.ITypeBinding
getAnnotations
public org.eclipse.jdt.core.dom.IAnnotationBinding[] getAnnotations()
- Specified by:
getAnnotations in interface org.eclipse.jdt.core.dom.IBinding
getJavaElement
public org.eclipse.jdt.core.IJavaElement getJavaElement()
- Specified by:
getJavaElement in interface org.eclipse.jdt.core.dom.IBinding
getKey
public java.lang.String getKey()
- Specified by:
getKey in interface org.eclipse.jdt.core.dom.IBinding
getKind
public int getKind()
- Specified by:
getKind in interface org.eclipse.jdt.core.dom.IBinding
isDeprecated
public boolean isDeprecated()
- Specified by:
isDeprecated in interface org.eclipse.jdt.core.dom.IBinding
isEqualTo
public boolean isEqualTo(org.eclipse.jdt.core.dom.IBinding binding)
- Specified by:
isEqualTo in interface org.eclipse.jdt.core.dom.IBinding
isRecovered
public boolean isRecovered()
- Specified by:
isRecovered in interface org.eclipse.jdt.core.dom.IBinding
isSynthetic
public boolean isSynthetic()
- Specified by:
isSynthetic in interface org.eclipse.jdt.core.dom.IBinding
getGenericTypeOfWildcardType
public org.eclipse.jdt.core.dom.ITypeBinding getGenericTypeOfWildcardType()
- Specified by:
getGenericTypeOfWildcardType in interface org.eclipse.jdt.core.dom.ITypeBinding
getRank
public int getRank()
- Specified by:
getRank in interface org.eclipse.jdt.core.dom.ITypeBinding