public class ClassDescriptor extends java.lang.Object implements java.lang.Comparable<ClassDescriptor>, java.io.Serializable
Modifier and Type | Field and Description |
---|---|
static ClassDescriptor[] |
EMPTY_ARRAY |
Modifier | Constructor and Description |
---|---|
protected |
ClassDescriptor(java.lang.String className)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(ClassDescriptor o) |
static ClassDescriptor |
createClassDescriptor(org.apache.bcel.classfile.JavaClass c)
Deprecated.
|
static ClassDescriptor |
createClassDescriptor(java.lang.String className)
Deprecated.
Use
DescriptorFactory.createClassDescriptor(String)
instead |
static ClassDescriptor[] |
createClassDescriptor(java.lang.String[] classNames)
Deprecated.
|
static ClassDescriptor |
createClassDescriptorFromDottedClassName(java.lang.String dottedClassName)
Deprecated.
|
static ClassDescriptor |
createClassDescriptorFromSignature(java.lang.String signature)
Deprecated.
|
boolean |
equals(java.lang.Object obj) |
static ClassDescriptor |
fromFieldSignature(java.lang.String signature)
Deprecated.
|
static ClassDescriptor |
fromResourceName(java.lang.String resourceName)
Deprecated.
|
java.lang.String |
getClassName() |
java.lang.String |
getDottedClassName()
Get the name of the class in dotted format.
|
java.lang.String |
getPackageName()
Get the name of the package in dotted format.
|
java.lang.String |
getSignature() |
java.lang.String |
getSimpleName()
Get the simple name of the class
|
XClass |
getXClass() |
int |
hashCode() |
boolean |
isAnonymousClass() |
boolean |
isArray() |
static boolean |
isClassResource(java.lang.String resourceName)
Deprecated.
Use
DescriptorFactory.isClassResource(String) instead |
boolean |
matches(java.lang.Class<?> c) |
static void |
throwClassNotFoundException(ClassDescriptor classDescriptor)
Throw a ClassNotFoundException to indicate that class named by given
ClassDescriptor cannot be found.
|
java.lang.String |
toDottedClassName()
Get the name of the class in dotted format.
|
java.lang.String |
toResourceName()
Get the resource name of this class as it would appear in the classpath.
|
java.lang.String |
toString() |
public static final ClassDescriptor[] EMPTY_ARRAY
protected ClassDescriptor(@SlashedClassName java.lang.String className)
className
- class name in VM format, e.g. "java/lang/String"@SlashedClassName public final java.lang.String getClassName()
public int compareTo(ClassDescriptor o)
compareTo
in interface java.lang.Comparable<ClassDescriptor>
public boolean matches(java.lang.Class<?> c)
public java.lang.String toResourceName()
@DottedClassName public java.lang.String toDottedClassName()
@DottedClassName public java.lang.String getDottedClassName()
public XClass getXClass() throws CheckedAnalysisException
CheckedAnalysisException
@DottedClassName public java.lang.String getPackageName()
public java.lang.String getSimpleName()
public java.lang.String getSignature()
public boolean isArray()
@Deprecated public static ClassDescriptor fromResourceName(java.lang.String resourceName)
DescriptorFactory.createClassDescriptorFromResourceName(String)
insteadresourceName
- the resource name@Deprecated @CheckForNull public static ClassDescriptor fromFieldSignature(java.lang.String signature)
DescriptorFactory.createClassDescriptorFromFieldSignature(String)
instead@Deprecated public static boolean isClassResource(java.lang.String resourceName)
DescriptorFactory.isClassResource(String)
insteadresourceName
- the resource name@Deprecated public static ClassDescriptor createClassDescriptorFromSignature(java.lang.String signature)
DescriptorFactory.createClassDescriptorFromSignature(String)
instead@Deprecated public static ClassDescriptor createClassDescriptor(@SlashedClassName java.lang.String className)
DescriptorFactory.createClassDescriptor(String)
instead@Deprecated public static ClassDescriptor[] createClassDescriptor(java.lang.String[] classNames)
DescriptorFactory.createClassDescriptor(String[])
instead@Deprecated public static ClassDescriptor createClassDescriptorFromDottedClassName(java.lang.String dottedClassName)
DescriptorFactory.createClassDescriptorFromDottedClassName(String)
instead@Deprecated public static ClassDescriptor createClassDescriptor(org.apache.bcel.classfile.JavaClass c)
DescriptorFactory.createClassDescriptor(JavaClass)
insteadpublic java.lang.String toString()
toString
in class java.lang.Object
public final boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public static void throwClassNotFoundException(ClassDescriptor classDescriptor) throws java.lang.ClassNotFoundException
classDescriptor
- ClassDescriptor naming a class that cannot be foundjava.lang.ClassNotFoundException
ClassNotFoundExceptionParser
public boolean isAnonymousClass()
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.