Interface PortletStatePersistenceManager
-
- All Known Implementing Classes:
AbstractPortletStatePersistenceManager,PortletStatePersistenceManagerService
public interface PortletStatePersistenceManagerAn abstraction for enabling state management on the producer side.- Version:
- $Revision: 5873 $
- Author:
- Julien Viet
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringcloneState(String stateId)Clone an existing state.StringcloneState(String stateId, org.gatein.pc.api.state.PropertyMap propertyMap)Clone an existing state.StringcreateState(String portletId, org.gatein.pc.api.state.PropertyMap propertyMap)Create the initial state.voiddestroyState(String stateId)Destroy the state.PortletStateContextloadState(String stateId)Load the state.voidupdateState(String stateId, org.gatein.pc.api.state.PropertyMap propertyMap)Update the state.
-
-
-
Method Detail
-
loadState
PortletStateContext loadState(String stateId) throws IllegalArgumentException, NoSuchStateException, InvalidStateIdException
Load the state.- Parameters:
stateId- the state id- Returns:
- the value map or null if it does not exist
- Throws:
IllegalArgumentException- if the state id is nullNoSuchStateException- is the specified state does not existInvalidStateIdException- if the state id is not valid
-
createState
String createState(String portletId, org.gatein.pc.api.state.PropertyMap propertyMap) throws IllegalArgumentException
Create the initial state.- Parameters:
portletId- the id that this state refers to- Returns:
- the id of the state created
- Throws:
IllegalArgumentException- if the portlet id is null
-
cloneState
String cloneState(String stateId) throws IllegalArgumentException, NoSuchStateException, InvalidStateIdException
Clone an existing state.- Parameters:
stateId- the id that this state refers to- Returns:
- the state id
- Throws:
IllegalArgumentException- if the state id is nullNoSuchStateException- is the specified state does not existInvalidStateIdException- if the state id is not valid
-
cloneState
String cloneState(String stateId, org.gatein.pc.api.state.PropertyMap propertyMap) throws IllegalArgumentException, NoSuchStateException, InvalidStateIdException
Clone an existing state.- Parameters:
stateId- the id that this state refers topropertyMap- the values of the cloned state- Returns:
- the state id
- Throws:
IllegalArgumentException- if the state id is null or the value is nulNoSuchStateException- is the specified state does not existInvalidStateIdException- if the state id is not valid
-
updateState
void updateState(String stateId, org.gatein.pc.api.state.PropertyMap propertyMap) throws IllegalArgumentException, NoSuchStateException, InvalidStateIdException
Update the state.- Parameters:
stateId-propertyMap- the updated state- Throws:
IllegalArgumentException- if the state id is null or the values are nullNoSuchStateException- is the specified state does not existInvalidStateIdException- if the state id is not valid
-
destroyState
void destroyState(String stateId) throws IllegalArgumentException, NoSuchStateException, InvalidStateIdException
Destroy the state.- Parameters:
stateId-- Throws:
IllegalArgumentException- if the state id is nullNoSuchStateException- is the specified state does not existInvalidStateIdException- if the state id is not valid
-
-