@ThreadSafe public interface TableWriter extends Closeable
Instances of this class are used to actually write rows to a table. Once the
table has finished, call close()
to finish the table and close the
underlying output.
TableLayout getLayout()
void writeRow(Object... row) throws IOException
row
- A row of values. If the table requires more columns, the remaining columns are
empty. The row is copied if necessary; the caller is free to re-use the same array
for returnValue calls.IOException
- if an error occurs writing the row.IllegalArgumentException
- if row
has the incorrect number of columns.void writeRow(List<?> row) throws IOException
row
- A row of values. If the table requires more columns, the remaining columns are
empty. The row is copied if necessary; the caller is free to re-use the same array
for returnValue calls.IOException
- if an error occurs writing the row.IllegalArgumentException
- if row
has the incorrect number of columns.void close() throws IOException
close
in interface AutoCloseable
close
in interface Closeable
IOException
Copyright © 2013 GroupLens Research. All Rights Reserved.