de.erichseifert.gral.io.data
Class CSVWriter

java.lang.Object
  extended by de.erichseifert.gral.io.IOCapabilitiesStorage
      extended by de.erichseifert.gral.io.data.AbstractDataWriter
          extended by de.erichseifert.gral.io.data.CSVWriter
All Implemented Interfaces:
DataWriter

public class CSVWriter
extends AbstractDataWriter

Class that writes a DataSource to a CSV file. By default the semicolon character will be used for separating columns.

See Also:
RFC 4180

Constructor Summary
CSVWriter(String mimeType)
          Creates a new CSVWriter object with the specified MIME-Type.
 
Method Summary
 void write(DataSource data, OutputStream output)
          Stores the specified DataSource
 
Methods inherited from class de.erichseifert.gral.io.data.AbstractDataWriter
getMimeType, getSetting, setSetting
 
Methods inherited from class de.erichseifert.gral.io.IOCapabilitiesStorage
getCapabilities
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CSVWriter

public CSVWriter(String mimeType)
Creates a new CSVWriter object with the specified MIME-Type.

Parameters:
mimeType - MIME-Type of the output file.
Method Detail

write

public void write(DataSource data,
                  OutputStream output)
           throws IOException
Description copied from interface: DataWriter
Stores the specified DataSource

Parameters:
data - DataSource to be stored.
output - OutputStream to be written to.
Throws:
IOException - if writing the data failed


Copyright © 2009-2010. All Rights Reserved.