org.apache.tomcat.core
Interface Request

All Known Implementing Classes:
RequestImpl

public interface Request


Method Summary
 java.lang.Object getAttribute(java.lang.String name)
           
 java.util.Enumeration getAttributeNames()
           
 java.lang.String getAuthType()
           
 java.lang.String getCharacterEncoding()
           
 Container getContainer()
           
 int getContentLength()
           
 java.lang.String getContentType()
           
 Context getContext()
           
 ContextManager getContextManager()
           
 javax.servlet.http.Cookie[] getCookies()
          Return the cookies
 HttpServletRequestFacade getFacade()
          One-to-One with Facade
 java.lang.String getHeader(java.lang.String name)
           
 java.util.Enumeration getHeaderNames()
           
 java.util.Enumeration getHeaders(java.lang.String name)
           
 javax.servlet.ServletInputStream getInputStream()
           
 java.lang.String getJvmRoute()
           
 java.lang.String getLookupPath()
           
 java.lang.String getMappedPath()
          Deprecated. - internal use only
 java.lang.String getMethod()
           
 java.util.Enumeration getParameterNames()
           
 java.util.Hashtable getParameters()
          Deprecated. internal use only
 java.lang.String[] getParameterValues(java.lang.String name)
           
 java.lang.String getPathInfo()
          Path Info - set be mappers or from adapter
 java.lang.String getPathTranslated()
          Real Path - should be implemented as a callback ( override it in adapters).
 java.lang.String getProtocol()
           
 java.lang.String getQueryString()
           
 java.io.BufferedReader getReader()
           
 java.lang.String getRemoteAddr()
           
 java.lang.String getRemoteHost()
          Expensive - should be implemented as a callback where possible!
 java.lang.String getRemoteUser()
           
 java.lang.String getRequestedSessionId()
           
 java.lang.String getRequestURI()
           
 Response getResponse()
          One-to-One with Response
 java.lang.String getScheme()
           
 java.lang.String getServerName()
           
 int getServerPort()
           
 java.lang.String getServletPath()
           
 javax.servlet.http.HttpSession getSession(boolean create)
           
 java.security.Principal getUserPrincipal()
          Deprecated.  
 ServletWrapper getWrapper()
          Deprecated. - use Container instead
 boolean isRequestedSessionIdFromCookie()
           
 boolean isRequestedSessionIdFromURL()
           
 boolean isRequestedSessionIdValid()
           
 boolean isSecure()
           
 boolean isUserInRole(java.lang.String role)
          Deprecated.  
 void recycle()
          Support for "pools"
 void removeAttribute(java.lang.String name)
           
 void setAttribute(java.lang.String name, java.lang.Object value)
           
 void setAuthType(java.lang.String authType)
           
 void setCharEncoding(java.lang.String enc)
           
 void setContainer(Container handler)
           
 void setContentLength(int len)
           
 void setContentType(java.lang.String type)
           
 void setContext(Context context)
          Context - will be set by contextMap stage of request interceptors
 void setContextManager(ContextManager cm)
          Pointer to the server engine - for errors, etc
 void setLookupPath(java.lang.String l)
          Everything after context path ( servletPath + pathInfo + queryInfo )
 void setMappedPath(java.lang.String m)
          Deprecated. - internal use only
 void setParameters(java.util.Hashtable h)
          Deprecated. internal use only
 void setPathInfo(java.lang.String pathInfo)
           
 void setPathTranslated(java.lang.String path)
           
 void setQueryString(java.lang.String queryString)
          Set query string - will be called by forward
 void setRemoteUser(java.lang.String s)
           
 void setRequestedSessionId(java.lang.String reqSessionId)
           
 void setRequestedSessionIdFromCookie(boolean newState)
           
 void setRequestedSessionIdFromURL(boolean newState)
           
 void setRequestURI(java.lang.String r)
           
 void setResponse(Response response)
           
 void setServerName(java.lang.String serverName)
           
 void setServletPath(java.lang.String servletPath)
          Servlet Path
 void setSession(javax.servlet.http.HttpSession serverSession)
           
 void setWrapper(ServletWrapper handler)
          Deprecated. - use Container instead
 

Method Detail

getJvmRoute

public java.lang.String getJvmRoute()

getScheme

public java.lang.String getScheme()

getMethod

public java.lang.String getMethod()

getRequestURI

public java.lang.String getRequestURI()

setRequestURI

public void setRequestURI(java.lang.String r)

getQueryString

public java.lang.String getQueryString()

getProtocol

public java.lang.String getProtocol()

getServerName

public java.lang.String getServerName()

setServerName

public void setServerName(java.lang.String serverName)

getServerPort

public int getServerPort()

getRemoteAddr

public java.lang.String getRemoteAddr()

getRemoteHost

