Class HttpMessageContext

    • Constructor Detail

      • HttpMessageContext

        public HttpMessageContext​(String clientID,
                                  javax.servlet.http.HttpServletRequest request)
        Constructs a message context, that interfaces a Client, identified by its id, with the corresponding HttpServletRequest.
        Parameters:
        clientID - the id of the client
        request - the request of the client
    • Method Detail

      • getRequest

        public javax.servlet.http.HttpServletRequest getRequest()
        Gets the HttpServletRequest of the HTTP message.
        Returns:
        the HttpServletRequest of the HTTP message.
      • getRequestURI

        public String getRequestURI()
        Description copied from interface: MessageContext
        Returns the URI requested by the message for this context from the protocol up to the query string.

        Example:

        • https://somepage.com/somesite?key=value
        • RequestURI: somepage.com/somesite
        Specified by:
        getRequestURI in interface MessageContext
        Returns:
        the requested URI
      • getQueryString

        public String getQueryString()
        Description copied from interface: MessageContext
        Returns the query string contained in the message for this context.

        Example:

        • https://somepage.com/somesite?key=value
        • QueryString: key=value
        Specified by:
        getQueryString in interface MessageContext
        Returns:
        the query string
      • getClientID

        public String getClientID()
        Description copied from interface: MessageContext
        Returns the client id of the client which did send the message associated with this message context.
        Specified by:
        getClientID in interface MessageContext
        Returns:
        the client id
      • getHTTPSession

        public javax.servlet.http.HttpSession getHTTPSession()
        Description copied from interface: MessageContext
        Returns the HttpSession of the message associated with this message context.
        Specified by:
        getHTTPSession in interface MessageContext
        Returns:
        the HttpSession