Class ModelAdapter<S,C extends Serializable>
java.lang.Object
org.exoplatform.portal.webui.application.ModelAdapter<S,C>
- Version:
- $Revision$
- Author:
- Julien Viet
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <S,C extends Serializable, I>
ModelAdapter<S, C> getAdapter(org.exoplatform.portal.config.model.ApplicationType<S> type) abstract org.gatein.pc.api.StatefulPortletContext<C> getPortletContext(org.exoplatform.container.ExoContainer container, String applicationId, org.exoplatform.portal.config.model.ApplicationState<S> applicationState) abstract org.gatein.pc.api.PortletContextgetProducerOfferedPortletContext(String applicationId) StatefulPortletContext returned by getPortletContext is actually of type PortletStateType.OPAQUE so that it can be properly handled in WSRP...abstract org.exoplatform.portal.pom.spi.portlet.PortletgetState(org.exoplatform.container.ExoContainer container, org.exoplatform.portal.config.model.ApplicationState<S> applicationState) Returns the state of the gadget as preferences or null if the preferences cannot be edited as such.abstract CgetstateFromClonedContext(org.gatein.pc.api.PortletContext originalPortletContext, org.gatein.pc.api.PortletContext clonedPortletContext) Extracts the state based on what the current PortletContext is and the new cloned PortletContextabstract CgetStateFromModifiedContext(org.gatein.pc.api.PortletContext originalPortletContext, org.gatein.pc.api.PortletContext modifiedPortletContext) Extracts the state based on what the current PortletContext is and the new modified PortletContext.abstract org.exoplatform.portal.config.model.ApplicationState<S> update(org.exoplatform.container.ExoContainer container, C updateState, org.exoplatform.portal.config.model.ApplicationState<S> applicationState)
-
Constructor Details
-
ModelAdapter
public ModelAdapter()
-
-
Method Details
-
getAdapter
public static <S,C extends Serializable, ModelAdapter<S,I> C> getAdapter(org.exoplatform.portal.config.model.ApplicationType<S> type) -
getProducerOfferedPortletContext
public abstract org.gatein.pc.api.PortletContext getProducerOfferedPortletContext(String applicationId) StatefulPortletContext returned by getPortletContext is actually of type PortletStateType.OPAQUE so that it can be properly handled in WSRP... This model needs to be revisited if we want to properly support consumer-side state management. See GTNPORTAL-736. -
getPortletContext
public abstract org.gatein.pc.api.StatefulPortletContext<C> getPortletContext(org.exoplatform.container.ExoContainer container, String applicationId, org.exoplatform.portal.config.model.ApplicationState<S> applicationState) throws Exception - Throws:
Exception
-
update
public abstract org.exoplatform.portal.config.model.ApplicationState<S> update(org.exoplatform.container.ExoContainer container, C updateState, org.exoplatform.portal.config.model.ApplicationState<S> applicationState) throws Exception - Throws:
Exception
-
getState
public abstract org.exoplatform.portal.pom.spi.portlet.Portlet getState(org.exoplatform.container.ExoContainer container, org.exoplatform.portal.config.model.ApplicationState<S> applicationState) throws Exception Returns the state of the gadget as preferences or null if the preferences cannot be edited as such.- Parameters:
container- the containerapplicationState- the application state- Returns:
- the preferences
- Throws:
Exception- any exception
-
getStateFromModifiedContext
public abstract C getStateFromModifiedContext(org.gatein.pc.api.PortletContext originalPortletContext, org.gatein.pc.api.PortletContext modifiedPortletContext) Extracts the state based on what the current PortletContext is and the new modified PortletContext.- Parameters:
originalPortletContext- The current PortletContext for the PortletmodifiedPortletContext- The new modified PortletContext- Returns:
-
getstateFromClonedContext
public abstract C getstateFromClonedContext(org.gatein.pc.api.PortletContext originalPortletContext, org.gatein.pc.api.PortletContext clonedPortletContext) Extracts the state based on what the current PortletContext is and the new cloned PortletContext- Parameters:
originalPortletContext- The current PortletContext for the PortletclonedPortletContext- The new cloned PortletContext- Returns:
-