|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--org.jwarp.flow.form.model.Component
|
+--org.jwarp.flow.form.model.Container
A generic JWeb container object is a component that can contain other element components.
Components added to a container are tracked in a list. The order of the list will define the components' front-to-back stacking order within the container. If no index is specified when adding a component to a container, it will be added to the end of the list (and hence to the bottom of the stacking order).
Container| Field Summary | |
java.util.Vector |
components
The actual subcomponents |
java.util.Vector |
containerListeners
The registered listeners |
| Fields inherited from class org.jwarp.flow.form.model.Component |
componentListeners, description, enabled, id, locale, name, parent |
| Constructor Summary | |
Container(int id,
java.lang.String name,
IContainer parent)
|
|
Container(java.lang.String name,
IContainer parent)
|
|
| Method Summary | |
void |
add(IComponent comp)
Adds the specified component to the end of this container. |
void |
add(IComponent comp,
int index)
Adds the specified component to this container at the given position. |
void |
addContainerListener(IContainerListener l)
Adds the specified container listener to receive container events from this container. |
boolean |
contains(IComponent c)
Checks if the component is contained in the component hierarchy of this container. |
IComponent |
getComponent(int n)
Gets the nth component in this container. |
int |
getComponentCount()
Gets the number of components in this panel. |
java.util.Iterator |
getComponents()
Gets all the components in this container. |
void |
handleEvent(ComponentEvent event)
Handles the events. |
void |
remove(IComponent comp)
Removes the specified component from this container. |
IComponent |
remove(int index)
Removes the component, specified by index, from this container. |
void |
removeAll()
Removes all the components from this container. |
void |
removeContainerListener(IContainerListener l)
Removes the specified container listener so it no longer receives container events from this container. |
| Methods inherited from class org.jwarp.flow.form.model.Component |
addComponentListener, getDescription, getFullName, getID, getListeners, getLocale, getName, getParent, getXMLTree, isEnabled, removeComponentListener, setDescription, setEnabled, setFlowData, setLocale, setName, setParent |
| Methods inherited from class java.lang.Object |
|
| Methods inherited from interface org.jwarp.flow.form.model.IComponent |
addComponentListener, getDescription, getFullName, getID, getListeners, getLocale, getName, getParent, getXMLTree, isEnabled, removeComponentListener, setEnabled, setFlowData, setLocale |
| Field Detail |
public java.util.Vector components
public java.util.Vector containerListeners
| Constructor Detail |
public Container(int id,
java.lang.String name,
IContainer parent)
public Container(java.lang.String name,
IContainer parent)
| Method Detail |
public int getComponentCount()
getComponentCount in interface IContainerContainer.getComponent(int)public IComponent getComponent(int n)
getComponent in interface IContainern - the index of the component to get.ArrayIndexOutOfBoundsException - if the nth value does not exist.public java.util.Iterator getComponents()
getComponents in interface IContainerpublic void add(IComponent comp)
add in interface IContainercomp - the component to be added.
public void add(IComponent comp,
int index)
add in interface IContainercomp - the component to be added.index - the position at which to insert the component,
or -1 to insert the component at the end.compremove(int)public IComponent remove(int index)
index, from this container.remove in interface IContainerindex - the index of the component to be removed.add(org.jwarp.flow.form.model.IComponent)public void remove(IComponent comp)
remove in interface IContainercomp - the component to be removedadd(org.jwarp.flow.form.model.IComponent)public void removeAll()
removeAll in interface IContaineradd(org.jwarp.flow.form.model.IComponent),
remove(int)public void addContainerListener(IContainerListener l)
addContainerListener in interface IContainerl - the container listenerpublic void removeContainerListener(IContainerListener l)
removeContainerListener in interface IContainerl - the container listenerpublic boolean contains(IComponent c)
contains in interface IContainerc - the componenttrue if it is an ancestor; false otherwise.public void handleEvent(ComponentEvent event)
IComponenthandleEvent in interface IComponenthandleEvent in class Componentorg.jwarp.flow.form.model.IComponentevent - The event to be handled
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||