hudson.plugins.pmd.parser
Class PmdParser

java.lang.Object
  extended by hudson.plugins.pmd.util.AbstractAnnotationParser
      extended by hudson.plugins.pmd.parser.PmdParser
All Implemented Interfaces:
AnnotationParser, java.io.Serializable

public class PmdParser
extends AbstractAnnotationParser

A parser for PMD XML files.

Author:
Ulli Hafner
See Also:
Serialized Form

Constructor Summary
PmdParser()
          Creates a new instance of PmdParser.
PmdParser(java.lang.String defaultEncoding)
          Creates a new instance of PmdParser.
 
Method Summary
 java.util.Collection<FileAnnotation> parse(java.io.InputStream file, java.lang.String moduleName)
          Returns the annotations found in the specified file.
 
Methods inherited from class hudson.plugins.pmd.util.AbstractAnnotationParser
createContextHashCode, getDefaultEncoding, parse
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PmdParser

public PmdParser()
Creates a new instance of PmdParser.


PmdParser

public PmdParser(java.lang.String defaultEncoding)
Creates a new instance of PmdParser.

Parameters:
defaultEncoding - the default encoding to be used when reading and parsing files
Method Detail

parse

public java.util.Collection<FileAnnotation> parse(java.io.InputStream file,
                                                  java.lang.String moduleName)
                                           throws java.lang.reflect.InvocationTargetException
Returns the annotations found in the specified file.

Specified by:
parse in class AbstractAnnotationParser
Parameters:
file - the file to parse
moduleName - name of the maven module
Returns:
the found annotations
Throws:
java.lang.reflect.InvocationTargetException - if the file could not be parsed (wrap your exception in this exception)


Copyright © 2009. All Rights Reserved.