org.jcoderz.phoenix.report
Class ReportNormalizer

java.lang.Object
  extended by org.jcoderz.phoenix.report.ReportNormalizer

public final class ReportNormalizer
extends Object

Provides merging of findbugs, pmd, checkstyle, cpd, and cobertura XML files into a single XML representation.

Author:
Michael Griffel, Michael Rumpf

Nested Class Summary
static class ReportNormalizer.SourceReport
          The Class SourceReport.
 
Field Summary
static String JCODERZ_REPORT_XML
          The Constant JCODERZ_REPORT_XML.
 
Constructor Summary
ReportNormalizer()
          Constructor.
 
Method Summary
 void addReport(ReportFormat format, File file)
          Adds the report.
 void addReport(ReportFormat format, String file)
          Adds the report.
 void addReport(ReportFormat format, String file, String flavor)
          Adds the report with a given flavor.
 void addSource(File srcDir)
           
 File getFilterFile()
          Gets the filter file.
 ReportLevel getLevel()
          Gets the level.
 Level getLogLevel()
          Gets the log level.
 File getOutFile()
          Gets the out file.
 File getProjectHome()
          Gets the project home.
 String getProjectName()
          Gets the project name.
static void main(String[] args)
          Main method.
 void run()
          Run ReportNormalizer.
 void setFilterFile(File filterFile)
          Sets the filter file.
 void setLevel(ReportLevel level)
          Sets the level.
 void setLogLevel(Level logLevel)
          Sets the log level.
 void setOutFile(File outFile)
          Sets the out file.
 void setProjectHome(File projectHome)
          Sets the project home.
 void setProjectName(String projectName)
          Sets the project name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

JCODERZ_REPORT_XML

public static final String JCODERZ_REPORT_XML
The Constant JCODERZ_REPORT_XML.

See Also:
Constant Field Values
Constructor Detail

ReportNormalizer

public ReportNormalizer()
                 throws IOException
Constructor.

Throws:
IOException - in case of any error.
Method Detail

main

public static void main(String[] args)
                 throws Exception
Main method.

Parameters:
args - arguments.
Throws:
Exception - the exception

run

public void run()
         throws JAXBException,
                IOException,
                TransformerException
Run ReportNormalizer.

Throws:
JAXBException
IOException
TransformerException

addReport

public void addReport(ReportFormat format,
                      String file)
Adds the report.

Parameters:
format - the format
file - the file

addReport

public void addReport(ReportFormat format,
                      String file,
                      String flavor)
Adds the report with a given flavor. The flavor is used for generic reports to detect the type of file.

Parameters:
format - the format
file - the file
flavor - the flavor of the report.

addReport

public void addReport(ReportFormat format,
                      File file)
Adds the report.

Parameters:
format - the format
file - the file

addSource

public void addSource(File srcDir)

getProjectHome

public File getProjectHome()
Gets the project home.

Returns:
the project home

setProjectHome

public void setProjectHome(File projectHome)
Sets the project home.

Parameters:
projectHome - the new project home

getProjectName

public String getProjectName()
Gets the project name.

Returns:
the project name

setProjectName

public void setProjectName(String projectName)
Sets the project name.

Parameters:
projectName - the new project name

getOutFile

public File getOutFile()
Gets the out file.

Returns:
the out file

setOutFile

public void setOutFile(File outFile)
                throws IOException
Sets the out file.

Parameters:
outFile - the new out file
Throws:
IOException - Signals that an I/O exception has occurred.

getLogLevel

public Level getLogLevel()
Gets the log level.

Returns:
the log level

setLogLevel

public void setLogLevel(Level logLevel)
Sets the log level.

Parameters:
logLevel - the new log level

getLevel

public ReportLevel getLevel()
Gets the level.

Returns:
the level

setLevel

public void setLevel(ReportLevel level)
Sets the level.

Parameters:
level - the new level

getFilterFile

public File getFilterFile()
Gets the filter file.

Returns:
the filter file

setFilterFile

public void setFilterFile(File filterFile)
                   throws IOException
Sets the filter file.

Parameters:
filterFile - the new filter file
Throws:
IOException - Signals that an I/O exception has occurred.


Copyright 2007 The jCoderZ Project.