|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthudson.plugins.findbugs.util.SourceDetail
public class SourceDetail
Renders a source file containing an annotation for the whole file or a specific line number.
| Field Summary | |
|---|---|
protected static int |
SOURCE_GENERATOR_OFFSET
Offset of the source code generator. |
| Constructor Summary | |
|---|---|
SourceDetail(hudson.model.AbstractBuild<?,?> owner,
FileAnnotation annotation)
Creates a new instance of this source code object. |
|
| Method Summary | |
|---|---|
java.lang.String |
getDisplayName()
|
java.lang.String |
getFileName()
Gets the file name of this source file. |
hudson.model.AbstractBuild<?,?> |
getOwner()
Returns the build as owner of this object. |
java.lang.String |
getSourceCode()
Returns the line that should be highlighted. |
java.lang.String |
highlightSource(java.io.InputStream file)
Highlights the specified source and returns the result as an HTML string. |
void |
splitSourceFile(java.lang.String sourceFile)
Splits the source code into three blocks: the line to highlight and the source code before and after this line. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final int SOURCE_GENERATOR_OFFSET
| Constructor Detail |
|---|
public SourceDetail(hudson.model.AbstractBuild<?,?> owner,
FileAnnotation annotation)
owner - the current build as owner of this objectannotation - the warning to display in the source file| Method Detail |
|---|
public java.lang.String getDisplayName()
getDisplayName in interface hudson.model.ModelObject
public final java.lang.String highlightSource(java.io.InputStream file)
throws java.io.IOException
file - the source file to highlight
java.io.IOExceptionpublic final void splitSourceFile(java.lang.String sourceFile)
sourceFile - the source code of the whole file as rendered HTML stringpublic java.lang.String getFileName()
public hudson.model.AbstractBuild<?,?> getOwner()
public java.lang.String getSourceCode()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||