Spec-Zone .ru
спецификации, руководства, описания, API
|
|
JavaTM 2 Platform Standard Edition |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
JDBC 2.0
A input stream that contains a stream of values representing an
instance of an SQL structured or distinct type.
This interface, used only for custom mapping, is used by the driver
behind the scenes, and a programmer never directly invokes
SQLInput
methods.
When the method getObject
is called with an
object of a class implementing the interface SQLData
,
the JDBC driver calls the method SQLData.getSQLType
to determine the SQL type of the user-defined type (UDT)
being custom mapped. The driver
creates an instance of SQLInput
, populating it with the
attributes of the UDT. The driver then passes the input
stream to the method SQLData.readSQL
, which in turn
calls the SQLInput.readXXX
methods
in its implementation for reading the
attributes from the input stream.
Method Summary | |
Array |
readArray()
Reads an array from the stream. |
InputStream |
readAsciiStream()
Returns the next attribute in the stream as a stream of ASCII characters. |
BigDecimal |
readBigDecimal()
Reads the next attribute in the stream as a java.math.BigDecimal object. |
InputStream |
readBinaryStream()
Returns the next attribute in the stream as a stream of uninterpreted bytes. |
Blob |
readBlob()
Reads a BLOB from the stream. |
boolean |
readBoolean()
Reads the next attribute in the stream as a Java boolean. |
byte |
readByte()
Reads the next attribute in the stream as a Java byte. |
byte[] |
readBytes()
Reads the next attribute in the stream as an array of bytes. |
Reader |
readCharacterStream()
Returns the next attribute in the stream as a stream of Unicode characters. |
Clob |
readClob()
Reads a CLOB from the stream. |
Date |
readDate()
Reads the next attribute in the stream as a java.sql.Date object. |
double |
readDouble()
Reads the next attribute in the stream as a Java double. |
float |
readFloat()
Reads the next attribute in the stream as a Java float. |
int |
readInt()
Reads the next attribute in the stream as a Java int. |
long |
readLong()
Reads the next attribute in the stream as a Java long. |
Object |
readObject()
Returns the datum at the head of the stream as a Java object. |
Ref |
readRef()
Reads a REF(<structured-type>) from the stream. |
short |
readShort()
Reads the next attribute in the stream as a Java short. |
String |
readString()
Reads the next attribute in the stream as a Java String. |
Time |
readTime()
Reads the next attribute in the stream as a java.sql.Time object. |
Timestamp |
readTimestamp()
Reads the next attribute in the stream as a java.sql.Timestamp object. |
boolean |
wasNull()
Determines whether the last value read was null. |
Method Detail |
public String readString() throws SQLException
public boolean readBoolean() throws SQLException
public byte readByte() throws SQLException
public short readShort() throws SQLException
public int readInt() throws SQLException
public long readLong() throws SQLException
public float readFloat() throws SQLException
public double readDouble() throws SQLException
public BigDecimal readBigDecimal() throws SQLException
public byte[] readBytes() throws SQLException
public Date readDate() throws SQLException
public Time readTime() throws SQLException
public Timestamp readTimestamp() throws SQLException
public Reader readCharacterStream() throws SQLException
public InputStream readAsciiStream() throws SQLException
public InputStream readBinaryStream() throws SQLException
public Object readObject() throws SQLException
SQLData.readSQL
on that object, which reads additional data from the
stream, using the protocol described for that method.public Ref readRef() throws SQLException
public Blob readBlob() throws SQLException
public Clob readClob() throws SQLException
public Array readArray() throws SQLException
public boolean wasNull() throws SQLException
|
JavaTM 2 Platform Standard Edition |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |