uk.ac.ebi.microarray.zooma.reports
Class TextReportWriter

java.lang.Object
  extended by java.io.Writer
      extended by uk.ac.ebi.microarray.zooma.reports.ReportWriter
          extended by uk.ac.ebi.microarray.zooma.reports.TextReportWriter
All Implemented Interfaces:
java.io.Closeable, java.io.Flushable, java.lang.Appendable

public class TextReportWriter
extends ReportWriter

A ReportWriter implementation that writes a simple tab delimited text report based around a simple format. TextReportingMappers use this writer to actually generate the report.

Author:
Tony Burdett
See Also:
TextReportingMapper

Field Summary
 
Fields inherited from class java.io.Writer
lock
 
Constructor Summary
TextReportWriter(java.io.File file)
          Creates a ReportWriter that buffers written lines, sorting them alphabetically.
 
Method Summary
 void write(OntologyMappingOutcome outcome)
           
protected  void writeReportHeader(java.io.PrintWriter writer)
          Writes the header of the report into the supplied print writer.
 
Methods inherited from class uk.ac.ebi.microarray.zooma.reports.ReportWriter
close, endReport, extractOntologyTermFromURI, fetchOntologyName, flush, getLog, lookupVersionFromMavenProperties, startReport, write, writeReportFooter
 
Methods inherited from class java.io.Writer
append, append, append, write, write, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TextReportWriter

public TextReportWriter(java.io.File file)
Creates a ReportWriter that buffers written lines, sorting them alphabetically. The file is only created on completion, once this writer is closed.

Parameters:
file - the file to write the report to
Method Detail

writeReportHeader

protected void writeReportHeader(java.io.PrintWriter writer)
Description copied from class: ReportWriter
Writes the header of the report into the supplied print writer. If you require columns headers at the top of your report, you should extend this method, calling super.writeReportHeader() first followed by writer.println(<my line here>);

Overrides:
writeReportHeader in class ReportWriter
Parameters:
writer - the writer to write the header data to

write

public void write(OntologyMappingOutcome outcome)
           throws java.io.IOException
Throws:
java.io.IOException


Copyright © 2010. All Rights Reserved.