Class ReadableChannelOverSliceAccessor<A>

All Implemented Interfaces:
Closeable, AutoCloseable, Channel, HasArrayOps<A>, ReadableChannel<A>

public class ReadableChannelOverSliceAccessor<A> extends ReadableChannelBase<A>
  • Constructor Details

    • ReadableChannelOverSliceAccessor

      public ReadableChannelOverSliceAccessor(SliceAccessor<A> accessor, long posInSlice)
  • Method Details

    • getArrayOps

      public ArrayOps<A> getArrayOps()
    • closeActual

      public void closeActual() throws IOException
      Throws:
      IOException
    • read

      public int read(A array, int position, int length) throws IOException
      Description copied from interface: ReadableChannel
      Read method following the usual InputStream protocol.
      Parameters:
      array - The array into which to put the read data
      position - Offset into array where to start writing
      length - Maximum number of items to read.
      Returns:
      The number of items read. Return -1 if end of data was reached, and 0 iff length was 0.
      Throws:
      IOException