All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.ibm.beans.mb.BeanBagView

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----java.awt.Panel
                           |
                           +----com.ibm.beans.mb.BeanBagView

public class BeanBagView
extends Panel
implements ModelChangeListener, ItemListener, MouseListener
This class defines the views for a BeanBagModel instance.

See Also:
ModelChangeListener, ItemListener, MouseListener

Variable Index

 o model

Constructor Index

 o BeanBagView()
 o BeanBagView(BeanBagModel)
Constructs a BeanBagView instance containing the specified model.

Method Index

 o acquireMBIcon(ManagedBean)
Gets the best available icon from specified managed bean.
 o destruct()
 o getModel()
Gets the model belonging to the view.
 o handleAdd(ModelEvent)
Handles the event that is fired when managed beans are added to the model.
 o handleChange(ModelEvent)
Handles the event that is fired when managed beans in the model are modified.
 o handleRemove(ModelEvent)
Handles the event that is fired when managed beans are removed from the model.
 o itemStateChanged(ItemEvent)
Handles selection changes in the model.
 o mouseClicked(MouseEvent)
Handles the event generated when the mouse button is clicked in the Container.
 o mouseEntered(MouseEvent)
Handles the event generated when the mouse pointer enters the Container.
 o mouseExited(MouseEvent)
Handles the event generated when the mouse pointer exits the Container.
 o mousePressed(MouseEvent)
Handles the event generated when a mouse button is pressed in the Container.
 o mouseReleased(MouseEvent)
Handles the event generated when a mouse button is release in the Container.
 o setModel(BeanBagModel)
Sets the model belonging to the view.

Variables

 o model
 protected BeanBagModel model

Constructors

 o BeanBagView
 public BeanBagView()
 o BeanBagView
 public BeanBagView(BeanBagModel model)
Constructs a BeanBagView instance containing the specified model. Calls setModel to store the specified model and adds this BeanBagView object as a mouse listener to itself.

Parameters:
model - The BeanBagModel instance to be viewed.
See Also:
BeanBagModel

Methods

 o getModel
 public BeanBagModel getModel()
Gets the model belonging to the view. Returns a reference to the model, not a clone of it.

Returns:
The BeanBagModel instance associated with the view.
See Also:
BeanBagModel
 o setModel
 public synchronized void setModel(BeanBagModel model)
Sets the model belonging to the view. Stores the given model reference (does not clone it). Removes itself as a listener to the previous model and registers itself as a listener to the specified model (both as a ModelChangeListener and an ItemListener).

Parameters:
model - The BeanBagModel instance to be viewed.
See Also:
BeanBagModel
 o destruct
 public synchronized void destruct()
 o acquireMBIcon
 public Image acquireMBIcon(ManagedBean mb)
Gets the best available icon from specified managed bean. If no 32x32 icon is available, then a 16x16 icon is returned (if available).

Parameters:
mb - The managed bean for which an icon is desired.
See Also:
ManagedBean
 o handleAdd
 public void handleAdd(ModelEvent e)
Handles the event that is fired when managed beans are added to the model. The default implementation does nothing.

Parameters:
e - The generated event.
See Also:
ModelEvent, ModelChangeListener
 o handleRemove
 public void handleRemove(ModelEvent e)
Handles the event that is fired when managed beans are removed from the model. The default implementation does nothing.

Parameters:
e - The generated event.
See Also:
ModelEvent, ModelChangeListener
 o handleChange
 public void handleChange(ModelEvent e)
Handles the event that is fired when managed beans in the model are modified. The default implementation does nothing.

Parameters:
e - The generated event.
See Also:
ModelEvent, ModelChangeListener
 o itemStateChanged
 public void itemStateChanged(ItemEvent e)
Handles selection changes in the model. The default implementation does nothing.

Parameters:
e - The generated event.
 o mouseClicked
 public void mouseClicked(MouseEvent e)
Handles the event generated when the mouse button is clicked in the Container. The default implementation does nothing.

Parameters:
e - The generated event.
See Also:
MouseListener, MouseEvent
 o mouseEntered
 public void mouseEntered(MouseEvent e)
Handles the event generated when the mouse pointer enters the Container. The default implementation does nothing.

Parameters:
e - The generated event.
See Also:
MouseListener, MouseEvent
 o mouseExited
 public void mouseExited(MouseEvent e)
Handles the event generated when the mouse pointer exits the Container. The default implementation does nothing.

Parameters:
e - The generated event.
See Also:
MouseListener, MouseEvent
 o mousePressed
 public void mousePressed(MouseEvent e)
Handles the event generated when a mouse button is pressed in the Container. The default implementation deselects all beans in the model.

Parameters:
e - The generated event.
See Also:
MouseListener, MouseEvent
 o mouseReleased
 public void mouseReleased(MouseEvent e)
Handles the event generated when a mouse button is release in the Container. The default implementation does nothing.

Parameters:
e - The generated event.
See Also:
MouseListener, MouseEvent

All Packages  Class Hierarchy  This Package  Previous  Next  Index