com.arsdigita.bebop.portal
Interface PortletRenderer

All Known Implementing Classes:
Portlet

public interface PortletRenderer

An interface specifying Component-like behavior for a PortletRenderer, insofar as XML generation is concerned. Since a PortletRenderer gets its state only from PortalModel, it is stateless from the Bebop point of view and does not need Component's state management. We do still, however, want PortletRenderer to produce XML just as other Components do.

The PortletRenderer interface is used in Portal when it builds a new PortalModel and fetches a set of portlets. Portal calls generateXML(com.arsdigita.bebop.PageState, com.arsdigita.xml.Element) on each PortletRenderer returned.

Note that implementers of PortletRenderers will ordinarily want to extend AbstractPortletRenderer since it provides a default XML frame for portlets, one that the Portal stylesheet knows to transform.

Version:
$Id: //core-platform/dev/src/com/arsdigita/bebop/portal/PortletRenderer.java#8 $
Author:
Justin Ross, James Parsons
See Also:
Portal, PortalModel, PortalModelBuilder, AbstractPortletRenderer

Field Summary
static String versionId
           
 
Method Summary
 void generateXML(PageState pageState, Element parentElement)
          Build an XML fragment and attach it to this component's parent.
 Object getCacheKey()
           
 boolean isDirty()
           
 

Field Detail

versionId

public static final String versionId
See Also:
Constant Field Values
Method Detail

generateXML

public void generateXML(PageState pageState,
                        Element parentElement)
Build an XML fragment and attach it to this component's parent. Someone implementing a TimeOfDayPortlet could, for instance, override this method to fetch the time and, say, wrap it in a Bebop Label. Note, however, that it is preferable to extend AbstractPortlet since it provides a default "XML wrapper" for portlets.

Parameters:
pageState - the PageState of the current request.
parentElement - the element to which to attach the XML this method creates.

isDirty

public boolean isDirty()

getCacheKey

public Object getCacheKey()


Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 20 2004:2337 UTC