Class InboundReadResponse

  • All Implemented Interfaces:
    io.netty.util.ReferenceCounted, XrootdInboundResponse, ByteBuffersProvider

    public class InboundReadResponse
    extends AbstractXrootdInboundResponse
    implements ByteBuffersProvider
    Response from third-party source server.

    The implementation of the ByteBuffersProvider interface assimilates this response with an incoming client write request.

    The third-party client in effect acts as a pipe between the remote read of the file and the local write. Merging that functionality into a single object allows us to bypass an extra buffer copy.

    • Constructor Detail

      • InboundReadResponse

        public InboundReadResponse​(io.netty.buffer.ByteBuf buffer)
    • Method Detail

      • getDlen

        public int getDlen()
      • getWriteOffset

        public long getWriteOffset()
        Specified by:
        getWriteOffset in interface ByteBuffersProvider
        Returns:
        the current offset to the buffer or channel receiving the written bytes.
      • setWriteOffset

        public void setWriteOffset​(long writeOffset)
      • toByteBuffers

        public java.nio.ByteBuffer[] toByteBuffers()
        Specified by:
        toByteBuffers in interface ByteBuffersProvider
        Returns:
        NIO buffer array produced from the Netty ByteBuf.
      • refCnt

        public int refCnt()
        Specified by:
        refCnt in interface io.netty.util.ReferenceCounted
      • retain

        public io.netty.util.ReferenceCounted retain()
        Specified by:
        retain in interface io.netty.util.ReferenceCounted
      • retain

        public io.netty.util.ReferenceCounted retain​(int i)
        Specified by:
        retain in interface io.netty.util.ReferenceCounted
      • touch

        public io.netty.util.ReferenceCounted touch()
        Specified by:
        touch in interface io.netty.util.ReferenceCounted
      • touch

        public io.netty.util.ReferenceCounted touch​(java.lang.Object o)
        Specified by:
        touch in interface io.netty.util.ReferenceCounted
      • release

        public boolean release()
        Specified by:
        release in interface io.netty.util.ReferenceCounted
      • release

        public boolean release​(int i)
        Specified by:
        release in interface io.netty.util.ReferenceCounted