| |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PortletModel
This interface provides access to the model for the different levels of portlet configuration. The resulting model is scoped to a particular request and user context and contains only those resources that are visible in that context.
It expresses the linking between the different portlet-related resources; for example, to find the correct portlet entity for a portlet window in the scope of the current request (user), the appropriate portlet model for the current request must be queried.
In the current portal version, all instances of PortletDefinition, Portlet and WebApplication are global, therefore the objects of these types that are returned by this model must be instances that are available through the global com.ibm.portal.portletmodel.admin">AdminPortletModel.
Only objects returned from this API may be passed as arguments to the methods.
Method Summary | |
---|---|
PortletEntity | com.ibm.portal.portletmodel.PortletEntity)">getParentPortletEntity(PortletEntity entity)
Returns the parent portlet entity that provides defaults for preferences. |
Portlet | com.ibm.portal.portletmodel.PortletDefinition)">getPortlet(PortletDefinition portletDefinition)
Return the portlet that represents the deployed code unit for the given portlet definition. |
PortletDefinition | com.ibm.portal.portletmodel.PortletEntity)">getPortletDefinition(PortletEntity entity)
Return the portlet definition that defines administrative settings for the portlet configuration represented by this entity |
PortletDefinition | com.ibm.portal.portletmodel.PortletWindow)">getPortletDefinition(PortletWindow window)
Return the portlet definition that defines administrative settings for the portlet shown in the given window. |
PortletEntity | com.ibm.portal.portletmodel.PortletWindow)">getPortletEntity(PortletWindow window)
Return a portlet entity that defines preferences for this portlet in the context of the scope of this portlet model. |
PortletWindow | com.ibm.portal.content.LayoutControl)">getPortletWindow(LayoutControl control)
Return the portlet window that is associated with the given layout control. |
PortletPreferences | com.ibm.portal.portletmodel.PortletDefinition)">getPreferencesHierarchy(PortletDefinition definition)
Return an aggregated view of the preference layers associated with the given portlet definition. |
PortletPreferences | com.ibm.portal.portletmodel.PortletEntity)">getPreferencesHierarchy(PortletEntity entity)
Return an aggregated view of the preference layers associated with the given portlet entity. |
WebApplication | com.ibm.portal.portletmodel.Portlet)">getWebApplication(Portlet portlet)
Returns the web application that represents the deployment unit for the given portlet |
Method Detail |
---|
PortletWindow getPortletWindow(LayoutControl control) throws ModelException
null
.
PortletEntity getPortletEntity(PortletWindow window) throws ModelException
null
.
PortletEntity getParentPortletEntity(PortletEntity entity) throws ModelException
null
, if no parent portlet entity exists.
Portlet entities can form a hierarchy where a parent portlet entity provides default values for those preferences that are not explicitly set or overridden on a child portlet entity. In the current portal version, the hierarchy of portlet entities can be at most two levels deep: a portlet entity either has no parent or it is a personalized portlet entity for a particular user and its parent is a shared portlet entity that itself has no parent.
For JSR portlets that do not operate in a special compatibility mode, preferences that are set in EDIT or VIEW mode are stored in a personalized portlet entity, while preferences that are set in EDIT_DEFAULTS mode are stored in a shared portlet entity.
null
.
PortletDefinition getPortletDefinition(PortletWindow window) throws ModelException
This method is more efficient but returns the same portlet definition as
getPorletDefinition(getPortletEntity(window))
null
PortletDefinition getPortletDefinition(PortletEntity entity) throws ModelException
null
Portlet getPortlet(PortletDefinition portletDefinition) throws ModelException
null
.
WebApplication getWebApplication(Portlet portlet) throws ModelException
PortletPreferences getPreferencesHierarchy(PortletEntity entity) throws ModelException
PortletPreferences getPreferencesHierarchy(PortletDefinition definition) throws ModelException
| |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |