|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.entityfs.util.io.OutputStreamToDataSinkAdapter
public class OutputStreamToDataSinkAdapter
This object is used to adapt an OutputStream to the DataSink
interface.
InputStreamToDataSourceAdapter,
DataSinkToOutputStreamAdapter| Constructor Summary | |
|---|---|
OutputStreamToDataSinkAdapter(OutputStream out)
|
|
| Method Summary | |
|---|---|
void |
close()
Close the sink and free all resources associated with it. |
protected void |
finalize()
|
void |
flush()
Flush changes made to the sink to the underlying storage. |
void |
write(byte[] barr)
Write the contents of the array to the sink, starting at the current file pointer. |
void |
write(byte[] barr,
int off,
int len)
Write len bytes from the array, starting at the offset off to this sink. |
void |
write(int b)
Write a byte to the sink. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public OutputStreamToDataSinkAdapter(OutputStream out)
| Method Detail |
|---|
public void flush()
throws ReadOnlyException,
IllegalStateException,
WrappedIOException
DataSinkReadOnlyException.
flush in interface DataSinkReadOnlyException - If the sink is opened read only.
IllegalStateException - If the sink is closed.
WrappedIOException - On I/O errors.
public void write(byte[] barr)
throws ReadOnlyException,
IllegalStateException,
WrappedIOException
DataSink
write in interface DataSinkbarr - The array to write.
ReadOnlyException - If the sink is opened read only.
IllegalStateException - If the sink is closed.
WrappedIOException - On I/O errors.
public void write(byte[] barr,
int off,
int len)
throws ReadOnlyException,
IllegalStateException,
WrappedIOException
DataSinklen bytes from the array, starting at the offset off to this sink.
write in interface DataSinkbarr - The byte array.off - The starting offset in the array.len - The number of bytes to write.
ReadOnlyException - If the sink is opened read only.
IllegalStateException - If the sink file is closed.
WrappedIOException - On I/O errors.
public void write(int b)
throws ReadOnlyException,
IllegalStateException,
WrappedIOException
DataSink
write in interface DataSinkb - The byte to write.
ReadOnlyException - If the sink is opened read only.
IllegalStateException - If the random access file is closed.
WrappedIOException - On I/O errors.
public void close()
throws WrappedIOException
DataSink
close in interface DataSinkWrappedIOException - On I/O errors.
protected void finalize()
throws Throwable
finalize in class ObjectThrowable
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||