public java.lang.String getRemoteHost()
Expensive - should be implemented as a callback where possible!

getHeader

public java.lang.String getHeader(java.lang.String name)

getHeaderNames

public java.util.Enumeration getHeaderNames()

getHeaders

public java.util.Enumeration getHeaders(java.lang.String name)

getCookies

public javax.servlet.http.Cookie[] getCookies()
Return the cookies

getContentLength

public int getContentLength()

setContentLength

public void setContentLength(int len)

getContentType

public java.lang.String getContentType()

setContentType

public void setContentType(java.lang.String type)

setCharEncoding

public void setCharEncoding(java.lang.String enc)

getCharacterEncoding

public java.lang.String getCharacterEncoding()

setContext

public void setContext(Context context)
Context - will be set by contextMap stage of request interceptors

getContext

public Context getContext()

setLookupPath

public void setLookupPath(java.lang.String l)
Everything after context path ( servletPath + pathInfo + queryInfo )

getLookupPath

public java.lang.String getLookupPath()

getPathTranslated

public java.lang.String getPathTranslated()
Real Path - should be implemented as a callback ( override it in adapters). Map interceptor should set it to something reasonable ( context home + path ) MappedPath is similar - it contain mappings inside a context, for normal contexts pathTranslated==context.docBase + mappedPath

setPathTranslated

public void setPathTranslated(java.lang.String path)

getPathInfo

public java.lang.String getPathInfo()
Path Info - set be mappers or from adapter

setPathInfo

public void setPathInfo(java.lang.String pathInfo)

setServletPath

public void setServletPath(java.lang.String servletPath)
Servlet Path

getServletPath

public java.lang.String getServletPath()

getContainer

public Container getContainer()

setContainer

public void setContainer(Container handler)

getAuthType

public java.lang.String getAuthType()

setAuthType

public void setAuthType(java.lang.String authType)

getRemoteUser

public java.lang.String getRemoteUser()

setRemoteUser

public void setRemoteUser(java.lang.String s)

isSecure

public boolean isSecure()

getRequestedSessionId

public java.lang.String getRequestedSessionId()

setRequestedSessionId

public void setRequestedSessionId(java.lang.String reqSessionId)

isRequestedSessionIdFromCookie

public boolean isRequestedSessionIdFromCookie()

setRequestedSessionIdFromCookie

public void setRequestedSessionIdFromCookie(boolean newState)

isRequestedSessionIdFromURL

public boolean isRequestedSessionIdFromURL()

setRequestedSessionIdFromURL

public void setRequestedSessionIdFromURL(boolean newState)

setSession

public void setSession(javax.servlet.http.HttpSession serverSession)

getSession

public javax.servlet.http.HttpSession getSession(boolean create)

isRequestedSessionIdValid

public boolean isRequestedSessionIdValid()

setQueryString

public void setQueryString(java.lang.String queryString)
Set query string - will be called by forward

getParameterValues

public java.lang.String[] getParameterValues(java.lang.String name)

getParameterNames

public java.util.Enumeration getParameterNames()

getAttribute

public java.lang.Object getAttribute(java.lang.String name)

setAttribute

public void setAttribute(java.lang.String name,
                         java.lang.Object value)

removeAttribute

public void removeAttribute(java.lang.String name)

getAttributeNames

public java.util.Enumeration getAttributeNames()

getReader

public java.io.BufferedReader getReader()
                                 throws java.io.IOException

getInputStream

public javax.servlet.ServletInputStream getInputStream()
                                                throws java.io.IOException

recycle

public void recycle()
Support for "pools"

getResponse

public Response getResponse()
One-to-One with Response

setResponse

public void setResponse(Response response)

getFacade

public HttpServletRequestFacade getFacade()
One-to-One with Facade

setContextManager

public void setContextManager(ContextManager cm)
Pointer to the server engine - for errors, etc

getContextManager

public ContextManager getContextManager()

setParameters

public void setParameters(java.util.Hashtable h)
Deprecated. internal use only


getParameters

public java.util.Hashtable getParameters()
Deprecated. internal use only


getUserPrincipal

public java.security.Principal getUserPrincipal()
Deprecated.  


isUserInRole

public boolean isUserInRole(java.lang.String role)
Deprecated.  


getWrapper

public ServletWrapper getWrapper()
Deprecated. - use Container instead

Wrapper - the servlet that will execute the request Similar with "handler" in Apache.

setWrapper

public void setWrapper(ServletWrapper handler)
Deprecated. - use Container instead


getMappedPath

public java.lang.String getMappedPath()
Deprecated. - internal use only

The file - result of mapping the request ( using aliases and other mapping rules. Usefull only for static resources.

setMappedPath

public void setMappedPath(java.lang.String m)
Deprecated. - internal use only



Copyright © 2000 Apache Software Foundation. All Rights Reserved.