Class DefaultWebApplicationRequest

    • Field Detail

      • authType

        protected String authType
        Stores the auth type.
      • asyncContext

        protected AsyncContext asyncContext
        Stores the async context.
      • asyncStarted

        protected boolean asyncStarted
        Stores if async is started.
      • asyncSupported

        protected boolean asyncSupported
        Stores if async is supported.
      • attributeManager

        protected AttributeManager attributeManager
        Stores the attribute manager.
      • characterEncoding

        protected String characterEncoding
        Stores the character encoding.
      • contentLength

        protected long contentLength
        Stores the content length.
      • contentType

        protected String contentType
        Stores the content type.
      • contextPath

        protected String contextPath
        Stores the context path.
      • cookies

        protected Cookie[] cookies
        Stores the cookies.
      • currentSessionId

        protected String currentSessionId
        Stores the current session id.
      • dispatcherType

        protected DispatcherType dispatcherType
        Stores the dispatcher type.
      • gotInputStream

        protected boolean gotInputStream
        Stores the gotInputStream flag.
      • gotReader

        protected boolean gotReader
        Stores the gotReader flag.
      • headerManager

        protected HttpHeaderManager headerManager
        Stores the header manager.
      • inputStream

        protected InputStream inputStream
        Stores the input stream.
      • localAddress

        protected String localAddress
        Stores the local address.
      • localName

        protected String localName
        Stores the local name.
      • localPort

        protected int localPort
        Stores the local port.
      • method

        protected String method
        Stores the method.
      • parametersParsed

        protected boolean parametersParsed
        Stores the parameters parsed flag.
      • pathInfo

        protected String pathInfo
        Stores the path info.
      • protocol

        protected String protocol
        Stores the protocol.
      • queryString

        protected String queryString
        Stores the query string.
      • remoteAddr

        protected String remoteAddr
        Stores the remote address.
      • remoteHost

        protected String remoteHost
        Stores the remote host.
      • remotePort

        protected int remotePort
        Stores the remote port.
      • requestedSessionId

        protected String requestedSessionId
        Stores the requested session id.
      • requestedSessionIdFromCookie

        protected boolean requestedSessionIdFromCookie
        Stores the requested session id from cookie flag.
      • requestedSessionIdFromURL

        protected boolean requestedSessionIdFromURL
        Stores the requested session id from url flag.
      • scheme

        protected String scheme
        Stores the scheme.
      • serverName

        protected String serverName
        Stores the server name.
      • serverPort

        protected int serverPort
        Stores the server port.
      • servletPath

        protected String servletPath
        Stores the servlet path.
      • upgraded

        protected boolean upgraded
        Stores the upgraded flag.
      • userPrincipal

        protected Principal userPrincipal
        Stores the user principal.
      • webApplication

        protected WebApplication webApplication
        Stores the web application
    • Constructor Detail

      • DefaultWebApplicationRequest

        public DefaultWebApplicationRequest()
        Constructor.
    • Method Detail

      • getAttribute

        public Object getAttribute​(String name)
        Get the attribute.
        Specified by:
        getAttribute in interface ServletRequest
        Parameters:
        name - the attribute name.
        Returns:
        the value.
      • getContentLength

        public int getContentLength()
        Get the content length.
        Specified by:
        getContentLength in interface ServletRequest
        Returns:
        the content length.
      • getContentLengthLong

        public long getContentLengthLong()
        Get the content length.
        Specified by:
        getContentLengthLong in interface ServletRequest
        Returns:
        the content length.
      • getDateHeader

        public long getDateHeader​(String name)
        Get the date header.
        Specified by:
        getDateHeader in interface HttpServletRequest
        Parameters:
        name - the header name.
        Returns:
        the date header.
      • getIntHeader

        public int getIntHeader​(String name)
        Get the int header.
        Specified by:
        getIntHeader in interface HttpServletRequest
        Parameters:
        name - the name.
        Returns:
        the int header.
      • getLocalPort

        public int getLocalPort()
        Get the local port.
        Specified by:
        getLocalPort in interface ServletRequest
        Returns:
        the local port.
      • getParameterValues

        public String[] getParameterValues​(String name)
        Get the parameter values.
        Specified by:
        getParameterValues in interface ServletRequest
        Parameters:
        name - the parameter name.
        Returns:
        the parameter values.
      • getParametersFromRequest

        protected void getParametersFromRequest()
        Get the parameters from the request.
      • getRealPath

        public String getRealPath​(String path)
        Deprecated.
        Get the real path.
        Specified by:
        getRealPath in interface ServletRequest
        Parameters:
        path - the path.
        Returns:
        the real path.
      • getRemotePort

        public int getRemotePort()
        Get the remote port.
        Specified by:
        getRemotePort in interface ServletRequest
        Returns:
        the remote port.
      • getServerPort

        public int getServerPort()
        Get the server port.
        Specified by:
        getServerPort in interface ServletRequest
        Returns:
        the server port.
      • getSession

        public HttpSession getSession​(boolean create)
        Get the session.
        Specified by:
        getSession in interface HttpServletRequest
        Parameters:
        create - to create it or not.
        Returns:
        the session.
      • getUpgradeHandler

        public HttpUpgradeHandler getUpgradeHandler()
        Get the upgrade handler.
        Returns:
        the upgrade handler.
      • isAsyncStarted

        public boolean isAsyncStarted()
        Is async started.
        Specified by:
        isAsyncStarted in interface ServletRequest
        Returns:
        is async started.
      • isAsyncSupported

        public boolean isAsyncSupported()
        Is async supported.
        Specified by:
        isAsyncSupported in interface ServletRequest
        Returns:
        true if is async is supported.
      • isRequestedSessionIdFromCookie

        public boolean isRequestedSessionIdFromCookie()
        Is the requested session id from cookie.
        Specified by:
        isRequestedSessionIdFromCookie in interface HttpServletRequest
        Returns:
        if the requested session id from cookie.
      • isRequestedSessionIdFromURL

        public boolean isRequestedSessionIdFromURL()
        Is the requested session id from the request url.
        Specified by:
        isRequestedSessionIdFromURL in interface HttpServletRequest
        Returns:
        if the requested session id from the request url.
      • isRequestedSessionIdFromUrl

        public boolean isRequestedSessionIdFromUrl()
        Deprecated.
        Is the requested session id from the request url.
        Specified by:
        isRequestedSessionIdFromUrl in interface HttpServletRequest
        Returns:
        if the requested session id from the request url.
      • isRequestedSessionIdValid

        public boolean isRequestedSessionIdValid()
        Is the requested session id valid?
        Specified by:
        isRequestedSessionIdValid in interface HttpServletRequest
        Returns:
        true if it is, false otherwise.
      • isSecure

        public boolean isSecure()
        Is the request secure.
        Specified by:
        isSecure in interface ServletRequest
        Returns:
        is the request secure.
      • isUpgraded

        public boolean isUpgraded()
        Is the request upgraded.
        Returns:
        false
      • isUserInRole

        public boolean isUserInRole​(String role)
        Is the user in the specified role.
        Specified by:
        isUserInRole in interface HttpServletRequest
        Parameters:
        role - the role.
        Returns:
        if the user in the specified role.
      • removeAttribute

        public void removeAttribute​(String name)
        Remove the attribute.
        Specified by:
        removeAttribute in interface ServletRequest
        Parameters:
        name - the name.
      • setAsyncSupported

        public void setAsyncSupported​(boolean asyncSupported)
        Set the async supported flag.
        Parameters:
        asyncSupported - the async supported flag.
      • setAttribute

        public void setAttribute​(String name,
                                 Object value)
        Set the attribute.
        Specified by:
        setAttribute in interface ServletRequest
        Parameters:
        name - the name.
        value - the value.
      • setAuthType

        public void setAuthType​(String authType)
        Set the auth type.
        Parameters:
        authType - the auth type.
      • setContentLength

        public void setContentLength​(int contentLength)
        Set the content length.
        Parameters:
        contentLength - the content length.
      • setContentType

        public void setContentType​(String contentType)
        Set the content type.
        Parameters:
        contentType - the content type.
      • setContextPath

        public void setContextPath​(String contextPath)
        Set the context path.
        Parameters:
        contextPath - the context path.
      • setCookies

        public void setCookies​(Cookie[] cookies)
        Set the cookies.
        Parameters:
        cookies - the cookies.
      • setHeader

        public void setHeader​(String name,
                              String value)
        Set the header.
        Parameters:
        name - the name.
        value - the value (string).
      • setInputStream

        public void setInputStream​(InputStream inputStream)
        Set the input stream.
        Parameters:
        inputStream - the input stream.
      • setLocalAddr

        public void setLocalAddr​(String localAddress)
        Set the local address.
        Parameters:
        localAddress - the local address.
      • setLocalName

        public void setLocalName​(String localName)
        Set the local name.
        Parameters:
        localName - the local name.
      • setLocalPort

        public void setLocalPort​(int localPort)
        Set the local port.
        Parameters:
        localPort - the local port.
      • setMethod

        public void setMethod​(String method)
        Set the method.
        Parameters:
        method - the method.
      • setParameter

        public void setParameter​(String name,
                                 String[] values)
        Set the parameter values.
        Parameters:
        name - the parameter name.
        values - the values.
      • setPathInfo

        public void setPathInfo​(String pathInfo)
        Set the path info.
        Parameters:
        pathInfo - the path info.
      • setProtocol

        public void setProtocol​(String protocol)
        Set the protocol.
        Parameters:
        protocol - the protocol.
      • setQueryString

        public void setQueryString​(String queryString)
        Set the query string.
        Parameters:
        queryString - the query string.
      • setRemoteAddr

        public void setRemoteAddr​(String remoteAddr)
        Set the remote address.
        Parameters:
        remoteAddr - the remote address.
      • setRemoteHost

        public void setRemoteHost​(String remoteHost)
        Set the remote host.
        Parameters:
        remoteHost - the remote host.
      • setRemotePort

        public void setRemotePort​(int remotePort)
        Set the remote port.
        Parameters:
        remotePort - the remote port.
      • setRequestedSessionId

        public void setRequestedSessionId​(String requestedSessionId)
        Set the requested session id.
        Parameters:
        requestedSessionId - the requested session id.
      • setRequestedSessionIdFromCookie

        public void setRequestedSessionIdFromCookie​(boolean requestedSessionIdFromCookie)
        Set the requested session id from cookie.
        Parameters:
        requestedSessionIdFromCookie - the requested session id from cookie.
      • setRequestedSessionIdFromURL

        public void setRequestedSessionIdFromURL​(boolean requestedSessionIdFromURL)
        Set the request session id from URL flag.
        Parameters:
        requestedSessionIdFromURL - the requested session if from URL flag.
      • setScheme

        public void setScheme​(String scheme)
        Set the scheme.
        Parameters:
        scheme - the scheme.
      • setServerName

        public void setServerName​(String serverName)
        Set the server name.
        Parameters:
        serverName - the server name.
      • setServerPort

        public void setServerPort​(int serverPort)
        Set the server port.
        Parameters:
        serverPort - the server port.
      • setServletPath

        public void setServletPath​(String servletPath)
        Set the servlet path.
        Parameters:
        servletPath - the servlet path.
      • setUpgraded

        public void setUpgraded​(boolean upgraded)
        Set the upgraded flag.
        Parameters:
        upgraded - the upgraded flag.
      • setUserPrincipal

        public void setUserPrincipal​(Principal userPrincipal)
        Set the user principal.
        Parameters:
        userPrincipal - the user principal.
      • setWebApplication

        public void setWebApplication​(WebApplication webApplication)
        Set the web application.
        Parameters:
        webApplication - the web application.
      • verifyMultipartFormData

        protected void verifyMultipartFormData()
                                        throws ServletException
        Verify the method is of type "multipart/form-data"
        Throws:
        ServletException - the exception thrown when it is not.
      • isFinished

        public boolean isFinished()
        Is the Servlet input stream finished?
        Specified by:
        isFinished in class ServletInputStream
        Returns:
        true if it is, false otherwise.
      • isReady

        public boolean isReady()
        Is the Servlet input stream ready?
        Specified by:
        isReady in class ServletInputStream
        Returns:
        true if it is, false otherwise.
      • read

        public int read()
                 throws IOException
        Read from the Servlet input stream.
        Specified by:
        read in class InputStream
        Returns:
        the read value.
        Throws:
        IOException - when an I/O error occurs.