RS
- The result setIDX
- The index typepublic interface ResultReader<RS,IDX>
Modifier and Type | Method and Description |
---|---|
default <T> T |
convertRequired(java.lang.Object value,
io.micronaut.core.type.Argument<T> type)
Convert the value to the given type.
|
default <T> T |
convertRequired(java.lang.Object value,
java.lang.Class<T> type)
Convert the value to the given type.
|
<T> T |
getRequiredValue(RS resultSet,
IDX name,
java.lang.Class<T> type)
Get a value from the given result set for the given name and type.
|
boolean |
next(RS resultSet)
Move the index to the next result if possible.
|
default java.math.BigDecimal |
readBigDecimal(RS resultSet,
IDX name)
Read a BigDecimal value for the given name.
|
default boolean |
readBoolean(RS resultSet,
IDX name)
Read a boolean value for the given name.
|
default byte |
readByte(RS resultSet,
IDX name)
Read a byte value for the given name.
|
default byte[] |
readBytes(RS resultSet,
IDX name)
Read a byte[] value for the given name.
|
default char |
readChar(RS resultSet,
IDX name)
Read a char value for the given name.
|
default java.util.Date |
readDate(RS resultSet,
IDX name)
Read a date value for the given name.
|
default double |
readDouble(RS resultSet,
IDX name)
Read a double value for the given name.
|
default java.lang.Object |
readDynamic(RS resultSet,
IDX index,
DataType dataType)
Read a value dynamically using the result set and the given name and data type.
|
default float |
readFloat(RS resultSet,
IDX name)
Read a float value for the given name.
|
default int |
readInt(RS resultSet,
IDX name)
Read a int value for the given name.
|
default long |
readLong(RS resultSet,
IDX name)
Read a long value for the given name.
|
default short |
readShort(RS resultSet,
IDX name)
Read a short value for the given name.
|
default java.lang.String |
readString(RS resultSet,
IDX name)
Read a string value for the given name.
|
default java.util.Date |
readTimestamp(RS resultSet,
IDX index)
Read a timestamp value for the given index.
|
default java.util.UUID |
readUUID(RS resultSet,
IDX name)
Read a UUID value for the given name.
|
default <T> T convertRequired(@NonNull java.lang.Object value, java.lang.Class<T> type)
T
- The generic typevalue
- The valuetype
- The typeDataAccessException
- if the value cannot be converteddefault <T> T convertRequired(@NonNull java.lang.Object value, io.micronaut.core.type.Argument<T> type)
T
- The generic typevalue
- The valuetype
- The typeDataAccessException
- if the value cannot be converted@Nullable <T> T getRequiredValue(RS resultSet, IDX name, java.lang.Class<T> type) throws DataAccessException
T
- The generic typeresultSet
- The result setname
- The nametype
- The typeDataAccessException
- if the value cannot be readboolean next(RS resultSet)
resultSet
- The result set@Nullable default java.lang.Object readDynamic(@NonNull RS resultSet, @NonNull IDX index, @NonNull DataType dataType)
resultSet
- The result setindex
- The namedataType
- The data typeDataAccessException
- if the value cannot be readdefault long readLong(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default char readChar(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default java.util.Date readDate(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default java.util.Date readTimestamp(RS resultSet, IDX index)
resultSet
- The result setindex
- The index (such as the column name)@Nullable default java.lang.String readString(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)@Nullable default java.util.UUID readUUID(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default int readInt(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default boolean readBoolean(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default float readFloat(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default byte readByte(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default short readShort(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default double readDouble(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)default java.math.BigDecimal readBigDecimal(RS resultSet, IDX name)
resultSet
- The result setname
- The name (such as the column name)