NCSA Portfolio

ncsa.j3d.ui.tools
Class ReceiverList

java.lang.Object
  |
  +--ncsa.j3d.ui.tools.ReceiverList

public class ReceiverList
extends java.lang.Object
implements PortfolioEventReceiver

THIS IS CONSIDERED LEGACY CODE AND SHOULD GO AWAY WHEN POSSIBLE. This object maintains a list of PortfolioEventRecievers and is capable of distributing events to them all in one logical operation.


Constructor Summary
ReceiverList()
          Constructs a ReceiverList.
 
Method Summary
 void add(PortfolioEventReceiver i)
          Adds an object into the distribution list.
 boolean contains(PortfolioEventReceiver i)
          Allows an object to find out if a particular object is in the distribution list.
 PortfolioEventReceiver get(int index)
          Indexes into the ditribution list and returns the object at a specific index.
 int getSize()
          Checks the size.
 boolean notify(java.util.EventObject event)
          Distributes an event to all members of the distibution list.
 boolean remove(PortfolioEventReceiver i)
          Removes an object from the distibution list.
 void shred()
          Removes all elements from the distibution list.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReceiverList

public ReceiverList()
Constructs a ReceiverList.
Method Detail

getSize

public int getSize()
Checks the size.
Returns:
The size of the list.

add

public void add(PortfolioEventReceiver i)
Adds an object into the distribution list.
Parameters:
i - The object to be inserted into the distibution list.

remove

public boolean remove(PortfolioEventReceiver i)
Removes an object from the distibution list.
Parameters:
i - The object to be removed.

contains

public boolean contains(PortfolioEventReceiver i)
Allows an object to find out if a particular object is in the distribution list.
Parameters:
i - The object to find out about.

get

public PortfolioEventReceiver get(int index)
Indexes into the ditribution list and returns the object at a specific index.
Parameters:
index - The number of items to index into the list.
Returns:
The object at the index or null.

shred

public void shred()
Removes all elements from the distibution list.
Parameters:
none -  

notify

public boolean notify(java.util.EventObject event)
Distributes an event to all members of the distibution list.
Specified by:
notify in interface PortfolioEventReceiver
Parameters:
event - The event to distribute.

NCSA Portfolio

NCSA Portfolio, Copyright 1997-1999, National Center for Supercomputing Applications, University of Illinois Urbana-Champaign, All Rights Reserved