org.apache.catalina.connector

Class RequestFacade

Implemented Interfaces:
ServletRequest
Known Direct Subclasses:
CoyoteRequestFacade, CoyoteRequestFacade, HttpRequestFacade

public class RequestFacade
extends java.lang.Object
implements ServletRequest

Facade class that wraps a Catalina-internal Request object. All methods are delegated to the wrapped request.

Version:
$Revision: 1.4 $ $Date: 2004/02/27 14:58:41 $

Authors:
Craig R. McClanahan
Remy Maucherat
Jean-Francois Arcand

Field Summary

protected ServletRequest
request
The wrapped request.

Constructor Summary

RequestFacade(Request request)
Construct a wrapper for the specified request.

Method Summary

void
clear()
Clear facade.
Object
getAttribute(String name)
Enumeration
getAttributeNames()
String
getCharacterEncoding()
int
getContentLength()
String
getContentType()
ServletInputStream
getInputStream()
String
getLocalAddr()
Returns the Internet Protocol (IP) address of the interface on which the request was received.
String
getLocalName()
Returns the host name of the Internet Protocol (IP) interface on which the request was received.
int
getLocalPort()
Returns the Internet Protocol (IP) port number of the interface on which the request was received.
Locale
getLocale()
Enumeration
getLocales()
String
getParameter(String name)
Map
getParameterMap()
Enumeration
getParameterNames()
String[]
getParameterValues(String name)
String
getProtocol()
BufferedReader
getReader()
String
getRealPath(String path)
String
getRemoteAddr()
String
getRemoteHost()
int
getRemotePort()
Returns the Internet Protocol (IP) source port of the client or last proxy that sent the request.
RequestDispatcher
getRequestDispatcher(String path)
String
getScheme()
String
getServerName()
int
getServerPort()
boolean
isSecure()
void
removeAttribute(String name)
void
setAttribute(String name, Object o)
void
setCharacterEncoding(String env)

Field Details

request

protected ServletRequest request
The wrapped request.

Constructor Details

RequestFacade

public RequestFacade(Request request)
Construct a wrapper for the specified request.

Parameters:
request - The request to be wrapped

Method Details

clear

public void clear()
Clear facade.


getAttribute

public Object getAttribute(String name)


getAttributeNames

public Enumeration getAttributeNames()


getCharacterEncoding

public String getCharacterEncoding()


getContentLength

public int getContentLength()


getContentType

public String getContentType()


getInputStream

public ServletInputStream getInputStream()
            throws IOException


getLocalAddr

public String getLocalAddr()
Returns the Internet Protocol (IP) address of the interface on which the request was received.


getLocalName

public String getLocalName()
Returns the host name of the Internet Protocol (IP) interface on which the request was received.


getLocalPort

public int getLocalPort()
Returns the Internet Protocol (IP) port number of the interface on which the request was received.


getLocale

public Locale getLocale()


getLocales

public Enumeration getLocales()


getParameter

public String getParameter(String name)


getParameterMap

public Map getParameterMap()


getParameterNames

public Enumeration getParameterNames()


getParameterValues

public String[] getParameterValues(String name)


getProtocol

public String getProtocol()


getReader

public BufferedReader getReader()
            throws IOException


getRealPath

public String getRealPath(String path)


getRemoteAddr

public String getRemoteAddr()


getRemoteHost

public String getRemoteHost()


getRemotePort

public int getRemotePort()
Returns the Internet Protocol (IP) source port of the client or last proxy that sent the request.


getRequestDispatcher

public RequestDispatcher getRequestDispatcher(String path)


getScheme

public String getScheme()


getServerName

public String getServerName()


getServerPort

public int getServerPort()


isSecure

public boolean isSecure()


removeAttribute

public void removeAttribute(String name)


setAttribute

public void setAttribute(String name,
                         Object o)


setCharacterEncoding

public void setCharacterEncoding(String env)
            throws java.io.UnsupportedEncodingException


Copyright B) 2000-2003 Apache Software Foundation. All Rights Reserved.