private RowMapper<User> rowMap() {
RowMapper<User> row =new RowMapper<User>() {
@Override
public User mapRow(ResultSet rs) throws SQLException {
return new User(
rs.getString("userId"),
rs.getString("password"),
rs.getString("name"),
rs.getString("email"));
}
};
return row;
}
=>
private RowMapper<User> rowMap() {
RowMapper<User> row = rs ->new User(
rs.getString("userId"),
rs.getString("password"),
rs.getString("name"),
rs.getString("email")
);
return row;
}
댓글 ( 4)
댓글 남기기