olg.csv.base
Interface IWriter

Package class diagram package IWriter
All Superinterfaces:
Closeable
All Known Implementing Classes:
AbstractSheetWriter, CSVWriter, IgnoreNullWriter, ODSWriter

public interface IWriter
extends Closeable

Writer Interface.


Method Summary
 void addLine(String[] values)
          Adds a row from the given String array.
 void addRow(Row row)
          Adds a row.
 boolean isWithHeaders()
          Indicates if the file has a headers line.
 
Methods inherited from interface java.io.Closeable
close
 

Method Detail

addRow

void addRow(Row row)
Adds a row.

The first row allows to define the size used along writing unless addLine(String[]) had been used first.

Throws a WriterException when row size differs from initial size or row num is lesser than the expected next number line. Or if I/O error occurs during writing.

Parameters:
row - the row. It's possible to use a row with no cells. In this case, an empty line(a line wich all fields are null) is added. It's possible to use a row with a num greater than the expected number. In this case, empty lines are wroten as much as necessary. It's possible to use row which all cells are not specified. In this case the missing cells are added as empty cells. Must be not null with cells correctly ordered and size>0.

addLine

void addLine(String[] values)
Adds a row from the given String array. The first time this method define the size ( as the given string array length) used along writing unless addRow(Row) had been used first.

Throws a WriterException when line size differs from initial size.

Parameters:
values - the row. Must be not null with length >0. .

isWithHeaders

boolean isWithHeaders()
Indicates if the file has a headers line.

Returns:
true if the file has a headers line.


Copyright © 2014. All Rights Reserved.