public class LinkReportWriter extends XMLGraphWriter implements IReportWriter
DependencyGraph
as a XML link report.
This graph will walk through the graph from the ICompilationUnit
stored in roots
and construct a XML link report.
This has mostly been kept consistent with the link report from the old flex compiler, however a few differences remain. We may link different things from the framework, or the old compiler might have failed to find certain dependencies.
Without a concrete spec, this class is still a work in progress
Modifier and Type | Class and Description |
---|---|
static class |
LinkReportWriter.QNameComparator
A
Comparator that sorts qnames String based on alphabetical order. |
doc, graph, roots
Constructor and Description |
---|
LinkReportWriter(DependencyGraph graph,
List<ICompilationUnit> roots,
LinkageChecker linkageChecker) |
Modifier and Type | Method and Description |
---|---|
void |
writeToStream(OutputStream outStream,
Collection<ICompilerProblem> problems)
Writes the current graph state and root compilation nodes to the output stream specified
as a link report.
|
formatXMLStyleQName, writeReport
public LinkReportWriter(DependencyGraph graph, List<ICompilationUnit> roots, LinkageChecker linkageChecker)
public void writeToStream(OutputStream outStream, Collection<ICompilerProblem> problems) throws InterruptedException
IReportWriter
This should only be called when all compilation units are finished. There are no guarantees on the effects if called when compiler threads are still running.
writeToStream
in interface IReportWriter
writeToStream
in class XMLGraphWriter
outStream
- An OutputStream
that the report will be written toproblems
- A Collection
of ICompilerProblem
that this class will add to in case of exceptions or problemsInterruptedException
- can occur if this method is called while compilation is happeningCopyright © 2016 The Apache Software Foundation. All rights reserved.