org.apache.openejb.server.httpd
Interface HttpRequest

All Superinterfaces:
javax.servlet.http.HttpServletRequest, Serializable, javax.servlet.ServletRequest
All Known Implementing Classes:
HttpRequestImpl, ServletRequestAdapter

public interface HttpRequest
extends Serializable, javax.servlet.http.HttpServletRequest

An interface to take care of HTTP Requests. It parses headers, content, form and url parameters.


Nested Class Summary
static class HttpRequest.Method
          Request methods
 
Field Summary
static String HEADER_ACCEPT
          the Accept header
static String HEADER_ACCEPT_ENCODING
          the Accept-Encoding header
static String HEADER_ACCEPT_LANGUAGE
          the Accept-Language header
static String HEADER_CACHE_CONTROL
          the Cache-Control header
static String HEADER_CONNECTION
          the Connection header
static String HEADER_CONTENT_LENGTH
          the Content-Length header
static String HEADER_CONTENT_TYPE
          the Content-Type header
static String HEADER_COOKIE
          the Cookie header
static String HEADER_HOST
          the Host header
static String HEADER_SET_COOKIE
          the Set-Cookie header
static String HEADER_USER_AGENT
          the User-Agent header
static String SERVLET_CONTEXT
          If the https server implementation is based on Servlets, the real ServletContext will be registered in the request attributes using this name.
static String SERVLET_REQUEST
          If the https server implementation is based on Servlets, the real HttpServletRequest will be registered in the request attributes using this name.
static String SERVLET_RESPONSE
          If the https server implementation is based on Servlets, the real HttpServletResponse will be registered in the request attributes using this name.
 
Fields inherited from interface javax.servlet.http.HttpServletRequest
BASIC_AUTH, CLIENT_CERT_AUTH, DIGEST_AUTH, FORM_AUTH
 
Method Summary
 Object getAttribute(String name)
           
 int getContentLength()
           
 String getContentType()
           
 String getParameter(String name)
          Gets a form or URL query parameter based on the name passed in.
 Map getParameters()
          Gets all the form and URL query parameters
 String getRemoteAddr()
           
 URI getURI()
          Gets the URI for the current URL page.
 void setAttribute(String name, Object value)
           
 
Methods inherited from interface javax.servlet.http.HttpServletRequest
authenticate, getAuthType, getContextPath, getCookies, getDateHeader, getHeader, getHeaderNames, getHeaders, getIntHeader, getMethod, getPart, getParts, getPathInfo, getPathTranslated, getQueryString, getRemoteUser, getRequestedSessionId, getRequestURI, getRequestURL, getServletPath, getSession, getSession, getUserPrincipal, isRequestedSessionIdFromCookie, isRequestedSessionIdFromUrl, isRequestedSessionIdFromURL, isRequestedSessionIdValid, isUserInRole, login, logout
 
Methods inherited from interface javax.servlet.ServletRequest
getAsyncContext, getAttributeNames, getCharacterEncoding, getDispatcherType, getInputStream, getLocalAddr, getLocale, getLocales, getLocalName, getLocalPort, getParameterMap, getParameterNames, getParameterValues, getProtocol, getReader, getRealPath, getRemoteHost, getRemotePort, getRequestDispatcher, getScheme, getServerName, getServerPort, getServletContext, isAsyncStarted, isAsyncSupported, isSecure, removeAttribute, setCharacterEncoding, startAsync, startAsync
 

Field Detail

HEADER_ACCEPT

static final String HEADER_ACCEPT
the Accept header

See Also:
Constant Field Values

HEADER_ACCEPT_ENCODING

static final String HEADER_ACCEPT_ENCODING
the Accept-Encoding header

See Also:
Constant Field Values

HEADER_ACCEPT_LANGUAGE

static final String HEADER_ACCEPT_LANGUAGE
the Accept-Language header

See Also:
Constant Field Values

HEADER_CONTENT_TYPE

static final String HEADER_CONTENT_TYPE
the Content-Type header

See Also:
Constant Field Values

HEADER_CONTENT_LENGTH

static final String HEADER_CONTENT_LENGTH
the Content-Length header

See Also:
Constant Field Values

HEADER_CONNECTION

static final String HEADER_CONNECTION
the Connection header

See Also:
Constant Field Values

HEADER_CACHE_CONTROL

static final String HEADER_CACHE_CONTROL
the Cache-Control header

See Also:
Constant Field Values

HEADER_HOST

static final String HEADER_HOST
the Host header

See Also:
Constant Field Values

HEADER_USER_AGENT

static final String HEADER_USER_AGENT
the User-Agent header

See Also:
Constant Field Values

HEADER_SET_COOKIE

static final String HEADER_SET_COOKIE
the Set-Cookie header

See Also:
Constant Field Values

HEADER_COOKIE

static final String HEADER_COOKIE
the Cookie header

See Also:
Constant Field Values

SERVLET_REQUEST

static final String SERVLET_REQUEST
If the https server implementation is based on Servlets, the real HttpServletRequest will be registered in the request attributes using this name.


SERVLET_RESPONSE

static final String SERVLET_RESPONSE
If the https server implementation is based on Servlets, the real HttpServletResponse will be registered in the request attributes using this name.


SERVLET_CONTEXT

static final String SERVLET_CONTEXT
If the https server implementation is based on Servlets, the real ServletContext will be registered in the request attributes using this name. Note: a ServletContext may not be registered even if HttpServletRequest and HttpServletResponse objects are registered.

Method Detail

getParameter

String getParameter(String name)
Gets a form or URL query parameter based on the name passed in.

Specified by:
getParameter in interface javax.servlet.ServletRequest
Parameters:
name -

getParameters

Map getParameters()
Gets all the form and URL query parameters

Returns:
All the form and URL query parameters

getURI

URI getURI()
Gets the URI for the current URL page.

Returns:
The URI

getContentLength

int getContentLength()
Specified by:
getContentLength in interface javax.servlet.ServletRequest

getContentType

String getContentType()
Specified by:
getContentType in interface javax.servlet.ServletRequest

getAttribute

Object getAttribute(String name)
Specified by:
getAttribute in interface javax.servlet.ServletRequest

setAttribute

void setAttribute(String name,
                  Object value)
Specified by:
setAttribute in interface javax.servlet.ServletRequest

getRemoteAddr

String getRemoteAddr()
Specified by:
getRemoteAddr in interface javax.servlet.ServletRequest


Copyright © 1999–2015 The Apache Software Foundation. All rights reserved.