org.hsqldb.rowio
Class RowInputBase
java.lang.Object
java.io.InputStream
org.hsqldb.lib.HsqlByteArrayInputStream
org.hsqldb.rowio.RowInputBase
- All Implemented Interfaces:
- DataInput
- Direct Known Subclasses:
- RowInputBinary, RowInputLegacy, RowInputText
- public abstract class RowInputBase
- extends HsqlByteArrayInputStream
Base class for reading the data for a database row in different formats.
Defines the methods that are independent of storage format and declares
the format-dependent methods that subclasses should define.
- Since:
- 1.7.0
- Version:
- 1.7.2
- Author:
- sqlbob@users (RMP), fredt@users
Methods inherited from class org.hsqldb.lib.HsqlByteArrayInputStream |
available, close, mark, markSupported, read, read, readBoolean, readByte, readChar, readDouble, readFloat, readFully, readFully, readInt, readLong, readShort, readUnsignedByte, readUnsignedShort, readUTF, reset, skip |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
filePos
protected int filePos
nextPos
protected int nextPos
size
protected int size
makeSystemId
protected boolean makeSystemId
RowInputBase
public RowInputBase()
RowInputBase
public RowInputBase(byte[] buf)
- Constructor takes a complete row
newRowInput
public static RowInputInterface newRowInput(int cachedRowType)
throws HsqlException
- Throws:
HsqlException
getPos
public int getPos()
throws IOException
- Throws:
IOException
getNextPos
public int getNextPos()
throws IOException
- Throws:
IOException
getSize
public int getSize()
readIntData
public abstract int readIntData()
throws IOException
- Throws:
IOException
readType
public abstract int readType()
throws IOException
- Throws:
IOException
readString
public abstract String readString()
throws IOException
- Throws:
IOException
checkNull
protected abstract boolean checkNull()
throws IOException
- Throws:
IOException
readChar
protected abstract String readChar(int type)
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readSmallint
protected abstract Integer readSmallint()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readInteger
protected abstract Integer readInteger()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readBigint
protected abstract Long readBigint()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readReal
protected abstract Double readReal(int type)
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readDecimal
protected abstract BigDecimal readDecimal()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readBit
protected abstract Boolean readBit()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readTime
protected abstract Time readTime()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readDate
protected abstract Date readDate()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readTimestamp
protected abstract Timestamp readTimestamp()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readOther
protected abstract Object readOther()
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
readBinary
protected abstract Binary readBinary(int type)
throws IOException,
HsqlException
- Throws:
IOException
HsqlException
setSystemId
public void setSystemId(boolean flag)
readData
public Object[] readData(int[] colTypes)
throws IOException,
HsqlException
- reads row data from a stream using the JDBC types in colTypes
- Parameters:
colTypes
- currently only the length is used
- Returns:
-
- Throws:
IOException
HsqlException
resetRow
public void resetRow(int filepos,
int rowsize)
throws IOException
- Used to reset the row, ready for a new row to be written into the
byte[] buffer by an external routine.
- Throws:
IOException
getBuffer
public byte[] getBuffer()
skipBytes
public int skipBytes(int n)
throws IOException
- Specified by:
skipBytes
in interface DataInput
- Overrides:
skipBytes
in class HsqlByteArrayInputStream
- Throws:
IOException
readLine
public String readLine()
throws IOException
- Specified by:
readLine
in interface DataInput
- Overrides:
readLine
in class HsqlByteArrayInputStream
- Throws:
IOException
Copyright © 2001 - 2004 HSQL Development Group. All Rights Reserved.