package org.h2.samples;
import java.io.InputStream;
import java.io.Reader;
import java.math.BigDecimal;
import java.net.URL;
import java.sql.Array;
import java.sql.Blob;
import java.sql.Clob;
import java.sql.Date;
import java.sql.NClob;
import java.sql.PreparedStatement;
import java.sql.Ref;
import java.sql.ResultSetMetaData;
import java.sql.RowId;
import java.sql.SQLException;
import java.sql.SQLWarning;
import java.sql.SQLXML;
import java.sql.Statement;
import java.sql.Time;
import java.sql.Timestamp;
import java.util.Calendar;
import java.util.Map;
public class PageableResultSet2 implements Pageable {
protected java.sql.ResultSet rs = null;
protected int rowsCount;
protected int pageSize;
protected int curPage;
protected String command = "";
@Override
public boolean next() throws SQLException {
// TODO Auto-generated method stub
return rs.next();
}
@Override
public void close() throws SQLException {
// TODO Auto-generated method stub
}
@Override
public boolean wasNull() throws SQLException {
// TODO Auto-generated method stub
return false;
}
@Override
public String getString(int columnIndex) throws SQLException {
return null;
}
@Override
public boolean getBoolean(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return false;
}
@Override
public byte getByte(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public short getShort(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public int getInt(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public long getLong(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public float getFloat(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public double getDouble(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public BigDecimal getBigDecimal(int columnIndex, int scale)
throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public byte[] getBytes(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Date getDate(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Time getTime(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Timestamp getTimestamp(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public InputStream getAsciiStream(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public InputStream getUnicodeStream(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public InputStream getBinaryStream(int columnIndex) throws SQLException {
return null;
}
@Override
public String getString(String columnName) throws SQLException {
try {
return rs.getString(columnName);
} catch (SQLException e) {
// 这里是为了增加一些出错信息的内容便于调试
throw new SQLException(e.toString() + " columnName=" + columnName
+ " SQL=" + this.getCommand());
}
}
@Override
public boolean getBoolean(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return false;
}
@Override
public byte getByte(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public short getShort(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public int getInt(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public long getLong(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public float getFloat(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public double getDouble(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public BigDecimal getBigDecimal(String columnLabel, int scale)
throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public byte[] getBytes(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Date getDate(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Time getTime(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Timestamp getTimestamp(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public InputStream getAsciiStream(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public InputStream getUnicodeStream(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public InputStream getBinaryStream(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public SQLWarning getWarnings() throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public void clearWarnings() throws SQLException {
// TODO Auto-generated method stub
}
@Override
public String getCursorName() throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public ResultSetMetaData getMetaData() throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Object getObject(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Object getObject(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public int findColumn(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return 0;
}
@Override
public Reader getCharacterStream(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public Reader getCharacterStream(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public BigDecimal getBigDecimal(int columnIndex) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public BigDecimal getBigDecimal(String columnLabel) throws SQLException {
// TODO Auto-generated method stub
return null;
}
@Override
public boolean isBeforeFirst() throws SQLException {
// TODO Auto-generated method stub
return false;
}
@Override
public boolean isAfterLast() throws SQLException {
// TODO Auto-generated method stub
return false;
}
@Override
public boolean isFirst() throws SQLException {
// TODO Auto-generated method stub
return false;
}
@Override
public boolean isLast() throws SQLException {
// TODO Auto-generated method stub
return false;
}
@Override
public void beforeFirst() throws SQLException {
// TODO Auto-generated method stub
}
@Override
public void afterLast() throws SQLException {
// TODO Auto-generated method stub
}
@Override
public boolean first() throws SQLEx