|
© 2002 BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Information about the current customer's session is stored
in the PipelineSession
. For example the following
information about the current customer is stored in PipelineSession
.
ShoppingCart
PipelineSession allows attributes when added, to be scoped. The allowed scopes are:
SESSION_SCOPE
. The attributes added with this
scope are available till the end of the current HttpSession
.
REQUEST_SCOPE
. The attributes added with this scope
are availabe till the end of the current HttpServletRequest
.
All the attributes added to PipelineSession
, should belong to a specific namespace.
Note:
InvalidArgumentException
.
HttpSession
and
PipelineSession
are reserved for internal purposes.
Method Summary | |
void |
clearRequestScopedAttributes(java.lang.Object namespace,
java.lang.Object requestContext)
Removes all the attributes from the PipelineSession . |
void |
clearSessionScopedAttributes(java.lang.Object namespace)
Removes all the attributes from the PipelineSession . |
boolean |
containsRequestScopedAttribute(java.lang.String key,
java.lang.Object namespace,
java.lang.Object requestContext)
Returns true if the given key is present in the PipelineSession . |
boolean |
containsSessionScopedAttribute(java.lang.String key,
java.lang.Object namespace)
Returns true if the given key is present in the PipelineSession . |
Context |
getContext()
Gets current Webflow execution Context. |
java.lang.Object |
getDefaultNamespace()
Gets the default namespace for this web application. |
java.util.Enumeration |
getNamespaceNames()
Gets the names of all the namespaces that are currently available. |
java.lang.Object |
getRequestScopedAttribute(java.lang.String key,
java.lang.Object namespace,
java.lang.Object requestContext)
Gets the named attribute from the PipelineSession . |
java.util.Hashtable |
getRequestScopedAttributeMap(java.lang.Object namespace,
java.lang.Object requestContext)
Gets the list of all attributes in the REQUEST_SCOPE
and in given namespace as a Hashtable. |
java.util.Enumeration |
getRequestScopedKeys(java.lang.Object namespace,
java.lang.Object requestContext)
Gets the list of all keys in the PipelineSession. |
java.lang.Object |
getSessionScopedAttribute(java.lang.String key,
java.lang.Object namespace)
Gets the named attribute from the PipelineSession . |
java.util.Hashtable |
getSessionScopedAttributeMap(java.lang.Object namespace)
Gets the list of all attributes in the SESSION_SCOPE
and in given namespace as a Hashtable. |
java.util.Enumeration |
getSessionScopedKeys(java.lang.Object namespace)
Gets the list of all keys in the PipelineSession. |
java.lang.Object |
removeRequestScopedAttribute(java.lang.String key,
java.lang.Object namespace,
java.lang.Object requestContext)
Removes the key and the element from the PipelineSession . |
java.lang.Object |
removeSessionScopedAttribute(java.lang.String key,
java.lang.Object namespace)
Removes the key and the element from the PipelineSession . |
void |
setRequestScopedAttribute(java.lang.String key,
java.lang.Object attribute,
java.lang.Object namespace,
java.lang.Object requestContext)
Adds the named attribute to the PipelineSession and sets the scope to
the REQUEST_SCOPE
The attributes set with REQUEST_SCOPE are available till the end of the current
HttpServletRequest . |
void |
setRequestScopedAttributeMap(java.util.Hashtable attrMap,
java.lang.Object namespace,
java.lang.Object requestContext)
Sets the given Hashtable to the REQUEST_SCOPE . |
void |
setSessionScopedAttribute(java.lang.String key,
java.lang.Object attribute,
java.lang.Object namespace)
Adds the named attribute to the PipelineSession and sets the scope to
the SESSION_SCOPE
The attributes set with SESSION_SCOPE are available till the end of the current
HttpSession . |
void |
setSessionScopedAttributeMap(java.util.Hashtable attrMap,
java.lang.Object namespace)
Sets the given Hashtable to the SESSION_SCOPE . |
Method Detail |
public void setSessionScopedAttribute(java.lang.String key, java.lang.Object attribute, java.lang.Object namespace) throws InvalidArgumentException
PipelineSession
and sets the scope to
the SESSION_SCOPE
The attributes set with SESSION_SCOPE are available till the end of the current
HttpSession
.
If the key already exists in the given namespace and scope, then the key is overwritten.
If the namespace does not exist, then a namespace with the given name is created and
then the attribute is added to the newly created namespace.
key
- a String containing the name of the attribute.attribute
- an Object containing the attribute.namespace
- a Object containing the namespace name.public void setRequestScopedAttribute(java.lang.String key, java.lang.Object attribute, java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
PipelineSession
and sets the scope to
the REQUEST_SCOPE
The attributes set with REQUEST_SCOPE are available till the end of the current
HttpServletRequest
.
If the key already exists in the given namespace and scope, then the key is overwritten.
If the namespace does not exist, then a namespace with the given name is created and
then the attribute is added to the newly created namespace.
key
- a String containing the name of the attribute.attribute
- an Object containing the attribute.namespace
- a Object containing the namespace name.requestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.public java.util.Enumeration getNamespaceNames()
public java.lang.Object getSessionScopedAttribute(java.lang.String key, java.lang.Object namespace) throws InvalidArgumentException
PipelineSession
.
This method looks for the attribute in the SESSION_SCOPE
and given namespace. If the attribute is not found then this will
return null
.
key
- a String containing the name of the attribute.namespace
- a Object containing the namespace in which to look
for this attribute.public java.lang.Object getRequestScopedAttribute(java.lang.String key, java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
PipelineSession
.
This method looks for the attribute in the
REQUEST_SCOPE
and given namespace.
If the attribute is not found then this will return null
.
key
- a String containing the name of the attribute.namespace
- a String containing the namespace in which to look
for this attribute.requestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.public java.util.Hashtable getSessionScopedAttributeMap(java.lang.Object namespace) throws InvalidArgumentException
SESSION_SCOPE
and in given namespace as a Hashtable.
namespace
- a Object containing the namespace namepublic java.util.Hashtable getRequestScopedAttributeMap(java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
REQUEST_SCOPE
and in given namespace as a Hashtable.
namespace
- a Object containing the namespace namerequestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.public void setSessionScopedAttributeMap(java.util.Hashtable attrMap, java.lang.Object namespace) throws InvalidArgumentException
SESSION_SCOPE
.
Hashtable
- the attribute map.namespace
- a Object containing the namespace name to which
these attributes should belong.public void setRequestScopedAttributeMap(java.util.Hashtable attrMap, java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
REQUEST_SCOPE
.
Hashtable
- the attribute map.namespace
- a Object containing the namespace name to which
these attributes should belong.requestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.public java.util.Enumeration getSessionScopedKeys(java.lang.Object namespace) throws InvalidArgumentException
SESSION_SCOPE
and in given namespace
namespace
- a Object containing the namespace.public java.util.Enumeration getRequestScopedKeys(java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
REQUEST_SCOPE
and in given namespace
namespace
- a Object containing the namespace.requestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.public Context getContext()
public java.lang.Object getDefaultNamespace()
public boolean containsSessionScopedAttribute(java.lang.String key, java.lang.Object namespace) throws InvalidArgumentException
PipelineSession
.
If the given key belongs to the SESSION_SCOPE
and in given namespace then this method returns true
.
key
- a String containing the name of the attribute.namespace
- a Object containing the namespace in which to look for.true
if the key is found in the given scope.public boolean containsRequestScopedAttribute(java.lang.String key, java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
PipelineSession
.
If the given key belongs to the REQUEST_SCOPE
and in given namespace then this method returns true
.
key
- a String containing the name of the attribute.namespace
- a Object containing the namespace in which to look for.requestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.true
if the key is found in the given scope.public java.lang.Object removeSessionScopedAttribute(java.lang.String key, java.lang.Object namespace) throws InvalidArgumentException
PipelineSession
.
If the given key is present in the SESSION_SCOPE
and given namespace, then this method removes the key and returns the element.
Otherwise returns null
.
key
- a String containing the name of the attribute.namespace
- a Object containing the namespace from which to remove.public java.lang.Object removeRequestScopedAttribute(java.lang.String key, java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
PipelineSession
.
If the given key is present in the REQUEST_SCOPE
and given namespace, then this method removes the key and returns the element.
Otherwise returns null
.
key
- a String containing the name of the attribute.namespace
- a Object containing the namespace from which to remove.requestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.public void clearSessionScopedAttributes(java.lang.Object namespace) throws InvalidArgumentException
PipelineSession
.
Removes all the attributes that belong to the SESSION_SCOPE
and in given namespace.
namespace
- a Object containing the namespace from which to
remove alll the attributespublic void clearRequestScopedAttributes(java.lang.Object namespace, java.lang.Object requestContext) throws InvalidArgumentException
PipelineSession
.
Removes all the attributes that belong to the REQUEST_SCOPE
and in given namespace.
namespace
- a Object containing the namespace from which to
remove alll the attributesrequestContext
- this gives the current requesting threads context-ID with which
this attribute has to be stored in this namespace. If there are multiple requests
using this context id the processes can avoid name collisions of attributes as well
as it will be guaranteed that the attributes added in this thread are available no matter
what the order of execution of the threads are. This context id will be provided to all the
processors so that they can pass it along to specific processor types.
|
© 2002 BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |