Class ReadVResponse

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void deallocate()  
      int getDataLength()
      Returns the length of the response body.
      int getIndex()
      Returns the starting index into the request read segments that this response addresses.
      int getLength()
      Returns the number of segments contained in this response.
      ReadVRequest getRequest()
      Returns the request this is a response to.
      java.util.List<java.lang.Integer> getSegmentLengths()  
      java.util.List<io.netty.buffer.ByteBuf> getSegments()
      Returns the data segments of the response.
      int getStatus()
      The xrootd response status code.
      java.lang.String toString()  
      io.netty.util.ReferenceCounted touch​(java.lang.Object hint)  
      void writeTo​(io.netty.channel.ChannelHandlerContext ctx, io.netty.channel.ChannelPromise promise)
      Writes the encoded message to the given channel context.
      • Methods inherited from class io.netty.util.AbstractReferenceCounted

        refCnt, release, release, retain, retain, setRefCnt, touch
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

    • Method Detail

      • getSegments

        public java.util.List<io.netty.buffer.ByteBuf> getSegments()
        Returns the data segments of the response. Only the segments contained in this response are returned. The buffers returned are unmodifiable views of the actual data segments. Reference counts are shared and the caller should not release any reference to the returned buffers.
      • getSegmentLengths

        public java.util.List<java.lang.Integer> getSegmentLengths()
      • getIndex

        public int getIndex()
        Returns the starting index into the request read segments that this response addresses.
      • getLength

        public int getLength()
        Returns the number of segments contained in this response.
      • getDataLength

        public int getDataLength()
        Description copied from interface: XrootdResponse
        Returns the length of the response body. This is the value of the dlen field in the Xrootd Server Response Format. This does not include the length of the 8 byte header.
        Specified by:
        getDataLength in interface XrootdResponse<ReadVRequest>
      • writeTo

        public void writeTo​(io.netty.channel.ChannelHandlerContext ctx,
                            io.netty.channel.ChannelPromise promise)
        Description copied from interface: XrootdResponse
        Writes the encoded message to the given channel context. Does not flush the channel. This is a destructive call and must at most be called once. Decreases the reference count by 1 and deallocates this object if the reference count reaches 0.
        Specified by:
        writeTo in interface XrootdResponse<ReadVRequest>
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • touch

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

        protected void deallocate()
        Specified by:
        deallocate in class io.netty.util.AbstractReferenceCounted