All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ControlBeans.ComponentContainer

java.lang.Object
   |
   +----ControlBeans.ComponentContainer

public class ComponentContainer
extends Object
This class implements an object that can store components. It is used by AbstractCommunicator and should not be used directly by the user.


Constructor Index

 o ComponentContainer()
Creates a ComponentContainer with the ability to hold components with tags up to 999.

Method Index

 o addComponent(ComponentInterface)
Adds a component to this container.
 o putValue(double, int, double, int)
Invoked by AbstractCommunicator in order to pass received values on to the components stored in this container.
 o putValue(int, int, double, int)
Invoked by AbstractCommunicator in order to pass received values on to the components stored in this container.
 o putValue(String, int, double, int)
Invoked by AbstractCommuncator in order to pass received values on to the components stored in this container.
 o requestValues()
Called by the communicator to make all components send their value(s).

Constructors

 o ComponentContainer
 public ComponentContainer()
Creates a ComponentContainer with the ability to hold components with tags up to 999.

Methods

 o addComponent
 public synchronized void addComponent(ComponentInterface component)
Adds a component to this container. Invoked by AbstractCommunicator. If the component has multiple tags, a reference for each tag will be stored.

Parameters:
component - a reference to the component to be added
 o putValue
 public synchronized void putValue(int value,
                                   int aTag,
                                   double time,
                                   int ID)
Invoked by AbstractCommunicator in order to pass received values on to the components stored in this container. It will pass the value on to each component that has a tag corresponding to aTag.

Parameters:
value - the value to be set
aTag - the value will be only passed to components containing this tag
time - a time tag for the value
ID - the ID of the component
See Also:
putValue
 o putValue
 public synchronized void putValue(double value,
                                   int aTag,
                                   double time,
                                   int ID)
Invoked by AbstractCommunicator in order to pass received values on to the components stored in this container. It will pass the value on to each component that has a tag corresponding to aTag.

Parameters:
value - the value to be set
aTag - the value will be only passed to components containing this tag
time - a time tag for the value
ID - the ID of the component
See Also:
putValue
 o putValue
 public synchronized void putValue(String value,
                                   int aTag,
                                   double time,
                                   int ID)
Invoked by AbstractCommuncator in order to pass received values on to the components stored in this container. It will pass the value on to each component that has a tag corresponding to aTag.

Parameters:
value - the value to be set
aTag - the value will be only passed to components containing this tag
time - a time tag for the value
ID - the ID of the component
See Also:
putValue
 o requestValues
 public void requestValues()
Called by the communicator to make all components send their value(s). This can be used for initialization.


All Packages  Class Hierarchy  This Package  Previous  Next  Index