public interface AsyncOutputStream
See the com.mongodb.async.client.gridfs.helpers
package for adapters that create an AsyncOutputStream
Modifier and Type | Method and Description |
---|---|
void |
close(SingleResultCallback<java.lang.Void> callback)
Closes the output stream
|
void |
write(java.nio.ByteBuffer src,
SingleResultCallback<java.lang.Integer> callback)
Writes a sequence of bytes from the given buffer into this stream.
|
void write(java.nio.ByteBuffer src, SingleResultCallback<java.lang.Integer> callback)
src
- the source buffer containing the data to be written.callback
- the callback returning the number of bytes written.void close(SingleResultCallback<java.lang.Void> callback)
callback
- the callback that indicates when the stream has been closed