public abstract class PackageMemberAnnotation extends BugAnnotationWithSourceLines
BugAnnotation
,
Serialized FormModifier and Type | Field and Description |
---|---|
protected java.lang.String |
className |
protected java.lang.String |
description |
sourceFileName, sourceLines
MESSAGE_TAG
Modifier | Constructor and Description |
---|---|
protected |
PackageMemberAnnotation(java.lang.String className,
java.lang.String description)
Constructor.
|
protected |
PackageMemberAnnotation(java.lang.String className,
java.lang.String description,
java.lang.String sourceFileName)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
format(java.lang.String key,
ClassAnnotation primaryClass)
Format the annotation.
|
protected abstract java.lang.String |
formatPackageMember(java.lang.String key,
ClassAnnotation primaryClass)
Do default and subclass-specific formatting.
|
ClassDescriptor |
getClassDescriptor()
Get the class descriptor.
|
java.lang.String |
getClassName()
Get the dotted class name.
|
java.lang.String |
getDescription()
Get a description of this bug annotation.
|
java.lang.String |
getPackageName()
Get the package name.
|
java.lang.String |
getSimpleClassName() |
java.lang.String |
getSlashedClassName()
Get the dotted class name.
|
boolean |
isSignificant()
Is this annotation used to compute instance hashes or match bug instances
across versions
|
protected static java.lang.String |
removePackage(java.lang.String typeName) |
protected static java.lang.String |
removePackageName(java.lang.String typeName)
Shorten a type name by removing the package name
|
void |
setDescription(java.lang.String description)
Set a description of this bug annotation.
|
protected static java.lang.String |
shorten(java.lang.String pkgName,
java.lang.String typeName)
Shorten a type name of remove extraneous components.
|
java.lang.String |
toString()
All PackageMemberAnnotation object share a common toString()
implementation.
|
java.lang.String |
toString(ClassAnnotation primaryClass) |
clone, getSourceFileName, getSourceLines, setSourceLines
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
accept
writeXML
writeXML
@DottedClassName protected final java.lang.String className
protected java.lang.String description
protected PackageMemberAnnotation(@DottedClassName java.lang.String className, java.lang.String description)
className
- name of the classprotected PackageMemberAnnotation(@DottedClassName java.lang.String className, java.lang.String description, java.lang.String sourceFileName)
className
- name of the class@DottedClassName public final java.lang.String getClassName()
@SlashedClassName public final java.lang.String getSlashedClassName()
public java.lang.String getSimpleClassName()
public final ClassDescriptor getClassDescriptor()
@DottedClassName public final java.lang.String getPackageName()
public final java.lang.String format(java.lang.String key, ClassAnnotation primaryClass)
key
- the keyprimaryClass
- The primary class for the bug; some bug annotation format msgs
are simplified in relation to that class.public void setDescription(java.lang.String description)
BugAnnotation
public java.lang.String getDescription()
BugAnnotation
protected static java.lang.String shorten(java.lang.String pkgName, java.lang.String typeName)
java.lang
package.protected static java.lang.String removePackage(java.lang.String typeName)
protected static java.lang.String removePackageName(java.lang.String typeName)
protected abstract java.lang.String formatPackageMember(java.lang.String key, ClassAnnotation primaryClass)
key
- the key specifying how to do the formattingprimaryClass
- TODOpublic java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String toString(ClassAnnotation primaryClass)
toString
in interface BugAnnotation
toString
in class BugAnnotationWithSourceLines
public boolean isSignificant()
BugAnnotation
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.