Package com.aspectran.core.activity
Class ActivityDataMap
- java.lang.Object
-
- java.util.AbstractMap<K,V>
-
- java.util.HashMap<java.lang.String,java.lang.Object>
-
- com.aspectran.core.activity.ActivityDataMap
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable,java.util.Map<java.lang.String,java.lang.Object>
- Direct Known Subclasses:
TemplateDataMap
public class ActivityDataMap extends java.util.HashMap<java.lang.String,java.lang.Object>A map of data for saving activity results. It is often used as a model for providing data used in views.This class is generally not thread-safe. It is primarily designed for use in a single thread only.
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected Activityactivityprotected RequestAdapterrequestAdapter
-
Constructor Summary
Constructors Constructor Description ActivityDataMap(Activity activity)Instantiates a new ActivityDataMap.ActivityDataMap(Activity activity, boolean prefill)Instantiates a new ActivityDataMap.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectget(java.lang.Object key)java.lang.ObjectgetActionResultWithoutCache(java.lang.String name)Returns the value of the named action's process result without storing it in the cache.java.lang.ObjectgetAttributeWithoutCache(java.lang.String name)Returns the value of the named attribute from the request adapter without storing it in the cache.java.lang.ObjectgetParameterWithoutCache(java.lang.String name)Returns the value of the request parameter from the request adapter without storing it in the cache.
-
-
-
Field Detail
-
activity
protected final Activity activity
-
requestAdapter
protected final RequestAdapter requestAdapter
-
-
Constructor Detail
-
ActivityDataMap
public ActivityDataMap(Activity activity)
Instantiates a new ActivityDataMap.- Parameters:
activity- the activity
-
ActivityDataMap
public ActivityDataMap(Activity activity, boolean prefill)
Instantiates a new ActivityDataMap.- Parameters:
activity- the activityprefill- whether or not to pre-fill the data
-
-
Method Detail
-
get
public java.lang.Object get(java.lang.Object key)
- Specified by:
getin interfacejava.util.Map<java.lang.String,java.lang.Object>- Overrides:
getin classjava.util.HashMap<java.lang.String,java.lang.Object>
-
getParameterWithoutCache
public java.lang.Object getParameterWithoutCache(java.lang.String name)
Returns the value of the request parameter from the request adapter without storing it in the cache. If the parameter does not exist, returns null.- Parameters:
name- aStringspecifying the name of the parameter- Returns:
- an
Objectcontaining the value of the parameter, ornullif the parameter does not exist - See Also:
RequestAdapter.setParameter(java.lang.String, java.lang.String)
-
getAttributeWithoutCache
public java.lang.Object getAttributeWithoutCache(java.lang.String name)
Returns the value of the named attribute from the request adapter without storing it in the cache. If no attribute of the given name exists, returns null.- Parameters:
name- aStringspecifying the name of the attribute- Returns:
- an
Objectcontaining the value of the attribute, ornullif the attribute does not exist - See Also:
RequestAdapter.getAttribute(java.lang.String)
-
getActionResultWithoutCache
public java.lang.Object getActionResultWithoutCache(java.lang.String name)
Returns the value of the named action's process result without storing it in the cache. If no process result of the given name exists, returns null.- Parameters:
name- aStringspecifying the name of the action- Returns:
- an
Objectcontaining the value of the action result, ornullif the action result does not exist - See Also:
RequestAdapter.getAttribute(java.lang.String)
-
-