Package org.revapi.reporter.text
Class TextReporter
- java.lang.Object
-
- org.revapi.reporter.file.AbstractFileReporter
-
- org.revapi.reporter.text.TextReporter
-
- All Implemented Interfaces:
AutoCloseable
,org.revapi.configuration.Configurable
,org.revapi.Reporter
public class TextReporter extends org.revapi.reporter.file.AbstractFileReporter
- Since:
- 0.1
- Author:
- Lukas Krejci
-
-
Constructor Summary
Constructors Constructor Description TextReporter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected freemarker.template.Configuration
createFreeMarkerConfiguration()
Creates a new FreeMarker configuration.protected void
doReport(org.revapi.Report report)
protected void
flushReports()
String
getExtensionId()
Reader
getJSONSchema()
void
initialize(org.revapi.AnalysisContext analysis)
protected void
setOutput(PrintWriter wrt)
-
-
-
Method Detail
-
setOutput
protected void setOutput(PrintWriter wrt)
- Overrides:
setOutput
in classorg.revapi.reporter.file.AbstractFileReporter
-
initialize
public void initialize(@Nonnull org.revapi.AnalysisContext analysis)
- Specified by:
initialize
in interfaceorg.revapi.configuration.Configurable
- Overrides:
initialize
in classorg.revapi.reporter.file.AbstractFileReporter
-
createFreeMarkerConfiguration
protected freemarker.template.Configuration createFreeMarkerConfiguration()
Creates a new FreeMarker configuration. By default, it is configured as follows:- compatibility level is set to 2.3.23
- the object wrapper is configured to expose fields
- API builtins are enabled
- there are 2 template loaders - 1 for loading templates from /META-INF using a classloader and a second one to load templates from files.
- Returns:
-
doReport
protected void doReport(@Nonnull org.revapi.Report report)
- Specified by:
doReport
in classorg.revapi.reporter.file.AbstractFileReporter
-
flushReports
protected void flushReports() throws IOException
- Specified by:
flushReports
in classorg.revapi.reporter.file.AbstractFileReporter
- Throws:
IOException
-
-