|
Copyright © 2006 BEA Systems, Inc. All Rights Reserved | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.bea.p13n.http.HttpConfigurableEntity
com.bea.p13n.http.Request
public class Request
The Personalization Server implementation of the Http Servlet Request interface.
This object is used by the Personalization Server to get properties on an Http Request in a format understandable to Personalization Core Services such as the RulesService.
This will use a DefaultRequestFilter
to
filter out attributes. After loading the request attributes, this will
additionally call out to any AttributeLoaders
specified by the AttributeLoaderBean's RequestLoaders attribute.
Nested Class Summary | |
---|---|
static interface |
Request.AttributeLoader
An object which is capable of loading additional attributes into a Request. |
Field Summary | |
---|---|
static boolean |
ATTRIBUTE_OVERRIDE
Controls whether the getProperty and getPropertyNoDefault methods
check the HttpRequest attributes prior to the HttpRequest parameters. |
static String |
AUTHORIZATION_SCHEME
|
static String |
CHAR_ENCODING
|
static String |
CONTENT_LENGTH
|
static String |
CONTENT_TYPE
|
static String |
CONTEXT_PATH
|
static String |
LOCAL_ADDR
|
static String |
LOCAL_NAME
|
static String |
LOCAL_PORT
|
static String |
LOCALE
|
static String |
PATH_INFO
|
static String |
PATH_TRANSLATED
|
static String |
QUERY_STRING
|
static String |
REMOTE_ADDRESS
|
static String |
REMOTE_HOST
|
static String |
REMOTE_PORT
|
static String |
REMOTE_USER
|
static String |
REQUEST_METHOD
|
static String |
REQUEST_PROPERTY_SET_TYPE
request property set type |
static String |
REQUEST_PROTOCOL
|
static String |
REQUEST_URI
|
static String |
REQUEST_URL
|
static String |
SCHEME
|
static String |
SERVER_NAME
|
static String |
SERVER_PORT
|
static String |
SERVLET_PATH
|
static String |
USER_PRINCIPAL
|
Fields inherited from interface com.bea.p13n.property.ConfigurableEntity |
---|
RESERVED_PROPERTY_SET |
Constructor Summary | |
---|---|
Request()
Default Constructor |
|
Request(HttpServletRequest request)
Creates a P13N HTTP Request. |
|
Request(HttpServletRequest request,
boolean createSession)
Creates a P13N HTTP Request and, possibly, Session. |
Methods inherited from class com.bea.p13n.http.HttpConfigurableEntity |
---|
getJndiName, getPkString, getProperty, getPropertyAsString, getPropertyDefault, getPropertySetManager, getUniqueId, removeProperty, setProperty |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String REQUEST_PROPERTY_SET_TYPE
public static boolean ATTRIBUTE_OVERRIDE
getProperty
and getPropertyNoDefault
methods
check the HttpRequest attributes prior to the HttpRequest parameters. By default,
the parameters are checked first. To override the default set the system property
com.bea.p13n.http.Request.AttributeOverride=Yes
public static final String REQUEST_METHOD
public static final String REQUEST_URI
public static final String REQUEST_URL
public static final String REQUEST_PROTOCOL
public static final String SERVLET_PATH
public static final String PATH_INFO
public static final String PATH_TRANSLATED
public static final String CONTEXT_PATH
public static final String QUERY_STRING
public static final String CONTENT_LENGTH
public static final String CONTENT_TYPE
public static final String SERVER_NAME
public static final String SERVER_PORT
public static final String REMOTE_USER
public static final String REMOTE_ADDRESS
public static final String REMOTE_HOST
public static final String REMOTE_PORT
public static final String LOCAL_NAME
public static final String LOCAL_ADDR
public static final String LOCAL_PORT
public static final String SCHEME
public static final String AUTHORIZATION_SCHEME
public static final String LOCALE
public static final String CHAR_ENCODING
public static final String USER_PRINCIPAL
Constructor Detail |
---|
public Request()
public Request(HttpServletRequest request)
request
- the HttpServletRequest
used to set and
retrieve properties.public Request(HttpServletRequest request, boolean createSession)
request
- the HttpServletRequest
used to set and
retrieve properties.createSession
- true to also create a Session
from
the request's session and set it on this.setP13NSession(com.bea.p13n.http.Session)
,
Session
Method Detail |
---|
public static Request createP13NRequest(HttpServletRequest request) throws IllegalArgumentException
request
- the request used to create the Session object.
HttpServletRequest
IllegalArgumentException
- If the paramater is null.public void setP13NSession(Session session)
public Session getP13NSession()
public void setPrincipal(HttpServletRequest request)
public Object getPropertyNoDefault(String propertySet, String propertyName)
getPropertyNoDefault
in interface ConfigurableEntity
getPropertyNoDefault
in class HttpConfigurableEntity
propertySet
- The name of the property set for which the property is
sought. This only used if no property is found in the request
and we use the scope to look up the default value in the property set for the
request. This parameter can be null.propertyName
- The property name
public Object getProperty(String propertySet, String propertyName)
getProperty
in interface ConfigurableEntity
getProperty
in class HttpConfigurableEntity
propertySet
- The name of the property set for which the property is
sought. This only used if no property is found in the request
and we use the scope to look up the default value in the property set for the
request. This parameter can be null.propertyName
- The property name
getPropertyNoDefault(java.lang.String, java.lang.String)
public String getMethod(String name)
public Object getAttribute(String name)
public Enumeration getAttributeNames()
public String getCharacterEncoding()
public int getContentLength()
public String getContentType()
public ServletInputStream getInputStream()
public String getParameter(String name)
public Enumeration getParameterNames()
public String[] getParameterValues(String name)
public String getProtocol()
public String getScheme()
public String getServerName()
public int getServerPort()
public BufferedReader getReader()
public String getRemoteAddr()
public String getRemoteHost()
public int getRemotePort()
public String getLocalName()
public String getLocalAddr()
public int getLocalPort()
public void setAttribute(String name, Object o)
public void removeAttribute(String name)
public Locale getLocale()
public Enumeration getLocales()
public boolean isSecure()
public RequestDispatcher getRequestDispatcher(String uri)
public String getRealPath(String path)
public String getAuthType()
public Cookie[] getCookies()
public long getDateHeader(String name)
public String getHeader(String name)
public Enumeration getHeaders(String name)
public Enumeration getHeaderNames()
public int getIntHeader(String name)
public String getMethod()
public String getPathInfo()
public String getPathTranslated()
public String getContextPath()
public String getQueryString()
public String getRemoteUser()
public boolean isUserInRole(String role)
public Principal getUserPrincipal()
public String getRequestedSessionId()
public String getRequestURI()
public String getServletPath()
public HttpSession getSession(boolean create)
public HttpSession getSession()
public boolean isRequestedSessionIdValid()
public boolean isRequestedSessionIdFromCookie()
public boolean isRequestedSessionIdFromURL()
public boolean isRequestedSessionIdFromUrl()
public Map getParameterMap()
public void setCharacterEncoding(String anEncoding)
public StringBuffer getRequestURL()
|
Copyright © 2006 BEA Systems, Inc. All Rights Reserved | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |