Class ReportXmlFormatter
java.lang.Object
ro.isdc.wro.extensions.support.lint.AbstractReportXmlFormatter<LintItem>
ro.isdc.wro.extensions.support.lint.ReportXmlFormatter
Builds an XML report for lint errors based on provided collection of
LinterError's.- Since:
- 1.5.0
- Author:
- Alex Objelean
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedReportXmlFormatter(LintReport<LintItem> lintReport, ReportXmlFormatter.FormatterType type) -
Method Summary
Modifier and TypeMethodDescriptionprotected voidPopulates document with required DOM elements.static ReportXmlFormattercreate(LintReport<LintItem> lintReport, ReportXmlFormatter.FormatterType formatterType) Factory method for creatingReportXmlFormatter.static ReportXmlFormattercreateForCssLintError(LintReport<CssLintError> lintReport, ReportXmlFormatter.FormatterType formatterType) static ReportXmlFormattercreateForLinterError(LintReport<LinterError> lintReport, ReportXmlFormatter.FormatterType formatterType) protected Stringprotected Stringprotected StringMethods inherited from class ro.isdc.wro.extensions.support.lint.AbstractReportXmlFormatter
getDocument, getLintReport, write
-
Constructor Details
-
ReportXmlFormatter
protected ReportXmlFormatter(LintReport<LintItem> lintReport, ReportXmlFormatter.FormatterType type) - Parameters:
lintReport- a not null collection ofLinterErrorused to build an XML report from.
-
-
Method Details
-
create
public static ReportXmlFormatter create(LintReport<LintItem> lintReport, ReportXmlFormatter.FormatterType formatterType) Factory method for creatingReportXmlFormatter.- Parameters:
lintReport-LintReportto build xml reports from.
-
createForLinterError
public static ReportXmlFormatter createForLinterError(LintReport<LinterError> lintReport, ReportXmlFormatter.FormatterType formatterType) -
createForCssLintError
public static ReportXmlFormatter createForCssLintError(LintReport<CssLintError> lintReport, ReportXmlFormatter.FormatterType formatterType) -
buildDocument
protected void buildDocument()Populates document with required DOM elements.- Specified by:
buildDocumentin classAbstractReportXmlFormatter<LintItem>
-
getColumnAttributeName
- Returns:
- the name of the attribute indicating the character number where the issue is located.
-
getReasonAttributeName
- Returns:
- the name of the attribute indicating a reason of the issue.
-
getIssueElementName
- Returns:
- name of tag indicating an issue.
-