public class RestfulResultSet extends AbstractResultSet implements ResultSet
| Modifier and Type | Class and Description |
|---|---|
static class |
RestfulResultSet.Field |
| Modifier and Type | Field and Description |
|---|---|
static DateTimeFormatter |
rfc3339Parser |
timestampPrecision, wasNullCLOSE_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 |
|---|
RestfulResultSet(String database,
Statement statement,
com.alibaba.fastjson.JSONObject resultJson)
由一个result的Json构造结果集,对应执行show databases, show tables等这些语句,返回结果集,但无法获取结果集对应的meta,统一当成String处理
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
absolute(int row) |
void |
afterLast() |
void |
beforeFirst() |
void |
close() |
int |
findColumn(String columnLabel) |
boolean |
first() |
BigDecimal |
getBigDecimal(int columnIndex) |
boolean |
getBoolean(int columnIndex) |
byte |
getByte(int columnIndex) |
byte[] |
getBytes(int columnIndex) |
Date |
getDate(int columnIndex) |
double |
getDouble(int columnIndex) |
float |
getFloat(int columnIndex) |
int |
getInt(int columnIndex) |
long |
getLong(int columnIndex) |
ResultSetMetaData |
getMetaData() |
String |
getNString(int columnIndex) |
Object |
getObject(int columnIndex) |
int |
getRow() |
short |
getShort(int columnIndex) |
Statement |
getStatement() |
String |
getString(int columnIndex) |
Time |
getTime(int columnIndex) |
Timestamp |
getTimestamp(int columnIndex) |
Timestamp |
getTimestamp(int columnIndex,
Calendar cal) |
boolean |
isAfterLast() |
boolean |
isBeforeFirst() |
boolean |
isClosed() |
boolean |
isFirst() |
boolean |
isLast() |
boolean |
last() |
boolean |
next() |
boolean |
previous() |
boolean |
relative(int rows) |
cancelRowUpdates, checkAvailability, clearWarnings, deleteRow, getArray, getArray, getAsciiStream, getAsciiStream, getBigDecimal, getBigDecimal, getBigDecimal, getBinaryStream, getBinaryStream, getBlob, getBlob, getBoolean, getByte, getBytes, getCharacterStream, getCharacterStream, getClob, getClob, getConcurrency, getCursorName, getDate, getDate, getDate, getDouble, getFetchDirection, getFetchSize, getFloat, getHoldability, getInt, getLong, getNCharacterStream, getNCharacterStream, getNClob, getNClob, getNString, getObject, getObject, getObject, getObject, getObject, getRef, getRef, getRowId, getRowId, getShort, getSQLXML, getSQLXML, getString, getTime, getTime, getTime, getTimestamp, getTimestamp, getType, getUnicodeStream, getUnicodeStream, getURL, getURL, getWarnings, insertRow, moveToCurrentRow, moveToInsertRow, refreshRow, rowDeleted, rowInserted, rowUpdated, setFetchDirection, setFetchSize, setTimestampPrecision, 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, wasNullisWrapperFor, unwrapclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcancelRowUpdates, clearWarnings, deleteRow, getArray, getArray, getAsciiStream, getAsciiStream, getBigDecimal, getBigDecimal, getBigDecimal, getBinaryStream, getBinaryStream, getBlob, getBlob, getBoolean, getByte, getBytes, getCharacterStream, getCharacterStream, getClob, getClob, getConcurrency, getCursorName, getDate, getDate, getDate, getDouble, getFetchDirection, getFetchSize, getFloat, getHoldability, getInt, getLong, getNCharacterStream, getNCharacterStream, getNClob, getNClob, getNString, getObject, getObject, getObject, getObject, getObject, getRef, getRef, getRowId, getRowId, getShort, getSQLXML, getSQLXML, getString, getTime, getTime, getTime, getTimestamp, getTimestamp, getType, getUnicodeStream, getUnicodeStream, getURL, getURL, getWarnings, insertRow, moveToCurrentRow, moveToInsertRow, refreshRow, rowDeleted, rowInserted, rowUpdated, setFetchDirection, setFetchSize, 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, updateTimestamp, wasNullisWrapperFor, unwrappublic static DateTimeFormatter rfc3339Parser
public RestfulResultSet(String database, Statement statement, com.alibaba.fastjson.JSONObject resultJson) throws SQLException
resultJson: - 包含data信息的结果集,有sql返回的结果集SQLExceptionpublic boolean next()
throws SQLException
next in interface ResultSetnext in class AbstractResultSetSQLExceptionpublic void close()
throws SQLException
close in interface AutoCloseableclose in interface ResultSetclose in class AbstractResultSetSQLExceptionpublic String getString(int columnIndex) throws SQLException
getString in interface ResultSetgetString in class AbstractResultSetSQLExceptionpublic boolean getBoolean(int columnIndex)
throws SQLException
getBoolean in interface ResultSetgetBoolean in class AbstractResultSetSQLExceptionpublic byte getByte(int columnIndex)
throws SQLException
getByte in interface ResultSetgetByte in class AbstractResultSetSQLExceptionpublic short getShort(int columnIndex)
throws SQLException
getShort in interface ResultSetgetShort in class AbstractResultSetSQLExceptionpublic int getInt(int columnIndex)
throws SQLException
getInt in interface ResultSetgetInt in class AbstractResultSetSQLExceptionpublic long getLong(int columnIndex)
throws SQLException
getLong in interface ResultSetgetLong in class AbstractResultSetSQLExceptionpublic float getFloat(int columnIndex)
throws SQLException
getFloat in interface ResultSetgetFloat in class AbstractResultSetSQLExceptionpublic double getDouble(int columnIndex)
throws SQLException
getDouble in interface ResultSetgetDouble in class AbstractResultSetSQLExceptionpublic byte[] getBytes(int columnIndex)
throws SQLException
getBytes in interface ResultSetgetBytes in class AbstractResultSetSQLExceptionpublic Date getDate(int columnIndex) throws SQLException
getDate in interface ResultSetgetDate in class AbstractResultSetSQLExceptionpublic Time getTime(int columnIndex) throws SQLException
getTime in interface ResultSetgetTime in class AbstractResultSetSQLExceptionpublic Timestamp getTimestamp(int columnIndex) throws SQLException
getTimestamp in interface ResultSetgetTimestamp in class AbstractResultSetSQLExceptionpublic ResultSetMetaData getMetaData() throws SQLException
getMetaData in interface ResultSetgetMetaData in class AbstractResultSetSQLExceptionpublic Object getObject(int columnIndex) throws SQLException
getObject in interface ResultSetgetObject in class AbstractResultSetSQLExceptionpublic int findColumn(String columnLabel) throws SQLException
findColumn in interface ResultSetfindColumn in class AbstractResultSetSQLExceptionpublic BigDecimal getBigDecimal(int columnIndex) throws SQLException
getBigDecimal in interface ResultSetgetBigDecimal in class AbstractResultSetSQLExceptionpublic boolean isBeforeFirst()
throws SQLException
isBeforeFirst in interface ResultSetisBeforeFirst in class AbstractResultSetSQLExceptionpublic boolean isAfterLast()
throws SQLException
isAfterLast in interface ResultSetisAfterLast in class AbstractResultSetSQLExceptionpublic boolean isFirst()
throws SQLException
isFirst in interface ResultSetisFirst in class AbstractResultSetSQLExceptionpublic boolean isLast()
throws SQLException
isLast in interface ResultSetisLast in class AbstractResultSetSQLExceptionpublic void beforeFirst()
throws SQLException
beforeFirst in interface ResultSetbeforeFirst in class AbstractResultSetSQLExceptionpublic void afterLast()
throws SQLException
afterLast in interface ResultSetafterLast in class AbstractResultSetSQLExceptionpublic boolean first()
throws SQLException
first in interface ResultSetfirst in class AbstractResultSetSQLExceptionpublic boolean last()
throws SQLException
last in interface ResultSetlast in class AbstractResultSetSQLExceptionpublic int getRow()
throws SQLException
getRow in interface ResultSetgetRow in class AbstractResultSetSQLExceptionpublic boolean absolute(int row)
throws SQLException
absolute in interface ResultSetabsolute in class AbstractResultSetSQLExceptionpublic boolean relative(int rows)
throws SQLException
relative in interface ResultSetrelative in class AbstractResultSetSQLExceptionpublic boolean previous()
throws SQLException
previous in interface ResultSetprevious in class AbstractResultSetSQLExceptionpublic String getNString(int columnIndex) throws SQLException
getNString in interface ResultSetgetNString in class AbstractResultSetSQLExceptionpublic Statement getStatement() throws SQLException
getStatement in interface ResultSetgetStatement in class AbstractResultSetSQLExceptionpublic Timestamp getTimestamp(int columnIndex, Calendar cal) throws SQLException
getTimestamp in interface ResultSetgetTimestamp in class AbstractResultSetSQLExceptionpublic boolean isClosed()
throws SQLException
isClosed in interface ResultSetisClosed in class AbstractResultSetSQLExceptionCopyright © 2021. All rights reserved.