3334353637383940
return false; next = mapper.map(sars.getResultSet()); return true; } catch (SQLException e) { throw new DAOException(e); } }
798081828384858687
} catch (JsonParseException e) { throw new IllegalArgumentException(e); } catch (JsonMappingException e) { throw new IllegalArgumentException(e); } catch (IOException e) { throw new DAOException(e); } return new MessageEnvelope(json).freeze(); }
45464748495051525354
ps = cn.prepareStatement(sql); ps.setString(1, t.key()); ps.setString(2, t.value()); ps.execute(); } catch (SQLException e) { throw new DAOException(e); } finally { close(ps); } }
63646566676869707172
ps = cn.prepareStatement(sql); ps.setString(1, t.value()); ps.setString(2, t.key()); ps.execute(); } catch (SQLException e) { throw new DAOException(e); } finally { close(ps); } }
8788899091929394959697
String value = rs.getString(1); return new ConfigurationItem(key, value); } else return null; } catch (SQLException e) { throw new DAOException(e); } finally { close(rs); close(ps); } }
108109110111112113114115116117118
ps = cn.prepareStatement(sql); ps.setString(1, key); rs = ps.executeQuery(); return rs.next(); } catch (SQLException e) { throw new DAOException(e); } finally { close(rs); close(ps); } }
127128129130131132133134135136
String sql = "DELETE FROM " + TABLE_NAME + " WHERE key = ?"; ps = cn.prepareStatement(sql); ps.setString(1, key); ps.execute(); } catch (SQLException e) { throw new DAOException(e); } finally { close(ps); } }
3637383940414243
if (existsTable(con, tableName)) return; createEntitiesTable(con.getConnection()); } catch (SQLException e) { throw new DAOException(e); } }
85868788899091929394
ps.setNull(4, Types.NULL); ps.setTimestamp(5, new Timestamp(entity.getUpdatedAt().getTime())); ps.execute(); } catch (SQLException e) { throw new DAOException(e); } finally { close(ps); } }
107108109110111112113114115116
ps.setTimestamp(4, new Timestamp(TimeUtil.getCurrentTime())); ps.setObject(5, entity.getId(), Types.OTHER); ps.execute(); } catch (SQLException e) { throw new DAOException(e); } finally { close(ps); } }