OutputStream that will use an locator to write
bytes to the Clob value on the server.
Closing a ByteArrayInputStream has no effect. The methods in
this class can be called after the stream has been closed without
generating an IOException.
This OutputStream implementation is pretty basic. No
buffering of data is done. Hence, for efficiency #write(byte[])
should be used instead of #write(int).
| Modifier and Type | Field and Description |
|---|---|
| private final ClientClob | clob
The Clob to be accessed. |
| private long | currentPos
Current position in the underlying Clob. |
| Access | Constructor and Description |
|---|---|
| pack-priv | ClobLocatorOutputStream(ClientClob
Clob object that contains locator for
the Clob value on the server.the position in the pos)CLOB value at which
to start writing; the first position is 1Create an |
| Modifier and Type | Method and Description |
|---|---|
| public void | flush()
Overrides java. Implements java. |
| public void | write(int
the b)byte.Implements abstract java. |
| public void | write(byte[]
the data. b)Overrides java. b.length bytes from the specified byte array
to this output stream.
|
| public void | write(byte[]
the data. b, int the start offset in the data. off, int the number of bytes to write. len)Overrides java. len bytes from the specified byte array
starting at offset off to this output stream.
|
| private void | writeBytes(byte[]
The byte array containing the bytes to be written b)Write the |
| clob | back to summary |
|---|---|
| private final ClientClob clob The Clob to be accessed. | |
| currentPos | back to summary |
|---|---|
| private long currentPos Current position in the underlying Clob. Clobs are indexed from 1 | |
| ClobLocatorOutputStream | back to summary |
|---|---|
| pack-priv ClobLocatorOutputStream(ClientClob clob, long pos) throws SqlException Create an
| |
| flush | back to summary |
|---|---|
| public void flush() Overrides java. Implements java. Doc from java. Flushes this output stream and forces any buffered output bytes
to be written out. The general contract of If the intended destination of this stream is an abstraction provided by the underlying operating system, for example a file, then flushing the stream guarantees only that bytes previously written to the stream are passed to the operating system for writing; it does not guarantee that they are actually written to a physical device such as a disk drive.
| |
| write | back to summary |
|---|---|
| public void write(int b) throws IOException Implements abstract java. Doc from java. Writes the specified byte to this output stream. The general
contract for
| |
| write | back to summary |
|---|---|
| public void write(byte[] b) throws IOException Overrides java. Doc from java. Writes
| |
| write | back to summary |
|---|---|
| public void write(byte[] b, int off, int len) throws IOException Overrides java. Doc from java. Writes
If
If
| |
| writeBytes | back to summary |
|---|---|
| private void writeBytes(byte[] b) throws IOException Write the
| |