|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthudson.plugins.warnings.parser.ParserRegistry
public class ParserRegistry
Registry for the active parsers in this plug-in.
| Constructor Summary | |
|---|---|
ParserRegistry(java.util.List<WarningsParser> parsers,
java.lang.String defaultEncoding)
Creates a new instance of ParserRegistry. |
|
ParserRegistry(java.util.List<WarningsParser> parsers,
java.lang.String defaultEncoding,
java.lang.String includePattern,
java.lang.String excludePattern)
Creates a new instance of ParserRegistry. |
|
| Method Summary | |
|---|---|
protected java.io.Reader |
createReader(java.io.File file)
Creates a reader from the specified file. |
protected java.io.Reader |
createReader(java.io.InputStream inputStream)
Creates a reader from the specified input stream. |
static java.util.List<java.lang.String> |
getAvailableParsers()
Returns all available parser names. |
protected java.lang.Iterable<WarningsParser> |
getParsers()
Returns all registers parsers. |
static java.util.List<WarningsParser> |
getParsers(java.util.Set<java.lang.String> parserNames)
Returns a list of parsers that match the specified names. |
java.util.Collection<FileAnnotation> |
parse(java.io.File file)
Iterates over the available parsers and parses the specified file with each parser. |
java.util.Collection<FileAnnotation> |
parse(java.io.InputStream file)
Iterates over the available parsers and parses the specified file with each parser. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ParserRegistry(java.util.List<WarningsParser> parsers,
java.lang.String defaultEncoding)
ParserRegistry.
parsers - the parsers to use when scanning a filedefaultEncoding - the default encoding to be used when reading and parsing files
public ParserRegistry(java.util.List<WarningsParser> parsers,
java.lang.String defaultEncoding,
java.lang.String includePattern,
java.lang.String excludePattern)
ParserRegistry.
parsers - the parsers to use when scanning a fileincludePattern - Ant file-set pattern of files to include in report,
null or an empty string do not filter the outputexcludePattern - Ant file-set pattern of files to exclude from report,
null or an empty string do not filter the outputdefaultEncoding - the default encoding to be used when reading and parsing files| Method Detail |
|---|
protected java.lang.Iterable<WarningsParser> getParsers()
public java.util.Collection<FileAnnotation> parse(java.io.File file)
throws java.io.IOException
file - the input stream
java.io.IOException - Signals that an I/O exception has occurred.
public java.util.Collection<FileAnnotation> parse(java.io.InputStream file)
throws java.io.IOException
file - the input stream
java.io.IOException - Signals that an I/O exception has occurred.
protected java.io.Reader createReader(java.io.File file)
throws java.io.FileNotFoundException
file - the file
java.io.FileNotFoundException - if the file does not existprotected java.io.Reader createReader(java.io.InputStream inputStream)
inputStream - the input stream
public static java.util.List<java.lang.String> getAvailableParsers()
public static java.util.List<WarningsParser> getParsers(java.util.Set<java.lang.String> parserNames)
parserNames - the parser names
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||