@Test public void testParseQuery() throws Throwable { MySQLDataStore ds = (MySQLDataStore) this.createDataStore(); ds.init(); String partialInsertQuery = "(MD5(?), ?)"; Connection con = ds.dataSource.getConnection(); PreparedStatement stmt = con.prepareStatement(partialInsertQuery); stmt.setString(1, "Pippo"); stmt.setInt(2, 182376); System.out.println(stmt.toString()); }
@Override public void init() throws IOException, IllegalStateException { dataSource = new HikariDataSource(config); }
MySQLDataStore implements DataStore { @Override public void init() throws IOException, IllegalStateException { dataSource = new HikariDataSource(config); } }
MySQLDataStore implements DataStore { @Override public void init() throws IOException, IllegalStateException { dataSource = new HikariDataSource(config); } MySQLDataStore(String host, String username, String password, String databaseName); }
MySQLDataStore implements DataStore { @Override public void init() throws IOException, IllegalStateException { dataSource = new HikariDataSource(config); } MySQLDataStore(String host, String username, String password, String databaseName); @Override DataTransaction begin(boolean readOnly); @Override void init(); @Override void close(); }
MySQLDataStore implements DataStore { @Override public void init() throws IOException, IllegalStateException { dataSource = new HikariDataSource(config); } MySQLDataStore(String host, String username, String password, String databaseName); @Override DataTransaction begin(boolean readOnly); @Override void init(); @Override void close(); public HikariDataSource dataSource; }