T
- Type of items@Immutable public final class ColumnOutcome<T> extends Object implements Outcome<Collection<T>>
Use it when you need the first column:
Collection&lgt;Long> salaries = new JdbcSession(source) .sql("SELECT salary FROM user") .select(new ColumnOutcome<Long>(Long.class));
Supported types are: String
, Long
, Boolean
,
Byte
, Date
, and Utc
.
LAST_INSERT_ID, NOT_EMPTY, UPDATE_COUNT, VOID
Constructor and Description |
---|
ColumnOutcome(Class<T> tpe)
Public ctor.
|
@Loggable(value=1) public Collection<T> handle(ResultSet rset, Statement stmt) throws SQLException
Outcome
handle
in interface Outcome<Collection<T>>
rset
- The result set to processstmt
- The statement used in the runSQLException
- If something goes wrong insideCopyright © 2012–2015 jcabi.com. All rights reserved.