hudson.plugins.checkstyle.parser
Class CheckStyleParser

java.lang.Object
  extended by hudson.plugins.checkstyle.parser.CheckStyleParser
All Implemented Interfaces:
AnnotationParser, java.io.Serializable

public class CheckStyleParser
extends java.lang.Object
implements AnnotationParser

A parser for Checkstyle XML files.

Author:
Ulli Hafner
See Also:
Serialized Form

Constructor Summary
CheckStyleParser()
           
 
Method Summary
 java.lang.String getName()
          Returns the name of this parser.
 java.util.Collection<FileAnnotation> parse(java.io.File file, java.lang.String moduleName)
          Returns the annotations found in the specified file.
 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 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CheckStyleParser

public CheckStyleParser()
Method Detail

parse

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

Specified by:
parse in interface AnnotationParser
Parameters:
file - the file to parse
moduleName - name of the maven module
Returns:
the parsed result (stored in the module instance)
Throws:
java.lang.reflect.InvocationTargetException - if the file could not be parsed (wrap your exception in this exception)

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.

Parameters:
file - the file to parse
moduleName - name of the maven module
Returns:
the parsed result (stored in the module instance)
Throws:
java.lang.reflect.InvocationTargetException - if the file could not be parsed (wrap your exception in this exception)

getName

public java.lang.String getName()
Returns the name of this parser.

Specified by:
getName in interface AnnotationParser
Returns:
the name of this parser


Copyright © 2009. All Rights Reserved.