public class SessionPropertyPersistenceStrategy extends java.lang.Object implements PropertyPersistenceStrategy
PropertyPersistenceStrategy
, which stores
properties in the HttpSession as attributes.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
STRATEGY_ID |
Constructor and Description |
---|
SessionPropertyPersistenceStrategy() |
Modifier and Type | Method and Description |
---|---|
void |
addParametersForPersistentProperties(ServiceEncoding encoding,
boolean post)
Does nothing; session persistence does not make use of query parameters.
|
void |
discardStoredChanges(java.lang.String pageName)
Invoked to discard any stored changes for the specified page.
|
java.util.Collection |
getStoredChanges(java.lang.String pageName)
Returns a collection of
PropertyChange s. |
void |
setApplicationId(java.lang.String applicationName) |
void |
setRequest(WebRequest request) |
void |
store(java.lang.String pageName,
java.lang.String idPath,
java.lang.String propertyName,
java.lang.Object newValue)
Stores the new value.
|
public static final java.lang.String STRATEGY_ID
public SessionPropertyPersistenceStrategy()
public void store(java.lang.String pageName, java.lang.String idPath, java.lang.String propertyName, java.lang.Object newValue)
PropertyPersistenceStrategy
store
in interface PropertyPersistenceStrategy
pageName
- the name of the page containing the propertyidPath
- the path to the component with the property (may be null)propertyName
- the name of the property to be persistednewValue
- the new value (which may be null)public java.util.Collection getStoredChanges(java.lang.String pageName)
PropertyPersistenceStrategy
PropertyChange
s. These represent
prior changes previously stored. The order is not significant. Must not return null. Does not
have to reflect changes made during the current request (this method is typically invoked as
part of rolling back a page to a prior state, before any further changes are possible).getStoredChanges
in interface PropertyPersistenceStrategy
public void discardStoredChanges(java.lang.String pageName)
PropertyPersistenceStrategy
discardStoredChanges
in interface PropertyPersistenceStrategy
public void addParametersForPersistentProperties(ServiceEncoding encoding, boolean post)
addParametersForPersistentProperties
in interface PropertyPersistenceStrategy
encoding
- Service encoding, which indentifies the URL and the query parameters from which
the ILink
will be created.post
- if true, then the link will be used for a post (not a get, i.e., for a HTML form);
this may affect what information is encoded into the linkPropertyPersistenceStrategySource
public void setApplicationId(java.lang.String applicationName)
public void setRequest(WebRequest request)