borland.jbcl Packages  borland.jbcl Class Hierarchy  borland.jbcl.model 

VectorModelMulticaster class

java.lang.Object
   +----borland.jbcl.model.VectorModelMulticaster

About the VectorModelMulticaster class

Properties  Methods  

Implements VectorModelListener, EventListener

A class that dispatches vector model events to multiple listeners. VectorModelMulticaster maintains an array of listeners. The add(), remove(), and find() methods are used to manage this list.

The hasListeners() method determines whether any objects are listening for vector-model events. The dispatch() method sends a vector-model event to all listeners.

VectorModelMulticaster is not required to synchronize its access of the array of listeners because all changes are made to a copy of the original list.


VectorModelMulticaster properties

*Read-only properties **Write-only properties

Properties implemented in java.lang.Object

VectorModelMulticaster methods

Methods implemented in this class

Methods implemented in java.lang.Object


VectorModelMulticaster methods

add(borland.jbcl.model.VectorModelListener)

  public final synchronized void add(borland.jbcl.model.VectorModelListener listener)
Adds an object to the array of listeners.

Parameters:

listener
The object that is added to the list of listeners for vector-model events.

dispatch(borland.jbcl.model.VectorModelEvent)

  public final void dispatch(borland.jbcl.model.VectorModelEvent e)
Sends a vector-model event to all listeners. This is a high-speed dispatcher that does not need to be synchronized. If the event ID is CONTENT_CHANGED, it calls the modelContentChanged() method of the vector-model listeners. If the event ID is STRUCTURE_CHANGED, it calls the modelStructureChanged() method of the vector-model listeners.

Parameters:

e
The vector-model event sent to all listeners.

find(borland.jbcl.model.VectorModelListener)

  public int find(borland.jbcl.model.VectorModelListener listener)
Searches for the specified listener among the array of listening objects.

Parameters:

listener
The object you are searching for in the list of listeners.

hasListeners()

  public final boolean hasListeners()
Determines if there are any listeners for vector-model events. If the method returns true, one or more listeners are present.

remove(borland.jbcl.model.VectorModelListener)

  public final synchronized void remove(borland.jbcl.model.VectorModelListener listener)
Removes the specified listening object from the array of listeners for vector-model events.

Parameters:

listener
The listening object that is removed from the array of listeners.