public interface GridGgfsHadoopEx extends GridGgfsHadoop
| Modifier and Type | Method and Description |
|---|---|
void |
addEventListener(GridGgfsHadoopStreamDelegate delegate,
GridGgfsHadoopStreamEventListener lsnr)
Adds event listener that will be invoked when connection with server is lost or remote error has occurred.
|
void |
closeStream(GridGgfsHadoopStreamDelegate delegate)
Close server stream.
|
void |
flush(GridGgfsHadoopStreamDelegate delegate)
Flush output stream.
|
org.gridgain.grid.util.lang.GridPlainFuture<byte[]> |
readData(GridGgfsHadoopStreamDelegate delegate,
long pos,
int len,
byte[] outBuf,
int outOff,
int outLen)
Asynchronously reads specified amount of bytes from opened input stream.
|
void |
removeEventListener(GridGgfsHadoopStreamDelegate delegate)
Removes event listener that will be invoked when connection with server is lost or remote error has occurred.
|
void |
writeData(GridGgfsHadoopStreamDelegate delegate,
byte[] data,
int off,
int len)
Writes data to the stream with given streamId.
|
void addEventListener(GridGgfsHadoopStreamDelegate delegate, GridGgfsHadoopStreamEventListener lsnr)
delegate - Stream delegate.lsnr - Event listener.void removeEventListener(GridGgfsHadoopStreamDelegate delegate)
delegate - Stream delegate.org.gridgain.grid.util.lang.GridPlainFuture<byte[]> readData(GridGgfsHadoopStreamDelegate delegate, long pos, int len, @Nullable byte[] outBuf, int outOff, int outLen)
delegate - Stream delegate.pos - Position to read from.len - Data length to read.outBuf - Optional output buffer. If buffer length is less then len, all remaining
bytes will be read into new allocated buffer of length {len - outBuf.length} and this buffer will
be the result of read future.outOff - Output offset.outLen - Output length.void writeData(GridGgfsHadoopStreamDelegate delegate, byte[] data, int off, int len) throws IOException
delegate - Stream delegate.data - Data to write.off - Offset.len - Length.IOException - If failed.void closeStream(GridGgfsHadoopStreamDelegate delegate) throws IOException
delegate - Stream delegate.IOException - If failed.void flush(GridGgfsHadoopStreamDelegate delegate) throws IOException
delegate - Stream delegate.IOException - If failed.Copyright © 2014. All rights reserved.