java.lang.Object
edu.hm.hafner.analysis.IssueParser
edu.hm.hafner.analysis.parser.JsonParser
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
DScannerParser
Parser that reads the 1:1 JSON mapping of the properties of the
Issue bean.- Author:
- Jeremie Bresson
- See Also:
-
Field Summary
Fields inherited from class edu.hm.hafner.analysis.IssueParser
ADDITIONAL_PROPERTIES, CATEGORY, COLUMN_END, COLUMN_START, DESCRIPTION, FILE_NAME, FINGERPRINT, ID, LINE_END, LINE_RANGE_END, LINE_RANGE_START, LINE_RANGES, LINE_START, MESSAGE, MODULE_NAME, ORIGIN, PACKAGE_NAME, SEVERITY, TYPE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanaccepts(ReaderFactory readerFactory) Returns whether this parser accepts the specified file as valid input.parse(ReaderFactory readerFactory) Parses the specified file for issues.Methods inherited from class edu.hm.hafner.analysis.IssueParser
equalsIgnoreCase, isXmlFile, parseFile
-
Constructor Details
-
JsonParser
public JsonParser()
-
-
Method Details
-
accepts
Description copied from class:IssueParserReturns whether this parser accepts the specified file as valid input. Parsers may reject a file if it is in the wrong format to avoid exceptions during parsing.- Overrides:
acceptsin classIssueParser- Parameters:
readerFactory- provides a reader to the reports- Returns:
trueif this parser accepts this file as valid input, orfalseif the file could not be parsed by this parser
-
parse
Description copied from class:IssueParserParses the specified file for issues.- Specified by:
parsein classIssueParser- Parameters:
readerFactory- provides a reader to the reports- Returns:
- the issues
- Throws:
ParsingException- Signals that during parsing a non-recoverable error has been occurred
-