SAP NetWeaver '04

com.sapportals.wcm.rendering.layout
Class AbstractLayoutComposer

[contained in: com.sap.km.cm.ui.flex.par - km.shared.ui.flex.layout_api.jar]
java.lang.Object
  |
  +--com.sapportals.wcm.rendering.layout.AbstractLayoutComposer
All Implemented Interfaces:
IExtLayoutController, ILayoutComponent, ILayoutController

public abstract class AbstractLayoutComposer
extends java.lang.Object
implements ILayoutController, IExtLayoutController

Since:
NW04, FP This acts as a wrapper to shield implementations of the ILayoutController interface from the classes of the Wdf-package. Extend this class if you need to implement the ILayoutController interface. For the implementation see the java-doc of the two implemented interfaces.

Constructor Summary
AbstractLayoutComposer()
           
 
Method Summary
 com.sapportals.wdf.stack.Control[] getControls()
          returns all conrols that have to be registered with the Wdf-Framework.
abstract  ILayoutController getNewInstance()
          returns a new instance of the implementing class.
protected  IProxy getProxy()
           
abstract  IResourceListProvider[] getResourceListProvider()
           
abstract  void init()
          this method is called by the LayoutControllerFactory when the initialization of the implementing class is finished.
abstract  void readInputData(com.sapportals.htmlb.page.DynPage page)
          called by the IProxy that holds an instance of the implementing class after the user has initiated a server roundtrip.
 com.sapportals.htmlb.Component render()
          creates and returns the visible components for the user.
protected abstract  com.sapportals.htmlb.Component renderAll()
          this method is called by the method render as defined in the ILayoutController interface.
 void setProxy(IProxy proxy)
          sets the proxy-attribute for the layout-controller.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractLayoutComposer

public AbstractLayoutComposer()
Method Detail

getNewInstance

public abstract ILayoutController getNewInstance()
Description copied from interface: ILayoutController
returns a new instance of the implementing class. This method is used by the LayoutControllerFactory. The Factory holds one instance of the implementing class and calls its getNewInstance method. This allows the implementing class to set parameters at the newly created instance. It also reduces calls of the Class.forName() to gain performance.
Specified by:
getNewInstance in interface ILayoutController
Following copied from interface: com.sapportals.wcm.rendering.layout.ILayoutController
Returns:
a new instance of the implementing class, never returns null.

getControls

public final com.sapportals.wdf.stack.Control[] getControls()
Description copied from interface: ILayoutController
returns all conrols that have to be registered with the Wdf-Framework. If a control within the ILayoutController is not returned via this method, it can not use the Wdf-functionalities such as persistence of simple data types or the use of the WdfEventDispatcher to create Link or Button elements.
Specified by:
getControls in interface ILayoutController
Following copied from interface: com.sapportals.wcm.rendering.layout.ILayoutController
Returns:
an array of all controls inside the layoutcontroller that are to be registered with the WDF. The array must not contain null.

render

public final com.sapportals.htmlb.Component render()
                                            throws com.sapportals.wdf.WdfException
Description copied from interface: ILayoutController
creates and returns the visible components for the user. It is called, when the control that holds this instance (usually the IProxy is rendered by the Wdf-Framework. See the Wdf-Framework for details.
Specified by:
render in interface ILayoutController
Following copied from interface: com.sapportals.wcm.rendering.layout.ILayoutController
Returns:
an htmlb-Component that is to be displayed to the user

renderAll

protected abstract com.sapportals.htmlb.Component renderAll()
                                                     throws WcmException
this method is called by the method render as defined in the ILayoutController interface. To wrap the WdfException stated in that method, this abstract class requires extending classes to use this method instead.
Returns:
a Component to be rendered, must not be null
Throws:
WcmException - in case of an error

setProxy

public final void setProxy(IProxy proxy)
Description copied from interface: ILayoutComponent
sets the proxy-attribute for the layout-controller. The proxy has to be passed to classes within the ILayoutController, which want to use the proxy's services.
Specified by:
setProxy in interface ILayoutComponent

getProxy

protected final IProxy getProxy()

init

public abstract void init()
                   throws WcmException
Description copied from interface: IExtLayoutController
this method is called by the LayoutControllerFactory when the initialization of the implementing class is finished. At this point of time, it is ok for the implementing class to instantiate its ICollectionRenderer instances and to access fields such as IProxy
Specified by:
init in interface IExtLayoutController
Following copied from interface: com.sapportals.wcm.rendering.layout.IExtLayoutController
Throws:
WcmException -  

readInputData

public abstract void readInputData(com.sapportals.htmlb.page.DynPage page)
Description copied from interface: IExtLayoutController
called by the IProxy that holds an instance of the implementing class after the user has initiated a server roundtrip.
Specified by:
readInputData in interface IExtLayoutController
Following copied from interface: com.sapportals.wcm.rendering.layout.IExtLayoutController
Parameters:
page - the dynpage to read the user input from, must not be null.

getResourceListProvider

public abstract IResourceListProvider[] getResourceListProvider()
Specified by:
getResourceListProvider in interface IExtLayoutController
Following copied from interface: com.sapportals.wcm.rendering.layout.IExtLayoutController
Returns:
a list of classes that implement this interface and are rendered by this class. Might return an empty array, but must not return null.

SAP NetWeaver '04

Copyright © 2004 by SAP AG. All Rights Reserved.
SAP, R/3, mySAP, mySAP.com, xApps, xApp, SAP NetWeaver, and other SAP products and services mentioned herein as well as their respective logos are trademarks or registered trademarks of SAP AG in Germany and in several other countries all over the world. All other product and service names mentioned are the trademarks of their respective companies. Data contained in this document serves informational purposes only. National product specifications may vary.

These materials are subject to change without notice. These materials are provided by SAP AG and its affiliated companies ("SAP Group") for informational purposes only, without representation or warranty of any kind, and SAP Group shall not be liable for errors or omissions with respect to the materials. The only warranties for SAP Group products and services are those that are set forth in the express warranty statements accompanying such products and services, if any. Nothing herein should be construed as constituting an additional warranty.