org.apache.jetspeed.cache
Interface PortletWindowCache


public interface PortletWindowCache

org.apache.jetspeed.cache.impl.PortletWindowCache is an abstraction of a caching mechanism for use within org.apache.jetspeed.container.window.impl.PortletWindowAccessorImpl.

Author:
Scott T. Weaver
See Also:
PortletWindowAccessorImpl, EhPortletWindowCache

Method Summary
 Set getAllPortletWindows()
           
 org.apache.pluto.om.window.PortletWindow getPortletWindow(String windowId)
          Gets a PortletWindow from the cache.
 org.apache.pluto.om.window.PortletWindow getPortletWindowByEntityId(String portletEntityId)
          Gets a PortletWindow from the cache whose PortletEntity's (PortletWindow.getPortletEntity()) equals portletEntityId.
 void putPortletWindow(org.apache.pluto.om.window.PortletWindow window)
          Stores a PortletWindow in the cache using the PortletWindow#getId()#toString() as the key for the cache.
 void removePortletWindow(String windowId)
          Removes a PortletWindow from cache using the windowId as the cache key.
 void removePortletWindowByPortletEntityId(String portletEntityId)
          Removes a PortletWindow from the cache whose PortletEntity's id matches portletEntityId.
 

Method Detail

getPortletWindow

org.apache.pluto.om.window.PortletWindow getPortletWindow(String windowId)
Gets a PortletWindow from the cache.

Parameters:
windowId - Id of the window to get from the cache.
Returns:
PortletWindow whose id to PortletWindow.getId() or null if no window exists that matches windowId.

getPortletWindowByEntityId

org.apache.pluto.om.window.PortletWindow getPortletWindowByEntityId(String portletEntityId)
Gets a PortletWindow from the cache whose PortletEntity's (PortletWindow.getPortletEntity()) equals portletEntityId.

Parameters:
portletEntityId - id of PortletEntity whose window want want to retrieve from cache.
Returns:
PortletWindow whose PortletEntity's id equals portletEntityId or null if no windows exists in the cache that match said criteria.

putPortletWindow

void putPortletWindow(org.apache.pluto.om.window.PortletWindow window)
Stores a PortletWindow in the cache using the PortletWindow#getId()#toString() as the key for the cache.

Parameters:
window - PortletWindow to put into the cache.

removePortletWindow

void removePortletWindow(String windowId)
Removes a PortletWindow from cache using the windowId as the cache key.

Parameters:
windowId - Id of the PortletWindow we want to remove from the cache.

removePortletWindowByPortletEntityId

void removePortletWindowByPortletEntityId(String portletEntityId)
Removes a PortletWindow from the cache whose PortletEntity's id matches portletEntityId.

Parameters:
portletEntityId - id of the PortletEntity whose parent PortletWindow is to be removed from the cache.

getAllPortletWindows

Set getAllPortletWindows()
Returns:
List of all the PortletWindows in the cache. If no cache entries exist an empty list is returned. Never returns null.


Copyright © 1999-2007 Apache Software Foundation. All Rights Reserved.