public abstract class ClassName
extends java.lang.Object
Constructor and Description |
---|
ClassName() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
assertIsDotted(java.lang.String className) |
static java.lang.String |
assertIsSlashed(java.lang.String className) |
static java.lang.String |
extractClassName(java.lang.String originalName)
Extract a slashed classname from a JVM classname or signature.
|
static java.lang.String |
extractPackageName(java.lang.String className)
extract the package name from a dotted class name.
|
static java.lang.String |
extractPackagePrefix(java.lang.String packageName,
int count) |
static java.lang.String |
extractSimpleName(java.lang.String className) |
static java.lang.String |
fromFieldSignature(java.lang.String signature)
Converts from signature to slashed class name
(e.g., from Ljava/lang/String; to java/lang/String).
|
static java.lang.String |
getPrimitiveType(java.lang.String cls) |
static boolean |
isAnonymous(java.lang.String className)
Does a class name appear to designate an anonymous class? Only the name
is analyzed.
|
static boolean |
isMathClass(java.lang.String className) |
static boolean |
isValidClassName(java.lang.String className)
Return whether or not the given class name is valid.
|
static boolean |
matchedPrefixes(java.lang.String[] classSearchStrings,
java.lang.String className) |
static java.lang.String |
toDottedClassName(java.lang.String className)
Convert class name to dotted format.
|
static java.lang.String |
toSignature(java.lang.String className) |
static java.lang.String |
toSlashedClassName(java.lang.Class<?> class1) |
static java.lang.String |
toSlashedClassName(java.lang.String className)
Convert class name to slashed format.
|
public static boolean isMathClass(@SlashedClassName java.lang.String className)
@DottedClassName public static java.lang.String assertIsDotted(@DottedClassName java.lang.String className)
@SlashedClassName public static java.lang.String assertIsSlashed(@SlashedClassName java.lang.String className)
public static java.lang.String toSignature(@SlashedClassName java.lang.String className)
@CheckForNull public static java.lang.String getPrimitiveType(@SlashedClassName java.lang.String cls)
@CheckForNull @SlashedClassName public static java.lang.String fromFieldSignature(java.lang.String signature)
@SlashedClassName public static java.lang.String toSlashedClassName(@SlashedClassName(when=UNKNOWN) java.lang.String className)
className
- a class name@DottedClassName public static java.lang.String toDottedClassName(@SlashedClassName(when=UNKNOWN) java.lang.String className)
className
- a class name@DottedClassName public static java.lang.String extractPackageName(@DottedClassName java.lang.String className)
className
- a dotted class namepublic static java.lang.String extractSimpleName(@DottedClassName java.lang.String className)
public static boolean isValidClassName(java.lang.String className)
className
- a possible class namepublic static boolean isAnonymous(java.lang.String className)
className
- class name, slashed or dotted, fully qualified or unqualified@SlashedClassName public static java.lang.String extractClassName(java.lang.String originalName)
originalName
- JVM classname or signaturepublic static java.lang.String extractPackagePrefix(java.lang.String packageName, int count)
public static boolean matchedPrefixes(java.lang.String[] classSearchStrings, @DottedClassName java.lang.String className)
@SlashedClassName public static java.lang.String toSlashedClassName(java.lang.Class<?> class1)
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.