Package org.sqlite.jdbc3
Class JDBC3ResultSet
- java.lang.Object
-
- org.sqlite.core.CoreResultSet
-
- org.sqlite.jdbc3.JDBC3ResultSet
-
- All Implemented Interfaces:
Codes
- Direct Known Subclasses:
JDBC4ResultSet
public abstract class JDBC3ResultSet extends CoreResultSet
-
-
Field Summary
Fields Modifier and Type Field Description protected static Pattern
COLUMN_PRECISION
Pattern used to extract the precision and scale from column meta returned by the JDBC driver.protected static Pattern
COLUMN_TYPECAST
Pattern used to extract the column type name from a cast(col as type)protected static Pattern
COLUMN_TYPENAME
Pattern used to extract the column type name from table column definition.-
Fields inherited from class org.sqlite.core.CoreResultSet
closeStmt, cols, colsMeta, columnNameToIndex, emptyResultSet, lastCol, limitRows, maxRows, meta, open, pastLastRow, row, stmt
-
Fields inherited from interface org.sqlite.core.Codes
SQLITE_ABORT, SQLITE_AUTH, SQLITE_BLOB, SQLITE_BUSY, SQLITE_CANTOPEN, SQLITE_CONSTRAINT, SQLITE_CORRUPT, SQLITE_DONE, SQLITE_EMPTY, SQLITE_ERROR, SQLITE_FLOAT, SQLITE_FULL, SQLITE_INTEGER, SQLITE_INTERNAL, SQLITE_INTERRUPT, SQLITE_IOERR, SQLITE_LOCKED, SQLITE_MISMATCH, SQLITE_MISUSE, SQLITE_NOLFS, SQLITE_NOMEM, SQLITE_NOTFOUND, SQLITE_NULL, SQLITE_OK, SQLITE_PERM, SQLITE_PROTOCOL, SQLITE_READONLY, SQLITE_ROW, SQLITE_SCHEMA, SQLITE_TEXT, SQLITE_TOOBIG
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
JDBC3ResultSet(CoreStatement stmt)
-
Method Summary
-
Methods inherited from class org.sqlite.core.CoreResultSet
addColumnIndexInCache, checkCol, checkMeta, checkOpen, close, findColumnIndexInCache, getConnectionConfig, getDatabase, isOpen, markCol
-
-
-
-
Field Detail
-
COLUMN_TYPENAME
protected static final Pattern COLUMN_TYPENAME
Pattern used to extract the column type name from table column definition.
-
COLUMN_TYPECAST
protected static final Pattern COLUMN_TYPECAST
Pattern used to extract the column type name from a cast(col as type)
-
COLUMN_PRECISION
protected static final Pattern COLUMN_PRECISION
Pattern used to extract the precision and scale from column meta returned by the JDBC driver.
-
-
Constructor Detail
-
JDBC3ResultSet
protected JDBC3ResultSet(CoreStatement stmt)
-
-
Method Detail
-
findColumn
public int findColumn(String col) throws SQLException
returns col in [1,x] form- Throws:
SQLException
- See Also:
ResultSet.findColumn(java.lang.String)
-
next
public boolean next() throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.next()
-
getType
public int getType()
- See Also:
ResultSet.getType()
-
getFetchSize
public int getFetchSize()
- See Also:
ResultSet.getFetchSize()
-
setFetchSize
public void setFetchSize(int rows) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.setFetchSize(int)
-
getFetchDirection
public int getFetchDirection() throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getFetchDirection()
-
setFetchDirection
public void setFetchDirection(int d) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.setFetchDirection(int)
-
isAfterLast
public boolean isAfterLast()
- See Also:
ResultSet.isAfterLast()
-
isBeforeFirst
public boolean isBeforeFirst()
- See Also:
ResultSet.isBeforeFirst()
-
isFirst
public boolean isFirst()
- See Also:
ResultSet.isFirst()
-
isLast
public boolean isLast() throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.isLast()
-
getRow
public int getRow()
- See Also:
ResultSet.getRow()
-
wasNull
public boolean wasNull() throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.wasNull()
-
getBigDecimal
public BigDecimal getBigDecimal(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBigDecimal(int)
-
getBigDecimal
public BigDecimal getBigDecimal(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBigDecimal(java.lang.String)
-
getBoolean
public boolean getBoolean(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBoolean(int)
-
getBoolean
public boolean getBoolean(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBoolean(java.lang.String)
-
getBinaryStream
public InputStream getBinaryStream(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBinaryStream(int)
-
getBinaryStream
public InputStream getBinaryStream(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBinaryStream(java.lang.String)
-
getByte
public byte getByte(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getByte(int)
-
getByte
public byte getByte(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getByte(java.lang.String)
-
getBytes
public byte[] getBytes(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBytes(int)
-
getBytes
public byte[] getBytes(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getBytes(java.lang.String)
-
getCharacterStream
public Reader getCharacterStream(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getCharacterStream(int)
-
getCharacterStream
public Reader getCharacterStream(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getCharacterStream(java.lang.String)
-
getDate
public Date getDate(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getDate(int)
-
getDate
public Date getDate(int col, Calendar cal) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getDate(int, java.util.Calendar)
-
getDate
public Date getDate(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getDate(java.lang.String)
-
getDate
public Date getDate(String col, Calendar cal) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getDate(java.lang.String, java.util.Calendar)
-
getDouble
public double getDouble(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getDouble(int)
-
getDouble
public double getDouble(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getDouble(java.lang.String)
-
getFloat
public float getFloat(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getFloat(int)
-
getFloat
public float getFloat(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getFloat(java.lang.String)
-
getInt
public int getInt(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getInt(int)
-
getInt
public int getInt(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getInt(java.lang.String)
-
getLong
public long getLong(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getLong(int)
-
getLong
public long getLong(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getLong(java.lang.String)
-
getShort
public short getShort(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getShort(int)
-
getShort
public short getShort(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getShort(java.lang.String)
-
getString
public String getString(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getString(int)
-
getString
public String getString(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getString(java.lang.String)
-
getTime
public Time getTime(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTime(int)
-
getTime
public Time getTime(int col, Calendar cal) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTime(int, java.util.Calendar)
-
getTime
public Time getTime(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTime(java.lang.String)
-
getTime
public Time getTime(String col, Calendar cal) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTime(java.lang.String, java.util.Calendar)
-
getTimestamp
public Timestamp getTimestamp(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTimestamp(int)
-
getTimestamp
public Timestamp getTimestamp(int col, Calendar cal) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTimestamp(int, java.util.Calendar)
-
getTimestamp
public Timestamp getTimestamp(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTimestamp(java.lang.String)
-
getTimestamp
public Timestamp getTimestamp(String c, Calendar ca) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getTimestamp(java.lang.String, java.util.Calendar)
-
getObject
public Object getObject(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getObject(int)
-
getObject
public Object getObject(String col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSet.getObject(java.lang.String)
-
getStatement
public Statement getStatement()
- See Also:
ResultSet.getStatement()
-
getCursorName
public String getCursorName()
- See Also:
ResultSet.getCursorName()
-
getWarnings
public SQLWarning getWarnings()
- See Also:
ResultSet.getWarnings()
-
clearWarnings
public void clearWarnings()
- See Also:
ResultSet.clearWarnings()
-
getMetaData
public ResultSetMetaData getMetaData()
- See Also:
ResultSet.getMetaData()
-
getCatalogName
public String getCatalogName(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getCatalogName(int)
-
getColumnClassName
public String getColumnClassName(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getColumnClassName(int)
-
getColumnCount
public int getColumnCount() throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getColumnCount()
-
getColumnDisplaySize
public int getColumnDisplaySize(int col)
-
getColumnLabel
public String getColumnLabel(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getColumnLabel(int)
-
getColumnName
public String getColumnName(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getColumnName(int)
-
getColumnType
public int getColumnType(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getColumnType(int)
-
getColumnTypeName
public String getColumnTypeName(int col) throws SQLException
- Returns:
- The data type from either the 'create table' statement, or CAST(expr AS TYPE) otherwise sqlite3_value_type.
- Throws:
SQLException
- See Also:
ResultSetMetaData.getColumnTypeName(int)
-
getPrecision
public int getPrecision(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getPrecision(int)
-
getScale
public int getScale(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getScale(int)
-
getSchemaName
public String getSchemaName(int col)
- See Also:
ResultSetMetaData.getSchemaName(int)
-
getTableName
public String getTableName(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.getTableName(int)
-
isNullable
public int isNullable(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.isNullable(int)
-
isAutoIncrement
public boolean isAutoIncrement(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.isAutoIncrement(int)
-
isCaseSensitive
public boolean isCaseSensitive(int col)
- See Also:
ResultSetMetaData.isCaseSensitive(int)
-
isCurrency
public boolean isCurrency(int col)
- See Also:
ResultSetMetaData.isCurrency(int)
-
isDefinitelyWritable
public boolean isDefinitelyWritable(int col)
-
isReadOnly
public boolean isReadOnly(int col)
- See Also:
ResultSetMetaData.isReadOnly(int)
-
isSearchable
public boolean isSearchable(int col)
- See Also:
ResultSetMetaData.isSearchable(int)
-
isSigned
public boolean isSigned(int col) throws SQLException
- Throws:
SQLException
- See Also:
ResultSetMetaData.isSigned(int)
-
isWritable
public boolean isWritable(int col)
- See Also:
ResultSetMetaData.isWritable(int)
-
getConcurrency
public int getConcurrency()
- See Also:
ResultSet.getConcurrency()
-
rowDeleted
public boolean rowDeleted()
- See Also:
ResultSet.rowDeleted()
-
rowInserted
public boolean rowInserted()
- See Also:
ResultSet.rowInserted()
-
rowUpdated
public boolean rowUpdated()
- See Also:
ResultSet.rowUpdated()
-
safeGetColumnType
protected int safeGetColumnType(int col) throws SQLException
- Throws:
SQLException
-
-