Package org.apache.tika.eval.app.io
Class DBWriter
- java.lang.Object
- 
- org.apache.tika.eval.app.io.DBWriter
 
- 
- All Implemented Interfaces:
- IDBWriter
 
 public class DBWriter extends Object implements IDBWriter This is still in its early stages. The idea is to get something working with h2 and then add to that as necessary.Beware, this deletes the db file with each initialization. Each thread must construct its own DBWriter because each DBWriter creates its own PreparedStatements at initialization. 
- 
- 
Constructor SummaryConstructors Constructor Description DBWriter(Connection connection, List<TableInfo> tableInfos, JDBCUtil dbUtil, MimeBuffer mimeBuffer)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()This closes the writer by executing batch and committing changes.intgetMimeId(String mimeString)voidwriteRow(TableInfo table, Map<Cols,String> data)
 
- 
- 
- 
Constructor Detail- 
DBWriterpublic DBWriter(Connection connection, List<TableInfo> tableInfos, JDBCUtil dbUtil, MimeBuffer mimeBuffer) throws IOException, SQLException - Throws:
- IOException
- SQLException
 
 
- 
 - 
Method Detail- 
writeRowpublic void writeRow(TableInfo table, Map<Cols,String> data) throws IOException - Specified by:
- writeRowin interface- IDBWriter
- Throws:
- IOException
 
 - 
closepublic void close() throws IOExceptionThis closes the writer by executing batch and committing changes. This DOES NOT close the connection- Specified by:
- closein interface- IDBWriter
- Throws:
- IOException
 
 
- 
 
-