org.apache.wsrp4j.consumer
Interface PortletRegistry

All Known Implementing Classes:
GenericPortletRegistryImpl

public interface PortletRegistry

This interface defines a registry which holds portlet objects.

Author:
Stephan Laertz

Method Summary
 void addPortlet(WSRPPortlet portlet)
          Add a portlet to the registry
 boolean existsPortlet(PortletKey portletKey)
          Tests if a portlet with the given portlet key
 java.util.Iterator getAllPortlets()
          Get all the portlets in the register
 WSRPPortlet getPortlet(PortletKey portletKey)
          Get the portlet for the given producer and portlet handle
 void removeAllPortlets()
          Remove all portlets from the registry
 WSRPPortlet removePortlet(PortletKey portletKey)
          Remove the portlet with the given portlet key
 

Method Detail

addPortlet

public void addPortlet(WSRPPortlet portlet)
                throws WSRPException
Add a portlet to the registry

Parameters:
portlet - The portlet to add
Throws:
WSRPException

getPortlet

public WSRPPortlet getPortlet(PortletKey portletKey)
Get the portlet for the given producer and portlet handle

Parameters:
portletKey - The portlet key identifying the portlet
Returns:
The portlet with the given portlet key

removePortlet

public WSRPPortlet removePortlet(PortletKey portletKey)
Remove the portlet with the given portlet key

Parameters:
portletKey - The portlet key identifying the portlet
Returns:
The portlet which has been removed or null

existsPortlet

public boolean existsPortlet(PortletKey portletKey)
Tests if a portlet with the given portlet key

Parameters:
portletKey - The portlet key identifying the portlet
Returns:
True if portlet exists with this portlet key

getAllPortlets

public java.util.Iterator getAllPortlets()
Get all the portlets in the register

Returns:
Iterator with all portlets in the registry

removeAllPortlets

public void removeAllPortlets()
Remove all portlets from the registry