Class ResponseImpl

    • Constructor Detail

      • ResponseImpl

        ResponseImpl​(ChannelOwner parent,
                     java.lang.String type,
                     java.lang.String guid,
                     com.google.gson.JsonObject initializer)
    • Method Detail

      • allHeaders

        public java.util.Map<java.lang.String,​java.lang.String> allHeaders()
        Description copied from interface: Response
        An object with all the response HTTP headers associated with this response.
        Specified by:
        allHeaders in interface Response
      • body

        public byte[] body()
        Description copied from interface: Response
        Returns the buffer with response body.
        Specified by:
        body in interface Response
      • finished

        public java.lang.String finished()
        Description copied from interface: Response
        Waits for this response to finish, returns always null.
        Specified by:
        finished in interface Response
      • frame

        public Frame frame()
        Description copied from interface: Response
        Returns the Frame that initiated this response.
        Specified by:
        frame in interface Response
      • headers

        public java.util.Map<java.lang.String,​java.lang.String> headers()
        Description copied from interface: Response
        An object with the response HTTP headers. The header names are lower-cased. Note that this method does not return security-related headers, including cookie-related ones. You can use Response.allHeaders() for complete list of headers that include cookie information.
        Specified by:
        headers in interface Response
      • headersArray

        public java.util.List<HttpHeader> headersArray()
        Description copied from interface: Response
        An array with all the request HTTP headers associated with this response. Unlike Response.allHeaders(), header names are NOT lower-cased. Headers with multiple entries, such as Set-Cookie, appear in the array multiple times.
        Specified by:
        headersArray in interface Response
      • headerValue

        public java.lang.String headerValue​(java.lang.String name)
        Description copied from interface: Response
        Returns the value of the header matching the name. The name is case insensitive. If multiple headers have the same name (except set-cookie), they are returned as a list separated by , . For set-cookie, the \n separator is used. If no headers are found, null is returned.
        Specified by:
        headerValue in interface Response
        Parameters:
        name - Name of the header.
      • headerValues

        public java.util.List<java.lang.String> headerValues​(java.lang.String name)
        Description copied from interface: Response
        Returns all values of the headers matching the name, for example set-cookie. The name is case insensitive.
        Specified by:
        headerValues in interface Response
        Parameters:
        name - Name of the header.
      • ok

        public boolean ok()
        Description copied from interface: Response
        Contains a boolean stating whether the response was successful (status in the range 200-299) or not.
        Specified by:
        ok in interface Response
      • serverAddr

        public ServerAddr serverAddr()
        Description copied from interface: Response
        Returns the IP address and port of the server.
        Specified by:
        serverAddr in interface Response
      • status

        public int status()
        Description copied from interface: Response
        Contains the status code of the response (e.g., 200 for a success).
        Specified by:
        status in interface Response
      • statusText

        public java.lang.String statusText()
        Description copied from interface: Response
        Contains the status text of the response (e.g. usually an "OK" for a success).
        Specified by:
        statusText in interface Response
      • text

        public java.lang.String text()
        Description copied from interface: Response
        Returns the text representation of response body.
        Specified by:
        text in interface Response
      • url

        public java.lang.String url()
        Description copied from interface: Response
        Contains the URL of the response.
        Specified by:
        url in interface Response
      • getRawHeaders

        private RawHeaders getRawHeaders()