Package edu.umd.cs.findbugs
Class BugAnnotationWithSourceLines
- java.lang.Object
-
- edu.umd.cs.findbugs.BugAnnotationWithSourceLines
-
- All Implemented Interfaces:
BugAnnotation,XMLWriteable,XMLWriteableWithMessages,java.io.Serializable,java.lang.Cloneable,java.lang.Comparable<BugAnnotation>
- Direct Known Subclasses:
PackageMemberAnnotation,TypeAnnotation
public abstract class BugAnnotationWithSourceLines extends java.lang.Object implements BugAnnotation
- Author:
- pugh
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.StringsourceFileNameprotected SourceLineAnnotationsourceLines-
Fields inherited from interface edu.umd.cs.findbugs.BugAnnotation
MESSAGE_TAG
-
-
Constructor Summary
Constructors Constructor Description BugAnnotationWithSourceLines()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectclone()java.lang.StringgetSourceFileName()Get the source file name.SourceLineAnnotationgetSourceLines()Get the SourceLineAnnotation describing the source lines where the method is defined.voidsetSourceLines(SourceLineAnnotation sourceLines)Set a SourceLineAnnotation describing the source lines where the package element is defined.java.lang.StringtoString(ClassAnnotation primaryClass)-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface edu.umd.cs.findbugs.BugAnnotation
accept, format, getDescription, isSignificant, setDescription
-
Methods inherited from interface edu.umd.cs.findbugs.xml.XMLWriteable
writeXML
-
Methods inherited from interface edu.umd.cs.findbugs.XMLWriteableWithMessages
writeXML
-
-
-
-
Field Detail
-
sourceFileName
protected java.lang.String sourceFileName
-
sourceLines
protected SourceLineAnnotation sourceLines
-
-
Method Detail
-
clone
public java.lang.Object clone()
- Specified by:
clonein interfaceBugAnnotation- Overrides:
clonein classjava.lang.Object
-
getSourceFileName
public final java.lang.String getSourceFileName()
Get the source file name.
-
setSourceLines
public void setSourceLines(SourceLineAnnotation sourceLines)
Set a SourceLineAnnotation describing the source lines where the package element is defined.
-
getSourceLines
public SourceLineAnnotation getSourceLines()
Get the SourceLineAnnotation describing the source lines where the method is defined.- Returns:
- the SourceLineAnnotation, or null if there is no source information for this package element
-
toString
public java.lang.String toString(ClassAnnotation primaryClass)
- Specified by:
toStringin interfaceBugAnnotation
-
-