本文整理汇总了Java中java.sql.ResultSet.FETCH_FORWARD属性的典型用法代码示例。如果您正苦于以下问题:Java ResultSet.FETCH_FORWARD属性的具体用法?Java ResultSet.FETCH_FORWARD怎么用?Java ResultSet.FETCH_FORWARD使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类java.sql.ResultSet
的用法示例。
在下文中一共展示了ResultSet.FETCH_FORWARD属性的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setFetchDirection
@Override
public void setFetchDirection(int direction) throws SQLException
{
checkClosed();
if ((direction != ResultSet.FETCH_FORWARD) && (direction != ResultSet.FETCH_REVERSE) && (direction != ResultSet.FETCH_UNKNOWN)) {
throw SQLError.get(SQLError.ILLEGAL_ARGUMENT, direction);
}
this.fetchDirection = direction;
}
示例2: getFetchDirection
public int getFetchDirection() throws SQLException {
try {
if (this.wrappedStmt != null) {
return this.wrappedStmt.getFetchDirection();
}
throw SQLError.createSQLException("Statement already closed", SQLError.SQL_STATE_ILLEGAL_ARGUMENT, this.exceptionInterceptor);
} catch (SQLException sqlEx) {
checkAndFireConnectionError(sqlEx);
}
return ResultSet.FETCH_FORWARD; // we actually never get here, but the compiler can't figure that out
}
示例3: getFetchDirection
public int getFetchDirection() throws SQLException {
if (conn.isClosed()) {
throw new SQLException(BlancoGenericJdbcConstants.MESSAGE_DATABASE_CLOSED);
}
// Always FETCH FORWARD.
return ResultSet.FETCH_FORWARD;
}
示例4: rowSetFetchDirection
@DataProvider(name = "rowSetFetchDirection")
protected Object[][] rowSetFetchDirection() throws Exception {
RowSet rs = newInstance();
return new Object[][]{
{rs, ResultSet.FETCH_FORWARD},
{rs, ResultSet.FETCH_REVERSE},
{rs, ResultSet.FETCH_UNKNOWN}
};
}
示例5: setFetchDirection
@Override
public void setFetchDirection(int direction) throws SQLException {
checkConnection("setFetchDirection");
if (direction != ResultSet.FETCH_FORWARD) {
throw new SQLException(String.format("direction %d is not supported!", direction));
}
}
示例6: setFetchDirection
public void setFetchDirection(int direction) throws SQLException
{
if (direction != ResultSet.FETCH_FORWARD)
throw new SQLFeatureNotSupportedException("Only FETCH_FORWARD is supported");
}
示例7: getFetchDirection
public int getFetchDirection() throws SQLException
{
return ResultSet.FETCH_FORWARD;
}
示例8: getFetchDirection
public int getFetchDirection() throws SQLException {
checkOpen();
return ResultSet.FETCH_FORWARD;
}
示例9: setFetchDirection
public void setFetchDirection(int d) throws SQLException {
checkOpen();
if (d != ResultSet.FETCH_FORWARD)
throw new SQLException("only FETCH_FORWARD direction supported");
}
示例10: getFetchDirection
@Override
default int getFetchDirection() throws SQLException {
return ResultSet.FETCH_FORWARD;
}
示例11: getFetchDirection
@Override
public int getFetchDirection() throws SQLException {
return ResultSet.FETCH_FORWARD;
}
示例12: getFetchDirection
@Override
public int getFetchDirection() throws SQLException {
checkConnection("getFetchDirection");
return ResultSet.FETCH_FORWARD;
}