Ejemplo n.º 1
0
 @Override
 public Circle mapRow(ResultSet rs, int rowNum) throws SQLException {
   Circle circle = new Circle();
   circle.setId(rs.getInt("ID"));
   circle.setName(rs.getString("NAME"));
   return circle;
 }
Ejemplo n.º 2
0
 public void insertCircle(Circle circle) {
   String sql = "INSERT INTO CIRCLE(ID,NAME) VALUES(?, ?)";
   jdbcTemplate.update(sql, new Object[] {circle.getId(), circle.getName()});
 }