|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthudson.plugins.dry.parser.AbstractDryParser
public abstract class AbstractDryParser
A base class for duplicate code parsers. Use this class as a starting point
for your duplication result parser and register an instance in the
DuplicationParserRegistry.
| Constructor Summary | |
|---|---|
AbstractDryParser()
|
|
| Method Summary | |
|---|---|
protected abstract boolean |
accepts(java.io.InputStream inputStream)
Returns whether this parser accepts the specified stream as a valid file. |
java.util.Collection<FileAnnotation> |
parse(java.io.File file,
java.lang.String moduleName)
Returns the annotations found in the specified file. |
protected abstract java.util.Collection<FileAnnotation> |
parse(java.io.InputStream inputStream,
java.lang.String moduleName)
Returns the duplication 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 |
|---|
public AbstractDryParser()
| Method Detail |
|---|
public java.util.Collection<FileAnnotation> parse(java.io.File file,
java.lang.String moduleName)
throws java.lang.reflect.InvocationTargetException
parse in interface AnnotationParserfile - the file to parsemoduleName - name of the maven module
java.lang.reflect.InvocationTargetException - if the file could not be parsed (wrap your exception in this exception)
protected abstract java.util.Collection<FileAnnotation> parse(java.io.InputStream inputStream,
java.lang.String moduleName)
throws java.lang.reflect.InvocationTargetException
inputStream - the file to parsemoduleName - name of the maven module
java.lang.reflect.InvocationTargetException - if the file could not be parsed (wrap your actual exception in this exception)protected abstract boolean accepts(java.io.InputStream inputStream)
inputStream - the file to parse
true if this parser accepts the specified stream as
a valid file, false if the parser can't read this file
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||