Class AsyncResponse<T extends XrootdRequest>

  • All Implemented Interfaces:
    io.netty.util.ReferenceCounted, XrootdResponse<T>

    public class AsyncResponse<T extends XrootdRequest>
    extends io.netty.util.AbstractReferenceCounted
    implements XrootdResponse<T>
    • 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.
      T getRequest()
      Returns the request this is a response to.
      XrootdResponse<T> getResponse()  
      int getStatus()
      The xrootd response status code.
      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, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • 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<T extends XrootdRequest>
      • 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<T extends XrootdRequest>
      • 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