Class HttpResponse


  • public class HttpResponse
    extends Response
    Response wrapper for server HTTP calls.
    • Field Detail

      • httpCall

        private volatile ServerCall httpCall
        The low-level HTTP call.
      • serverAdded

        private volatile boolean serverAdded
        Indicates if the server data was parsed and added.
    • Constructor Detail

      • HttpResponse

        public HttpResponse​(ServerCall httpCall,
                            Request request)
        Constructor.
        Parameters:
        httpCall - The low-level HTTP server call.
        request - The associated high-level request.
    • Method Detail

      • addHeader

        public static void addHeader​(Response response,
                                     java.lang.String headerName,
                                     java.lang.String headerValue)
        Adds a new header to the given request.
        Parameters:
        response - The response to update.
        headerName - The header name to add.
        headerValue - The header value to add.
      • getHttpCall

        public ServerCall getHttpCall()
        Returns the low-level HTTP call.
        Returns:
        The low-level HTTP call.
      • getServerInfo

        public ServerInfo getServerInfo()
        Returns the server-specific information.
        Overrides:
        getServerInfo in class Response
        Returns:
        The server-specific information.