Package org.apache.tika.eval.app.db
Class JDBCUtil
java.lang.Object
org.apache.tika.eval.app.db.JDBCUtil
- Direct Known Subclasses:
H2Util
-
Nested Class Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
batchInsert
(PreparedStatement insertStatement, TableInfo table, Map<Cols, String> data) boolean
containsTable
(String tableName) void
createTables
(List<TableInfo> tableInfos, JDBCUtil.CREATE_TABLE createTable) boolean
dropTableIfExists
(Connection conn, String tableName) Override this any optimizations you want to do on the db before writing/reading.JDBC driver class.getTables
(Connection connection) static void
updateInsertStatement
(int dbColOffset, PreparedStatement st, ColInfo colInfo, String value)
-
Constructor Details
-
JDBCUtil
-
-
Method Details
-
batchInsert
public static void batchInsert(PreparedStatement insertStatement, TableInfo table, Map<Cols, String> data) throws SQLException- Throws:
SQLException
-
updateInsertStatement
public static void updateInsertStatement(int dbColOffset, PreparedStatement st, ColInfo colInfo, String value) throws SQLException - Throws:
SQLException
-
getConnection
Override this any optimizations you want to do on the db before writing/reading.- Returns:
- Throws:
IOException
SQLException
-
getJDBCDriverClass
JDBC driver class. Override as necessary.- Returns:
-
dropTableIfExists
- Throws:
SQLException
-
getConnectionString
-
getTables
- Throws:
SQLException
-
createTables
public void createTables(List<TableInfo> tableInfos, JDBCUtil.CREATE_TABLE createTable) throws SQLException, IOException - Throws:
SQLException
IOException
-
containsTable
- Throws:
SQLException
-