com.sapportals.htmlb

Class Container

java.lang.Object
  extended bycom.sapportals.htmlb.Component
      extended bycom.sapportals.htmlb.Container
Direct Known Subclasses:
ButtonRow, ClientEventContainer, Document, DragSource, DropTarget, EventValidationContainer, FlowLayout, Form, FormLayout, FormLayoutCell, GridLayout, Group, ItemList, RasterLayout, ScrollContainer, com.sapportals.htmlb.StatefulButtonGroupBase, StyleContainer, TabStrip, TabStripItem, Toolbar

public abstract class Container
extends Component

Base class for all components that can include other components.

Copyright 2004 SAP AG


Field Summary
protected  List elements
           
 
Constructor Summary
Container()
           
Container(String id)
           
 
Method Summary
 Component addComponent(Component component)
          add a component to this container
 String addRawText(String text)
          add a raw text to this container
 String addText(String text)
          add a raw text to this container
 int getChildCount()
          get the number of children of this container
 Iterator iterator()
          get an Iterator of the children
 void preRender(IPageContext pc)
          preRender traverses the component tree right before rendering
 void removeComponent(Component component)
          remove a specific component from this container
 void render(int selector, IPageContext rendererContext)
          render an aspect of the component using the current context.
 
Methods inherited from class com.sapportals.htmlb.Component
getEncodedIdForForm, getId, getParent, getUI, initFromPageContext, initFromShortId, initializeFromId, isJsObjectNeeded, render, renderAsString, requiresForm, setId, setJsObjectNeeded, setParent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

elements

protected List elements
Constructor Detail

Container

public Container()

Container

public Container(String id)
Method Detail

render

public void render(int selector,
                   IPageContext rendererContext)
render an aspect of the component using the current context. This method can be used by components that do not produce an atomic HTML code.

Parameters:
selector - the aspect to render.
rendererContext - the context in which to render.

addComponent

public Component addComponent(Component component)
add a component to this container

Parameters:
component - the component to add

addText

public String addText(String text)
add a raw text to this container

Parameters:
text - the text to add

addRawText

public String addRawText(String text)
add a raw text to this container

Parameters:
text - the text to add

removeComponent

public void removeComponent(Component component)
remove a specific component from this container

Parameters:
component - the component to remove

getChildCount

public int getChildCount()
get the number of children of this container

Returns:
the number of children

iterator

public Iterator iterator()
get an Iterator of the children

Returns:
an Iterator of the children

preRender

public void preRender(IPageContext pc)
preRender traverses the component tree right before rendering

Overrides:
preRender in class Component


Copyright 2006 SAP AG Complete Copyright Notice