|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.firebirdsql.gds.impl.wire.XdrInputStream
public class XdrInputStream
XdrInputStream is an input stream for reading in data that
is in the XDR format. An XdrInputStream instance is wrapped
around an underlying java.io.InputStream.
| Field Summary | |
|---|---|
protected byte[] |
buf
|
protected int |
count
|
protected static int |
defaultBufferSize
|
protected InputStream |
in
|
protected static byte[] |
pad
|
protected int |
pos
|
| Constructor Summary | |
|---|---|
protected |
XdrInputStream()
|
|
XdrInputStream(InputStream in)
Create a new instance of XdrInputStream. |
| Method Summary | |
|---|---|
void |
close()
Close this input stream and the underlying input stream. |
int |
read()
Read in the next byte of data from the underlying input stream. |
byte[] |
readBuffer()
Read in a byte buffer. |
void |
readFully(byte[] b,
int off,
int len)
Read a given amount of data from the underlying input stream. |
int |
readInt()
Read in an int. |
long |
readLong()
Read in a long. |
byte[] |
readRawBuffer(int len)
Read in a raw array of bytes. |
int |
readShort()
Read in a short. |
void |
readSQLData(int[] ioLength,
isc_stmt_handle_impl stmt)
Read a row of SQL data and store it in the results set of a statement. |
String |
readString()
Read in a String. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final byte[] pad
protected InputStream in
protected static int defaultBufferSize
protected byte[] buf
protected int count
protected int pos
| Constructor Detail |
|---|
protected XdrInputStream()
public XdrInputStream(InputStream in)
XdrInputStream.
in - The underlying InputStream to read from| Method Detail |
|---|
public byte[] readBuffer()
throws IOException
IOException - if an error occurs while reading from the
underlying input stream
public byte[] readRawBuffer(int len)
throws IOException
len - The number of bytes to read
IOException - if an error occurs while reading from the
underlying input stream
public String readString()
throws IOException
String.
String that was read
IOException - if an error occurs while reading from the
underlying input stream
public void readSQLData(int[] ioLength,
isc_stmt_handle_impl stmt)
throws IOException
ioLength - array containing the lengths of each column in the
data row that is to be readstmt - The statement where the row is to be stored
IOException - if an error occurs while reading from the
underlying input stream
public long readLong()
throws IOException
long.
long that was read
IOException - if an error occurs while reading from the
underlying input stream
public int readInt()
throws IOException
int.
int that was read
IOException - if an error occurs while reading from the
underlying input stream
public int readShort()
throws IOException
short.
short that was read
IOException - if an error occurs while reading from the
underlying input stream
public void readFully(byte[] b,
int off,
int len)
throws IOException
b, starting from offset
off.
b - The byte buffer to hold the data that is readoff - The offset at which to start storing data in blen - The number of bytes to be read
IOException - if an error occurs while reading from the
underlying input stream
public int read()
throws IOException
IOException - if an error occurs while reading from the
underlying input stream
public void close()
throws IOException
IOException - if an error occurs while closing the underlying
input stream
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||