public class MariaSelectResultSet extends AbstractSelectResultSet
| Modifier and Type | Field and Description |
|---|---|
boolean |
callableResult |
protected int |
columnInformationLength |
static MariaSelectResultSet |
EMPTY |
protected int |
fetchSize |
protected MariaSelectResultSet |
moreResult |
protected List<ValueObject[]> |
resultSet |
protected int |
resultSetScrollType |
cal, columnNameMap, columnsInformation, isClosed, lastGetWasNull, options, protocol, rowPointer, statementCLOSE_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| Constructor and Description |
|---|
MariaSelectResultSet(ColumnInformation[] columnInformation,
List<ValueObject[]> resultSet,
Protocol protocol,
int resultSetScrollType)
Create filled resultset.
|
MariaSelectResultSet(ColumnInformation[] columnInformation,
Statement statement,
Protocol protocol,
ReadPacketFetcher fetcher,
boolean binaryProtocol,
int resultSetScrollType,
int fetchSize,
boolean callableResult)
Create Streaming resultset.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
absolute(int row) |
void |
afterLast() |
void |
beforeFirst() |
void |
clearWarnings() |
void |
close()
Close resultset.
|
static ResultSet |
createGeneratedData(long[] data,
Protocol protocol,
boolean findColumnReturnsOne)
Create a result set from given data.
|
static MariaSelectResultSet |
createResult(Statement statement,
ResultSetPacket packet,
ReadPacketFetcher packetFetcher,
Protocol protocol,
boolean binaryProtocol,
int resultSetScrollType,
int fetchSize,
boolean canBeCallableResult)
Create streaming resultset.
|
static ResultSet |
createResultSet(String[] columnNames,
MariaDbType[] columnTypes,
String[][] data,
Protocol protocol)
Create a result set from given data.
|
boolean |
first() |
int |
getConcurrency() |
int |
getFetchDirection() |
int |
getFetchSize() |
MariaSelectResultSet |
getMoreResult() |
int |
getRow() |
int |
getType() |
protected ValueObject |
getValueObject(int position) |
SQLWarning |
getWarnings() |
void |
initFetch()
Initialize and fetch first value.
|
boolean |
isAfterLast() |
boolean |
isBeforeFirst() |
boolean |
isBinaryProtocol() |
boolean |
isCallableResult() |
boolean |
isFirst() |
boolean |
isLast() |
boolean |
last() |
boolean |
next() |
boolean |
previous() |
boolean |
readNextValue(List<ValueObject[]> values)
Read next value.
|
boolean |
relative(int rows) |
void |
setCallableResult(boolean callableResult) |
void |
setFetchDirection(int direction) |
void |
setFetchSize(int fetchSize) |
void |
setMoreResult(MariaSelectResultSet moreResult) |
cancelRowUpdates, deleteRow, findColumn, getArray, getArray, getAsciiStream, getAsciiStream, getBigDecimal, getBigDecimal, getBigDecimal, getBigDecimal, getBinaryStream, getBinaryStream, getBlob, getBlob, getBoolean, getBoolean, getByte, getByte, getBytes, getBytes, getCharacterStream, getCharacterStream, getClob, getClob, getCursorName, getDate, getDate, getDate, getDate, getDouble, getDouble, getFloat, getFloat, getHoldability, getInt, getInt, getLong, getLong, getMetaData, getNCharacterStream, getNCharacterStream, getNClob, getNClob, getNString, getNString, getObject, getObject, getObject, getObject, getObject, getObject, getRef, getRef, getRowId, getRowId, getShort, getShort, getSQLXML, getSQLXML, getStatement, getString, getString, getTime, getTime, getTime, getTime, getTimestamp, getTimestamp, getTimestamp, getTimestamp, getUnicodeStream, getUnicodeStream, getURL, getURL, insertRow, isClosed, isWrapperFor, moveToCurrentRow, moveToInsertRow, refreshRow, rowDeleted, rowInserted, rowUpdated, setReturnTableAlias, setStatement, unwrap, 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, updateRef, updateRef, updateRow, updateRowId, updateRowId, updateShort, updateShort, updateSQLXML, updateSQLXML, updateString, updateString, updateTime, updateTime, updateTimestamp, updateTimestamp, wasNullclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitupdateObject, updateObject, updateObject, updateObjectpublic static final MariaSelectResultSet EMPTY
protected int columnInformationLength
protected List<ValueObject[]> resultSet
protected int fetchSize
protected int resultSetScrollType
protected MariaSelectResultSet moreResult
public boolean callableResult
public MariaSelectResultSet(ColumnInformation[] columnInformation, Statement statement, Protocol protocol, ReadPacketFetcher fetcher, boolean binaryProtocol, int resultSetScrollType, int fetchSize, boolean callableResult)
columnInformation - column informationstatement - statementprotocol - current protocolfetcher - stream fetcherbinaryProtocol - is binary protocol ?resultSetScrollType - one of the following ResultSet constants: ResultSet.TYPE_FORWARD_ONLY,
ResultSet.TYPE_SCROLL_INSENSITIVE, or ResultSet.TYPE_SCROLL_SENSITIVEfetchSize - current fetch sizecallableResult - is it a callableResultpublic MariaSelectResultSet(ColumnInformation[] columnInformation, List<ValueObject[]> resultSet, Protocol protocol, int resultSetScrollType)
columnInformation - column informationresultSet - resultsetprotocol - current protocolresultSetScrollType - one of the following ResultSet constants: ResultSet.TYPE_FORWARD_ONLY,
ResultSet.TYPE_SCROLL_INSENSITIVE, or ResultSet.TYPE_SCROLL_SENSITIVEpublic static ResultSet createGeneratedData(long[] data, Protocol protocol, boolean findColumnReturnsOne)
data - - each element of this array represents a complete row in the ResultSet. Each value is given in its string representation, as in
MySQL text protocol, except boolean (BIT(1)) values that are represented as "1" or "0" stringsprotocol - protocolfindColumnReturnsOne - - special parameter, used only in generated key result setspublic static ResultSet createResultSet(String[] columnNames, MariaDbType[] columnTypes, String[][] data, Protocol protocol)
columnNames - - string array of column namescolumnTypes - - column typesdata - - each element of this array represents a complete row in the ResultSet. Each value is given in its string representation, as in
MySQL text protocol, except boolean (BIT(1)) values that are represented as "1" or "0" stringsprotocol - protocolpublic static MariaSelectResultSet createResult(Statement statement, ResultSetPacket packet, ReadPacketFetcher packetFetcher, Protocol protocol, boolean binaryProtocol, int resultSetScrollType, int fetchSize, boolean canBeCallableResult) throws IOException, QueryException
statement - current statementpacket - the result set stream from the serverpacketFetcher - packetfetcherprotocol - current protocolbinaryProtocol - is the mysql protocol binaryresultSetScrollType - one of the following ResultSet constants: ResultSet.TYPE_FORWARD_ONLY,
ResultSet.TYPE_SCROLL_INSENSITIVE, or ResultSet.TYPE_SCROLL_SENSITIVEfetchSize - current fetch sizecanBeCallableResult - is this resultset can be an callable output result ? (permit to avoid read the oef ok packet)IOException - when something goes wrong while reading/writing from the serverQueryException - if there is an actual active result on the current connectionpublic void initFetch()
throws IOException,
QueryException
IOException - exceptionQueryException - exceptionpublic boolean isBinaryProtocol()
isBinaryProtocol in class AbstractSelectResultSetpublic boolean readNextValue(List<ValueObject[]> values) throws IOException, QueryException
values - valuesIOException - exceptionQueryException - exceptionpublic void close()
throws SQLException
close in interface AutoCloseableclose in interface ResultSetclose in class AbstractSelectResultSetSQLExceptionpublic boolean next()
throws SQLException
next in interface ResultSetnext in class AbstractSelectResultSetSQLExceptionprotected ValueObject getValueObject(int position) throws SQLException
getValueObject in class AbstractSelectResultSetSQLExceptionpublic SQLWarning getWarnings() throws SQLException
getWarnings in interface ResultSetgetWarnings in class AbstractSelectResultSetSQLExceptionpublic void clearWarnings()
throws SQLException
clearWarnings in interface ResultSetclearWarnings in class AbstractSelectResultSetSQLExceptionpublic boolean isBeforeFirst()
throws SQLException
isBeforeFirst in interface ResultSetisBeforeFirst in class AbstractSelectResultSetSQLExceptionpublic boolean isAfterLast()
throws SQLException
isAfterLast in interface ResultSetisAfterLast in class AbstractSelectResultSetSQLExceptionpublic boolean isFirst()
throws SQLException
isFirst in interface ResultSetisFirst in class AbstractSelectResultSetSQLExceptionpublic boolean isLast()
throws SQLException
isLast in interface ResultSetisLast in class AbstractSelectResultSetSQLExceptionpublic void beforeFirst()
throws SQLException
beforeFirst in interface ResultSetbeforeFirst in class AbstractSelectResultSetSQLExceptionpublic void afterLast()
throws SQLException
afterLast in interface ResultSetafterLast in class AbstractSelectResultSetSQLExceptionpublic boolean first()
throws SQLException
first in interface ResultSetfirst in class AbstractSelectResultSetSQLExceptionpublic boolean last()
throws SQLException
last in interface ResultSetlast in class AbstractSelectResultSetSQLExceptionpublic int getRow()
throws SQLException
getRow in interface ResultSetgetRow in class AbstractSelectResultSetSQLExceptionpublic boolean absolute(int row)
throws SQLException
absolute in interface ResultSetabsolute in class AbstractSelectResultSetSQLExceptionpublic boolean relative(int rows)
throws SQLException
relative in interface ResultSetrelative in class AbstractSelectResultSetSQLExceptionpublic boolean previous()
throws SQLException
previous in interface ResultSetprevious in class AbstractSelectResultSetSQLExceptionpublic int getFetchDirection()
throws SQLException
getFetchDirection in interface ResultSetgetFetchDirection in class AbstractSelectResultSetSQLExceptionpublic void setFetchDirection(int direction)
throws SQLException
setFetchDirection in interface ResultSetsetFetchDirection in class AbstractSelectResultSetSQLExceptionpublic int getFetchSize()
throws SQLException
getFetchSize in interface ResultSetgetFetchSize in class AbstractSelectResultSetSQLExceptionpublic void setFetchSize(int fetchSize)
throws SQLException
setFetchSize in interface ResultSetsetFetchSize in class AbstractSelectResultSetSQLExceptionpublic int getType()
throws SQLException
getType in interface ResultSetgetType in class AbstractSelectResultSetSQLExceptionpublic int getConcurrency()
throws SQLException
getConcurrency in interface ResultSetgetConcurrency in class AbstractSelectResultSetSQLExceptionpublic MariaSelectResultSet getMoreResult()
public void setMoreResult(MariaSelectResultSet moreResult)
public boolean isCallableResult()
public void setCallableResult(boolean callableResult)
Copyright © 2016. All rights reserved.