public class CassandraResultSet extends Object implements CassandraResultSetExtras, CassandraResultSetJsonSupport
ResultSet.
It also implements CassandraResultSetExtras and CassandraResultSetJsonSupport interfaces
providing extra methods not defined in JDBC API to better handle some CQL data types and ease usage of JSON
features SELECT JSON and toJson() provided by Cassandra.
| CQL Type | Java type | Description |
|---|---|---|
| ascii | String | US-ASCII character string |
| bigint | Long | 64-bit signed long |
| blob | ByteBuffer | Arbitrary bytes (no validation) |
| boolean | Boolean | Boolean value: true or false |
| counter | Long | Counter column (64-bit long) |
| date | Date | A date with no corresponding time value; encoded date as a 32-bit integer representing days since epoch (January 1, 1970) |
| decimal | BigDecimal | Variable-precision decimal |
| double | Double | 64-bit IEEE-754 floating point |
| duration | CqlDuration | A duration with nanosecond precision |
| float | Float | 32-bit IEEE-754 floating point |
| inet | InetAddress | IP address string in IPv4 or IPv6 format |
| int | Integer | 32-bit signed integer |
| list | List | A collection of one or more ordered elements:
[literal, literal, literal] |
| map | Map | A JSON-style array of literals:
{ literal : literal, literal : literal ... } |
| set | Set | A collection of one or more elements:
{ literal, literal, literal } |
| smallint | Short | 16-bit signed integer |
| text | String | UTF-8 encoded string |
| time | Time | A value encoded as a 64-bit signed integer representing the number of nanoseconds since midnight |
| timestamp | Timestamp | Date and time with millisecond precision, encoded as 8 bytes since epoch |
| timeuuid | UUID | Version 1 UUID only |
| tinyint | Byte | 8-bits signed integer |
| tuple | TupleValue | A group of 2-3 fields |
| udt | UdtValue | A set of data fields where each field is named and typed |
| uuid | UUID | A UUID in standard UUID format |
| varchar | String | UTF-8 encoded string |
| varint | BigInteger | Arbitrary-precision integer |
| vector | CqlVector | A n-dimensional vector |
See: CQL data types reference and CQL temporal types reference.
Note: CQL type list can also be accessed through the methods ResultSet.getArray(int)
and ResultSet.getArray(String).
ResultSet| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_CONCURRENCY
Default result set concurrency for Cassandra implementation:
ResultSet.CONCUR_READ_ONLY. |
static int |
DEFAULT_HOLDABILITY
Default result set holdability for Cassandra implementation:
ResultSet.HOLD_CURSORS_OVER_COMMIT. |
static int |
DEFAULT_TYPE
Default result set type for Cassandra implementation:
ResultSet.TYPE_FORWARD_ONLY. |
static CassandraResultSet |
EMPTY_RESULT_SET
An empty Cassandra result set.
|
CLOSE_CURSORS_AT_COMMIT, CONCUR_READ_ONLY, CONCUR_UPDATABLE, FETCH_FORWARD, FETCH_REVERSE, FETCH_UNKNOWN, HOLD_CURSORS_OVER_COMMIT, TYPE_FORWARD_ONLY, TYPE_SCROLL_INSENSITIVE, TYPE_SCROLL_SENSITIVE| Modifier and Type | Method and Description |
|---|---|
boolean |
absolute(int row) |
void |
afterLast() |
void |
beforeFirst() |
void |
cancelRowUpdates() |
void |
clearWarnings() |
void |
close() |
void |
deleteRow() |
int |
findColumn(String columnLabel) |
boolean |
first() |
Array |
getArray(int columnIndex) |
Array |
getArray(String columnLabel) |
InputStream |
getAsciiStream(int columnIndex) |
InputStream |
getAsciiStream(String columnLabel) |
BigDecimal |
getBigDecimal(int columnIndex) |
BigDecimal |
getBigDecimal(int columnIndex,
int scale)
Deprecated.
use
getBigDecimal(int). |
BigDecimal |
getBigDecimal(String columnLabel) |
BigDecimal |
getBigDecimal(String columnLabel,
int scale)
Deprecated.
|
BigInteger |
getBigInteger(int columnIndex)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
BigInteger. |
BigInteger |
getBigInteger(String columnLabel)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
BigInteger. |
InputStream |
getBinaryStream(int columnIndex) |
InputStream |
getBinaryStream(String columnLabel) |
Blob |
getBlob(int columnIndex) |
Blob |
getBlob(String columnLabel) |
boolean |
getBoolean(int columnIndex) |
boolean |
getBoolean(String columnLabel) |
byte |
getByte(int columnIndex) |
byte |
getByte(String columnLabel) |
byte[] |
getBytes(int columnIndex) |
byte[] |
getBytes(String columnLabel) |
Reader |
getCharacterStream(int columnIndex) |
Reader |
getCharacterStream(String columnLabel) |
Clob |
getClob(int columnIndex) |
Clob |
getClob(String columnLabel) |
int |
getConcurrency() |
String |
getCursorName() |
Date |
getDate(int columnIndex) |
Date |
getDate(int columnIndex,
Calendar calendar) |
Date |
getDate(String columnLabel) |
Date |
getDate(String columnLabel,
Calendar calendar) |
double |
getDouble(int columnIndex) |
double |
getDouble(String columnLabel) |
com.datastax.oss.driver.api.core.data.CqlDuration |
getDuration(int columnIndex)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
CqlDuration. |
com.datastax.oss.driver.api.core.data.CqlDuration |
getDuration(String columnLabel)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
CqlDuration. |
int |
getFetchDirection() |
int |
getFetchSize() |
float |
getFloat(int columnIndex) |
float |
getFloat(String columnLabel) |
int |
getHoldability() |
int |
getInt(int columnIndex) |
int |
getInt(String columnLabel) |
List<?> |
getList(int columnIndex)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
List. |
List<?> |
getList(String columnLabel)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
List. |
LocalDate |
getLocalDate(int columnIndex)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
LocalDate. |
long |
getLong(int columnIndex) |
long |
getLong(String columnLabel) |
Map<?,?> |
getMap(int columnIndex)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
Map. |
Map<?,?> |
getMap(String columnLabel)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
Map. |
ResultSetMetaData |
getMetaData() |
Reader |
getNCharacterStream(int columnIndex) |
Reader |
getNCharacterStream(String columnLabel) |
NClob |
getNClob(int columnIndex) |
NClob |
getNClob(String columnLabel) |
String |
getNString(int columnIndex) |
String |
getNString(String columnLabel) |
Object |
getObject(int columnIndex) |
<T> T |
getObject(int columnIndex,
Class<T> type) |
Object |
getObject(int columnIndex,
Map<String,Class<?>> map) |
Object |
getObject(String columnLabel) |
<T> T |
getObject(String columnLabel,
Class<T> type) |
Object |
getObject(String columnLabel,
Map<String,Class<?>> map) |
<T> T |
getObjectFromJson(Class<T> type)
Retrieves the value of the column labelled "
[json]", containing a JSON string, in the current row of
this ResultSet object as an instance of type T. |
<T> T |
getObjectFromJson(int columnIndex,
Class<T> type)
Retrieves the value of the designated column in the current row of this
ResultSet object as an instance
of type T from a JSON string. |
<T> T |
getObjectFromJson(String columnLabel,
Class<T> type)
Retrieves the value of the designated column in the current row of this
ResultSet object as an instance
of type T from a JSON string. |
Ref |
getRef(int columnIndex) |
Ref |
getRef(String columnLabel) |
int |
getRow() |
RowId |
getRowId(int columnIndex) |
RowId |
getRowId(String columnLabel) |
Set<?> |
getSet(int columnIndex)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
Set. |
Set<?> |
getSet(String columnLabel)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
Set. |
short |
getShort(int columnIndex) |
short |
getShort(String columnLabel) |
SQLXML |
getSQLXML(int columnIndex) |
SQLXML |
getSQLXML(String columnLabel) |
Statement |
getStatement() |
String |
getString(int columnIndex) |
String |
getString(String columnLabel) |
Time |
getTime(int columnIndex) |
Time |
getTime(int columnIndex,
Calendar calendar) |
Time |
getTime(String columnLabel) |
Time |
getTime(String columnLabel,
Calendar calendar) |
Timestamp |
getTimestamp(int columnIndex) |
Timestamp |
getTimestamp(int columnIndex,
Calendar calendar) |
Timestamp |
getTimestamp(String columnLabel) |
Timestamp |
getTimestamp(String columnLabel,
Calendar calendar) |
int |
getType() |
InputStream |
getUnicodeStream(int columnIndex) |
InputStream |
getUnicodeStream(String columnLabel) |
URL |
getURL(int columnIndex) |
URL |
getURL(String columnLabel) |
com.datastax.oss.driver.api.core.data.CqlVector<?> |
getVector(int columnIndex)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
CqlVector. |
com.datastax.oss.driver.api.core.data.CqlVector<?> |
getVector(String columnLabel)
Retrieves the value of the designated column in the current row of this
ResultSet object as a
CqlVector. |
SQLWarning |
getWarnings() |
protected boolean |
hasMoreRows()
Gets whether this result set has still rows to iterate over.
|
void |
insertRow() |
boolean |
isAfterLast() |
boolean |
isBeforeFirst() |
boolean |
isClosed() |
boolean |
isFirst() |
boolean |
isLast() |
protected boolean |
isQueryResult()
Gets whether the result set is non-null and result of a query (even if has no rows).
|
boolean |
isWrapperFor(Class<?> iface) |
boolean |
last() |
void |
moveToCurrentRow() |
void |
moveToInsertRow() |
boolean |
next() |
boolean |
previous() |
void |
refreshRow() |
boolean |
relative(int arg0) |
boolean |
rowDeleted() |
boolean |
rowInserted() |
boolean |
rowUpdated() |
void |
setFetchDirection(int direction) |
void |
setFetchSize(int size) |
<T> T |
unwrap(Class<T> iface) |
void |
updateArray(int columnIndex,
Array x) |
void |
updateArray(String columnLabel,
Array x) |
void |
updateAsciiStream(int columnIndex,
InputStream x) |
void |
updateAsciiStream(int columnLabel,
InputStream x,
int length) |
void |
updateAsciiStream(int columnIndex,
InputStream x,
long length) |
void |
updateAsciiStream(String columnLabel,
InputStream x) |
void |
updateAsciiStream(String columnLabel,
InputStream x,
int length) |
void |
updateAsciiStream(String columnLabel,
InputStream x,
long length) |
void |
updateBigDecimal(int columnIndex,
BigDecimal x) |
void |
updateBigDecimal(String columnLabel,
BigDecimal x) |
void |
updateBinaryStream(int columnIndex,
InputStream length) |
void |
updateBinaryStream(int columnIndex,
InputStream x,
int length) |
void |
updateBinaryStream(int columnIndex,
InputStream x,
long length) |
void |
updateBinaryStream(String columnLabel,
InputStream x) |
void |
updateBinaryStream(String columnLabel,
InputStream x,
int length) |
void |
updateBinaryStream(String columnLabel,
InputStream x,
long length) |
void |
updateBlob(int columnIndex,
Blob x) |
void |
updateBlob(int columnIndex,
InputStream x) |
void |
updateBlob(int columnIndex,
InputStream x,
long length) |
void |
updateBlob(String columnLabel,
Blob x) |
void |
updateBlob(String columnLabel,
InputStream x) |
void |
updateBlob(String columnLabel,
InputStream x,
long length) |
void |
updateBoolean(int columnIndex,
boolean x) |
void |
updateBoolean(String columnLabel,
boolean x) |
void |
updateByte(int columnIndex,
byte x) |
void |
updateByte(String columnLabel,
byte x) |
void |
updateBytes(int columnIndex,
byte[] x) |
void |
updateBytes(String columnLabel,
byte[] x) |
void |
updateCharacterStream(int columnIndex,
Reader x) |
void |
updateCharacterStream(int columnIndex,
Reader x,
int length) |
void |
updateCharacterStream(int columnIndex,
Reader x,
long length) |
void |
updateCharacterStream(String columnLabel,
Reader x) |
void |
updateCharacterStream(String columnLabel,
Reader x,
int length) |
void |
updateCharacterStream(String columnLabel,
Reader x,
long length) |
void |
updateClob(int columnIndex,
Clob x) |
void |
updateClob(int columnIndex,
Reader x) |
void |
updateClob(int columnIndex,
Reader x,
long length) |
void |
updateClob(String columnLabel,
Clob x) |
void |
updateClob(String columnLabel,
Reader x) |
void |
updateClob(String columnLabel,
Reader x,
long length) |
void |
updateDate(int columnIndex,
Date x) |
void |
updateDate(String columnLabel,
Date x) |
void |
updateDouble(int columnIndex,
double x) |
void |
updateDouble(String columnLabel,
double x) |
void |
updateFloat(int columnIndex,
float x) |
void |
updateFloat(String columnLabel,
float x) |
void |
updateInt(int columnIndex,
int x) |
void |
updateInt(String columnLabel,
int x) |
void |
updateLong(int columnIndex,
long x) |
void |
updateLong(String columnLabel,
long x) |
void |
updateNCharacterStream(int columnIndex,
Reader x) |
void |
updateNCharacterStream(int columnIndex,
Reader x,
long length) |
void |
updateNCharacterStream(String columnLabel,
Reader x) |
void |
updateNCharacterStream(String columnLabel,
Reader x,
long length) |
void |
updateNClob(int columnIndex,
NClob x) |
void |
updateNClob(int columnIndex,
Reader x) |
void |
updateNClob(int columnIndex,
Reader x,
long length) |
void |
updateNClob(String columnLabel,
NClob x) |
void |
updateNClob(String columnLabel,
Reader x) |
void |
updateNClob(String columnLabel,
Reader x,
long length) |
void |
updateNString(int columnIndex,
String x) |
void |
updateNString(String columnLabel,
String x) |
void |
updateNull(int columnIndex) |
void |
updateNull(String columnLabel) |
void |
updateObject(int columnIndex,
Object x) |
void |
updateObject(int columnIndex,
Object x,
int scaleOrLength) |
void |
updateObject(String columnLabel,
Object x) |
void |
updateObject(String columnLabel,
Object x,
int scaleOrLength) |
void |
updateRef(int columnIndex,
Ref x) |
void |
updateRef(String columnLabel,
Ref x) |
void |
updateRow() |
void |
updateRowId(int columnIndex,
RowId x) |
void |
updateRowId(String columnLabel,
RowId x) |
void |
updateShort(int columnIndex,
short x) |
void |
updateShort(String columnLabel,
short x) |
void |
updateSQLXML(int columnIndex,
SQLXML x) |
void |
updateSQLXML(String columnLabel,
SQLXML x) |
void |
updateString(int columnIndex,
String x) |
void |
updateString(String columnLabel,
String x) |
void |
updateTime(int columnIndex,
Time x) |
void |
updateTime(String columnLabel,
Time x) |
void |
updateTimestamp(int columnIndex,
Timestamp x) |
void |
updateTimestamp(String columnLabel,
Timestamp x) |
boolean |
wasNull()
Gets whether a column was a null value.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitabsolute, cancelRowUpdates, deleteRow, first, getCursorName, getNCharacterStream, getNCharacterStream, getNString, getNString, getObject, getObject, getRef, getRef, getSQLXML, getSQLXML, getUnicodeStream, getUnicodeStream, insertRow, last, moveToCurrentRow, moveToInsertRow, previous, refreshRow, relative, rowDeleted, rowInserted, rowUpdated, updateArray, updateArray, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateBigDecimal, updateBigDecimal, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBlob, updateBoolean, updateBoolean, updateByte, updateByte, updateBytes, updateBytes, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateClob, updateClob, updateClob, updateClob, updateClob, updateClob, updateDate, updateDate, updateDouble, updateDouble, updateFloat, updateFloat, updateInt, updateInt, updateLong, updateLong, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNString, updateNString, updateNull, updateNull, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateObject, updateRef, updateRef, updateRow, updateRowId, updateRowId, updateShort, updateShort, updateSQLXML, updateSQLXML, updateString, updateString, updateTime, updateTime, updateTimestamp, updateTimestampisWrapperFor, unwrappublic static final CassandraResultSet EMPTY_RESULT_SET
ResultSet objects.public static final int DEFAULT_TYPE
ResultSet.TYPE_FORWARD_ONLY.public static final int DEFAULT_CONCURRENCY
ResultSet.CONCUR_READ_ONLY.public static final int DEFAULT_HOLDABILITY
ResultSet.HOLD_CURSORS_OVER_COMMIT.public void afterLast()
throws SQLException
afterLast in interface ResultSetSQLExceptionpublic void beforeFirst()
throws SQLException
beforeFirst in interface ResultSetSQLExceptionpublic void clearWarnings()
throws SQLException
clearWarnings in interface ResultSetSQLExceptionpublic void close()
throws SQLException
close in interface AutoCloseableclose in interface ResultSetSQLExceptionpublic int findColumn(String columnLabel) throws SQLException
findColumn in interface ResultSetSQLExceptionpublic InputStream getAsciiStream(int columnIndex) throws SQLException
getAsciiStream in interface ResultSetSQLExceptionpublic InputStream getAsciiStream(String columnLabel) throws SQLException
getAsciiStream in interface ResultSetSQLExceptionpublic Array getArray(int columnIndex) throws SQLException
getArray in interface ResultSetSQLExceptionpublic Array getArray(String columnLabel) throws SQLException
getArray in interface ResultSetSQLExceptionpublic BigDecimal getBigDecimal(int columnIndex) throws SQLException
getBigDecimal in interface ResultSetSQLException@Deprecated public BigDecimal getBigDecimal(int columnIndex, int scale) throws SQLException
getBigDecimal(int).getBigDecimal in interface ResultSetSQLExceptionpublic BigDecimal getBigDecimal(String columnLabel) throws SQLException
getBigDecimal in interface ResultSetSQLException@Deprecated public BigDecimal getBigDecimal(String columnLabel, int scale) throws SQLException
getBigDecimal(String).getBigDecimal in interface ResultSetSQLExceptionpublic BigInteger getBigInteger(int columnIndex) throws SQLException
CassandraResultSetExtrasResultSet object as a
BigInteger.getBigInteger in interface CassandraResultSetExtrascolumnIndex - The column index (the first column is 1).NULL, it should return null.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public BigInteger getBigInteger(String columnLabel) throws SQLException
CassandraResultSetExtrasResultSet object as a
BigInteger.getBigInteger in interface CassandraResultSetExtrascolumnLabel - The label for the column specified with the SQL AS clause. If the SQL AS clause was not
specified, then the label is the name of the column.NULL, it should return null.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public InputStream getBinaryStream(int columnIndex) throws SQLException
getBinaryStream in interface ResultSetSQLExceptionpublic InputStream getBinaryStream(String columnLabel) throws SQLException
getBinaryStream in interface ResultSetSQLExceptionpublic Blob getBlob(int columnIndex) throws SQLException
getBlob in interface ResultSetSQLExceptionpublic Blob getBlob(String columnLabel) throws SQLException
getBlob in interface ResultSetSQLExceptionpublic boolean getBoolean(int columnIndex)
throws SQLException
getBoolean in interface ResultSetSQLExceptionpublic boolean getBoolean(String columnLabel) throws SQLException
getBoolean in interface ResultSetSQLExceptionpublic byte getByte(int columnIndex)
throws SQLException
getByte in interface ResultSetSQLExceptionpublic byte getByte(String columnLabel) throws SQLException
getByte in interface ResultSetSQLExceptionpublic byte[] getBytes(int columnIndex)
throws SQLException
getBytes in interface ResultSetSQLExceptionpublic byte[] getBytes(String columnLabel) throws SQLException
getBytes in interface ResultSetSQLExceptionpublic Reader getCharacterStream(int columnIndex) throws SQLException
getCharacterStream in interface ResultSetSQLExceptionpublic Reader getCharacterStream(String columnLabel) throws SQLException
getCharacterStream in interface ResultSetSQLExceptionpublic Clob getClob(int columnIndex) throws SQLException
getClob in interface ResultSetSQLExceptionpublic Clob getClob(String columnLabel) throws SQLException
getClob in interface ResultSetSQLExceptionpublic int getConcurrency()
throws SQLException
getConcurrency in interface ResultSetSQLExceptionpublic Date getDate(int columnIndex) throws SQLException
getDate in interface ResultSetSQLExceptionpublic Date getDate(int columnIndex, Calendar calendar) throws SQLException
getDate in interface ResultSetSQLExceptionpublic Date getDate(String columnLabel) throws SQLException
getDate in interface ResultSetSQLExceptionpublic Date getDate(String columnLabel, Calendar calendar) throws SQLException
getDate in interface ResultSetSQLExceptionpublic double getDouble(int columnIndex)
throws SQLException
getDouble in interface ResultSetSQLExceptionpublic double getDouble(String columnLabel) throws SQLException
getDouble in interface ResultSetSQLExceptionpublic com.datastax.oss.driver.api.core.data.CqlDuration getDuration(int columnIndex)
throws SQLException
CassandraResultSetExtrasResultSet object as a
CqlDuration.getDuration in interface CassandraResultSetExtrascolumnIndex - The column index (the first column is 1).NULL, it should return null.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public com.datastax.oss.driver.api.core.data.CqlDuration getDuration(String columnLabel) throws SQLException
CassandraResultSetExtrasResultSet object as a
CqlDuration.getDuration in interface CassandraResultSetExtrascolumnLabel - The label for the column specified with the SQL AS clause. If the SQL AS clause was not
specified, then the label is the name of the column.NULL, it should return null.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public int getFetchDirection()
throws SQLException
getFetchDirection in interface ResultSetSQLExceptionpublic void setFetchDirection(int direction)
throws SQLException
setFetchDirection in interface ResultSetSQLExceptionpublic int getFetchSize()
throws SQLException
getFetchSize in interface ResultSetSQLExceptionpublic void setFetchSize(int size)
throws SQLException
setFetchSize in interface ResultSetSQLExceptionpublic float getFloat(int columnIndex)
throws SQLException
getFloat in interface ResultSetSQLExceptionpublic float getFloat(String columnLabel) throws SQLException
getFloat in interface ResultSetSQLExceptionpublic int getHoldability()
throws SQLException
getHoldability in interface ResultSetSQLExceptionpublic int getInt(int columnIndex)
throws SQLException
getInt in interface ResultSetSQLExceptionpublic int getInt(String columnLabel) throws SQLException
getInt in interface ResultSetSQLExceptionpublic List<?> getList(int columnIndex) throws SQLException
CassandraResultSetExtrasResultSet object as a
List.getList in interface CassandraResultSetExtrascolumnIndex - The column index (the first column is 1).NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public List<?> getList(String columnLabel) throws SQLException
CassandraResultSetExtrasResultSet object as a
List.getList in interface CassandraResultSetExtrascolumnLabel - The label for the column specified with the SQL AS clause. If the SQL AS clause was not
specified, then the label is the name of the column.NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public LocalDate getLocalDate(int columnIndex) throws SQLException
ResultSet object as a
LocalDate.columnIndex - The column index (the first column is 1).NULL, it should return null.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public long getLong(int columnIndex)
throws SQLException
getLong in interface ResultSetSQLExceptionpublic long getLong(String columnLabel) throws SQLException
getLong in interface ResultSetSQLExceptionpublic Map<?,?> getMap(int columnIndex) throws SQLException
CassandraResultSetExtrasResultSet object as a
Map.getMap in interface CassandraResultSetExtrascolumnIndex - The column index (the first column is 1).NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public Map<?,?> getMap(String columnLabel) throws SQLException
CassandraResultSetExtrasResultSet object as a
Map.getMap in interface CassandraResultSetExtrascolumnLabel - The label for the column specified with the SQL AS clause. If the SQL AS clause was not
specified, then the label is the name of the column.NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public ResultSetMetaData getMetaData()
getMetaData in interface ResultSetpublic NClob getNClob(int columnIndex) throws SQLException
getNClob in interface ResultSetSQLExceptionpublic NClob getNClob(String columnLabel) throws SQLException
getNClob in interface ResultSetSQLExceptionpublic Object getObject(int columnIndex) throws SQLException
getObject in interface ResultSetSQLExceptionpublic Object getObject(String columnLabel) throws SQLException
getObject in interface ResultSetSQLExceptionpublic <T> T getObject(String columnLabel, Class<T> type) throws SQLException
getObject in interface ResultSetSQLExceptionpublic <T> T getObject(int columnIndex,
Class<T> type)
throws SQLException
getObject in interface ResultSetSQLExceptionpublic <T> T getObjectFromJson(int columnIndex,
Class<T> type)
throws SQLException
CassandraResultSetJsonSupportResultSet object as an instance
of type T from a JSON string.
Typically, this method can be called on a result set returned by a CQL query like:
SELECT JSON col1, col2 FROM exampleTable;
or on a result column defined with the function toJson().
getObjectFromJson in interface CassandraResultSetJsonSupportT - The type of the object represented by the JSON string.columnIndex - The column index (the first column is 1).type - The class representing the Java data type to convert the designated column to.T. If the value is SQL NULL, it should
return null.SQLException - if the columnIndex is not valid; if a database access error occurs; if this method is called
on a closed result set or if the value is cannot be parsed to an object of type T.public <T> T getObjectFromJson(String columnLabel, Class<T> type) throws SQLException
CassandraResultSetJsonSupportResultSet object as an instance
of type T from a JSON string.
Typically, this method can be called on a result set returned by a CQL query like:
SELECT JSON col1, col2 FROM exampleTable;
or on a result column defined with the function toJson().
getObjectFromJson in interface CassandraResultSetJsonSupportT - The type of the object represented by the JSON string.columnLabel - The label for the column specified with the SQL AS clause. If the SQL AS clause was not
specified, then the label is the name of the column.type - The class representing the Java data type to convert the designated column to.T. If the value is SQL NULL, it should
return null.SQLException - if the columnIndex is not valid; if a database access error occurs; if this method is called
on a closed result set or if the value is cannot be parsed to an object of type T.public <T> T getObjectFromJson(Class<T> type) throws SQLException
CassandraResultSetJsonSupport[json]", containing a JSON string, in the current row of
this ResultSet object as an instance of type T.
Typically, this method can be called on a result set returned by a CQL query like:
SELECT JSON * FROM exampleTable;
getObjectFromJson in interface CassandraResultSetJsonSupportT - The type of the object represented by the JSON string.type - The class representing the Java data type to convert the column value to.T. If the value is SQL NULL, it should
return null.SQLException - if the columnIndex is not valid; if a database access error occurs; if this method is called
on a closed result set or if the value is cannot be parsed to an object of type T.public int getRow()
throws SQLException
getRow in interface ResultSetSQLExceptionpublic Set<?> getSet(int columnIndex) throws SQLException
CassandraResultSetExtrasResultSet object as a
Set.getSet in interface CassandraResultSetExtrascolumnIndex - The column index (the first column is 1).NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public Set<?> getSet(String columnLabel) throws SQLException
CassandraResultSetExtrasResultSet object as a
Set.getSet in interface CassandraResultSetExtrascolumnLabel - The label for the column specified with the SQL AS clause. If the SQL AS clause was not
specified, then the label is the name of the column.NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public short getShort(int columnIndex)
throws SQLException
getShort in interface ResultSetSQLExceptionpublic short getShort(String columnLabel) throws SQLException
getShort in interface ResultSetSQLExceptionpublic Statement getStatement() throws SQLException
getStatement in interface ResultSetSQLExceptionpublic String getString(int columnIndex) throws SQLException
getString in interface ResultSetSQLExceptionpublic String getString(String columnLabel) throws SQLException
getString in interface ResultSetSQLExceptionpublic Time getTime(int columnIndex) throws SQLException
getTime in interface ResultSetSQLExceptionpublic Time getTime(int columnIndex, Calendar calendar) throws SQLException
getTime in interface ResultSetSQLExceptionpublic Time getTime(String columnLabel) throws SQLException
getTime in interface ResultSetSQLExceptionpublic Time getTime(String columnLabel, Calendar calendar) throws SQLException
getTime in interface ResultSetSQLExceptionpublic Timestamp getTimestamp(int columnIndex) throws SQLException
getTimestamp in interface ResultSetSQLExceptionpublic Timestamp getTimestamp(int columnIndex, Calendar calendar) throws SQLException
getTimestamp in interface ResultSetSQLExceptionpublic Timestamp getTimestamp(String columnLabel) throws SQLException
getTimestamp in interface ResultSetSQLExceptionpublic Timestamp getTimestamp(String columnLabel, Calendar calendar) throws SQLException
getTimestamp in interface ResultSetSQLExceptionpublic int getType()
throws SQLException
getType in interface ResultSetSQLExceptionpublic URL getURL(int columnIndex) throws SQLException
getURL in interface ResultSetSQLExceptionpublic URL getURL(String columnLabel) throws SQLException
getURL in interface ResultSetSQLExceptionpublic com.datastax.oss.driver.api.core.data.CqlVector<?> getVector(int columnIndex)
throws SQLException
CassandraResultSetExtrasResultSet object as a
CqlVector.getVector in interface CassandraResultSetExtrascolumnIndex - The column index (the first column is 1).NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public com.datastax.oss.driver.api.core.data.CqlVector<?> getVector(String columnLabel) throws SQLException
CassandraResultSetExtrasResultSet object as a
CqlVector.getVector in interface CassandraResultSetExtrascolumnLabel - The label for the column specified with the SQL AS clause. If the SQL AS clause was not
specified, then the label is the name of the column.NULL, it should return an empty collection or null,
depending on the driver implementation.SQLException - if the columnIndex is not valid; if a database access error occurs or this method is called
on a closed result set.public SQLWarning getWarnings() throws SQLException
getWarnings in interface ResultSetSQLExceptionprotected boolean hasMoreRows()
true if there is still rows to iterate over, false otherwise.protected boolean isQueryResult()
true if the result set is non-null and has at least one column (so it's the result of a query),
false otherwise.public boolean isAfterLast()
throws SQLException
isAfterLast in interface ResultSetSQLExceptionpublic boolean isBeforeFirst()
throws SQLException
isBeforeFirst in interface ResultSetSQLExceptionpublic boolean isFirst()
throws SQLException
isFirst in interface ResultSetSQLExceptionpublic boolean isLast()
throws SQLException
isLast in interface ResultSetSQLExceptionpublic boolean wasNull()
public boolean absolute(int row)
throws SQLException
SQLExceptionpublic void cancelRowUpdates()
throws SQLException
SQLExceptionpublic void deleteRow()
throws SQLException
SQLExceptionpublic boolean first()
throws SQLException
SQLExceptionpublic String getCursorName() throws SQLException
SQLExceptionpublic Reader getNCharacterStream(int columnIndex) throws SQLException
SQLExceptionpublic Reader getNCharacterStream(String columnLabel) throws SQLException
SQLExceptionpublic String getNString(int columnIndex) throws SQLException
SQLExceptionpublic String getNString(String columnLabel) throws SQLException
SQLExceptionpublic Object getObject(int columnIndex, Map<String,Class<?>> map) throws SQLException
SQLExceptionpublic Object getObject(String columnLabel, Map<String,Class<?>> map) throws SQLException
SQLExceptionpublic Ref getRef(int columnIndex) throws SQLException
SQLExceptionpublic Ref getRef(String columnLabel) throws SQLException
SQLExceptionpublic SQLXML getSQLXML(int columnIndex) throws SQLException
SQLExceptionpublic SQLXML getSQLXML(String columnLabel) throws SQLException
SQLExceptionpublic InputStream getUnicodeStream(int columnIndex) throws SQLException
SQLExceptionpublic InputStream getUnicodeStream(String columnLabel) throws SQLException
SQLExceptionpublic void insertRow()
throws SQLException
SQLExceptionpublic boolean last()
throws SQLException
SQLExceptionpublic void moveToCurrentRow()
throws SQLException
SQLExceptionpublic void moveToInsertRow()
throws SQLException
SQLExceptionpublic boolean previous()
throws SQLException
SQLExceptionpublic void refreshRow()
throws SQLException
SQLExceptionpublic boolean relative(int arg0)
throws SQLException
SQLExceptionpublic boolean rowDeleted()
throws SQLException
SQLExceptionpublic boolean rowInserted()
throws SQLException
SQLExceptionpublic boolean rowUpdated()
throws SQLException
SQLExceptionpublic void updateArray(int columnIndex,
Array x)
throws SQLException
SQLExceptionpublic void updateArray(String columnLabel, Array x) throws SQLException
SQLExceptionpublic void updateAsciiStream(int columnIndex,
InputStream x)
throws SQLException
SQLExceptionpublic void updateAsciiStream(int columnLabel,
InputStream x,
int length)
throws SQLException
SQLExceptionpublic void updateAsciiStream(int columnIndex,
InputStream x,
long length)
throws SQLException
SQLExceptionpublic void updateAsciiStream(String columnLabel, InputStream x) throws SQLException
SQLExceptionpublic void updateAsciiStream(String columnLabel, InputStream x, int length) throws SQLException
SQLExceptionpublic void updateAsciiStream(String columnLabel, InputStream x, long length) throws SQLException
SQLExceptionpublic void updateBigDecimal(int columnIndex,
BigDecimal x)
throws SQLException
SQLExceptionpublic void updateBigDecimal(String columnLabel, BigDecimal x) throws SQLException
SQLExceptionpublic void updateBinaryStream(int columnIndex,
InputStream length)
throws SQLException
SQLExceptionpublic void updateBinaryStream(int columnIndex,
InputStream x,
int length)
throws SQLException
SQLExceptionpublic void updateBinaryStream(int columnIndex,
InputStream x,
long length)
throws SQLException
SQLExceptionpublic void updateBinaryStream(String columnLabel, InputStream x) throws SQLException
SQLExceptionpublic void updateBinaryStream(String columnLabel, InputStream x, int length) throws SQLException
SQLExceptionpublic void updateBinaryStream(String columnLabel, InputStream x, long length) throws SQLException
SQLExceptionpublic void updateBlob(int columnIndex,
Blob x)
throws SQLException
SQLExceptionpublic void updateBlob(int columnIndex,
InputStream x)
throws SQLException
SQLExceptionpublic void updateBlob(int columnIndex,
InputStream x,
long length)
throws SQLException
SQLExceptionpublic void updateBlob(String columnLabel, Blob x) throws SQLException
SQLExceptionpublic void updateBlob(String columnLabel, InputStream x) throws SQLException
SQLExceptionpublic void updateBlob(String columnLabel, InputStream x, long length) throws SQLException
SQLExceptionpublic void updateBoolean(int columnIndex,
boolean x)
throws SQLException
SQLExceptionpublic void updateBoolean(String columnLabel, boolean x) throws SQLException
SQLExceptionpublic void updateByte(int columnIndex,
byte x)
throws SQLException
SQLExceptionpublic void updateByte(String columnLabel, byte x) throws SQLException
SQLExceptionpublic void updateBytes(int columnIndex,
byte[] x)
throws SQLException
SQLExceptionpublic void updateBytes(String columnLabel, byte[] x) throws SQLException
SQLExceptionpublic void updateCharacterStream(int columnIndex,
Reader x)
throws SQLException
SQLExceptionpublic void updateCharacterStream(int columnIndex,
Reader x,
int length)
throws SQLException
SQLExceptionpublic void updateCharacterStream(int columnIndex,
Reader x,
long length)
throws SQLException
SQLExceptionpublic void updateCharacterStream(String columnLabel, Reader x) throws SQLException
SQLExceptionpublic void updateCharacterStream(String columnLabel, Reader x, int length) throws SQLException
SQLExceptionpublic void updateCharacterStream(String columnLabel, Reader x, long length) throws SQLException
SQLExceptionpublic void updateClob(int columnIndex,
Clob x)
throws SQLException
SQLExceptionpublic void updateClob(int columnIndex,
Reader x)
throws SQLException
SQLExceptionpublic void updateClob(int columnIndex,
Reader x,
long length)
throws SQLException
SQLExceptionpublic void updateClob(String columnLabel, Clob x) throws SQLException
SQLExceptionpublic void updateClob(String columnLabel, Reader x) throws SQLException
SQLExceptionpublic void updateClob(String columnLabel, Reader x, long length) throws SQLException
SQLExceptionpublic void updateDate(int columnIndex,
Date x)
throws SQLException
SQLExceptionpublic void updateDate(String columnLabel, Date x) throws SQLException
SQLExceptionpublic void updateDouble(int columnIndex,
double x)
throws SQLException
SQLExceptionpublic void updateDouble(String columnLabel, double x) throws SQLException
SQLExceptionpublic void updateFloat(int columnIndex,
float x)
throws SQLException
SQLExceptionpublic void updateFloat(String columnLabel, float x) throws SQLException
SQLExceptionpublic void updateInt(int columnIndex,
int x)
throws SQLException
SQLExceptionpublic void updateInt(String columnLabel, int x) throws SQLException
SQLExceptionpublic void updateLong(int columnIndex,
long x)
throws SQLException
SQLExceptionpublic void updateLong(String columnLabel, long x) throws SQLException
SQLExceptionpublic void updateNCharacterStream(int columnIndex,
Reader x)
throws SQLException
SQLExceptionpublic void updateNCharacterStream(int columnIndex,
Reader x,
long length)
throws SQLException
SQLExceptionpublic void updateNCharacterStream(String columnLabel, Reader x) throws SQLException
SQLExceptionpublic void updateNCharacterStream(String columnLabel, Reader x, long length) throws SQLException
SQLExceptionpublic void updateNClob(int columnIndex,
NClob x)
throws SQLException
SQLExceptionpublic void updateNClob(int columnIndex,
Reader x)
throws SQLException
SQLExceptionpublic void updateNClob(int columnIndex,
Reader x,
long length)
throws SQLException
SQLExceptionpublic void updateNClob(String columnLabel, NClob x) throws SQLException
SQLExceptionpublic void updateNClob(String columnLabel, Reader x) throws SQLException
SQLExceptionpublic void updateNClob(String columnLabel, Reader x, long length) throws SQLException
SQLExceptionpublic void updateNString(int columnIndex,
String x)
throws SQLException
SQLExceptionpublic void updateNString(String columnLabel, String x) throws SQLException
SQLExceptionpublic void updateNull(int columnIndex)
throws SQLException
SQLExceptionpublic void updateNull(String columnLabel) throws SQLException
SQLExceptionpublic void updateObject(int columnIndex,
Object x)
throws SQLException
SQLExceptionpublic void updateObject(int columnIndex,
Object x,
int scaleOrLength)
throws SQLException
SQLExceptionpublic void updateObject(String columnLabel, Object x) throws SQLException
SQLExceptionpublic void updateObject(String columnLabel, Object x, int scaleOrLength) throws SQLException
SQLExceptionpublic void updateRef(int columnIndex,
Ref x)
throws SQLException
SQLExceptionpublic void updateRef(String columnLabel, Ref x) throws SQLException
SQLExceptionpublic void updateRow()
throws SQLException
SQLExceptionpublic void updateRowId(int columnIndex,
RowId x)
throws SQLException
SQLExceptionpublic void updateRowId(String columnLabel, RowId x) throws SQLException
SQLExceptionpublic void updateShort(int columnIndex,
short x)
throws SQLException
SQLExceptionpublic void updateShort(String columnLabel, short x) throws SQLException
SQLExceptionpublic void updateSQLXML(int columnIndex,
SQLXML x)
throws SQLException
SQLExceptionpublic void updateSQLXML(String columnLabel, SQLXML x) throws SQLException
SQLExceptionpublic void updateString(int columnIndex,
String x)
throws SQLException
SQLExceptionpublic void updateString(String columnLabel, String x) throws SQLException
SQLExceptionpublic void updateTime(int columnIndex,
Time x)
throws SQLException
SQLExceptionpublic void updateTime(String columnLabel, Time x) throws SQLException
SQLExceptionpublic void updateTimestamp(int columnIndex,
Timestamp x)
throws SQLException
SQLExceptionpublic void updateTimestamp(String columnLabel, Timestamp x) throws SQLException
SQLExceptionpublic boolean isWrapperFor(Class<?> iface) throws SQLException
isWrapperFor in interface WrapperSQLExceptionpublic <T> T unwrap(Class<T> iface) throws SQLException
unwrap in interface WrapperSQLExceptionCopyright © 2020–2024 ING Bank. All rights reserved.