Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## edu.uci.ics.jung.utils
Class DefaultChangeEventSupport

    java.lang.Object
      edu.uci.ics.jung.utils.DefaultChangeEventSupport

All Implemented Interfaces:
  ChangeEventSupport

public class DefaultChangeEventSupport
extends Object
implements ChangeEventSupport

Field Summary
`protected ChangeEvent` | `changeEvent` Only one `ChangeEvent` is needed instance since the event's only state is the source property.
`protected EventListenerList` | `listenerList` holds the registered listeners

Constructor Summary
`DefaultChangeEventSupport(Object eventSource)`

Method Summary
`void` | `addChangeListener(ChangeListener l)`
`void` | `fireStateChanged()` Notifies all listeners that have registered interest for notification on this event type.
`ChangeListener[]` | `getChangeListeners()` Returns an array of all the `ChangeListener`s added with addChangeListener().
`void` | `removeChangeListener(ChangeListener l)` Removes a ChangeListener.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### listenerList

    protected EventListenerList listenerList

  holds the registered listeners

### changeEvent

    protected transient ChangeEvent changeEvent

  Only one `ChangeEvent` is needed instance since the event's only state is the source property. The source of events generated is always "this".

Constructor Detail

### DefaultChangeEventSupport

    public DefaultChangeEventSupport(Object eventSource)

Method Detail

### addChangeListener

    public void addChangeListener(ChangeListener l)

  Specified by:
    `addChangeListener` in interface `ChangeEventSupport`

### removeChangeListener

    public void removeChangeListener(ChangeListener l)

  Description copied from interface: `ChangeEventSupport`
  Removes a ChangeListener.

  Specified by:
    `removeChangeListener` in interface `ChangeEventSupport`
  Parameters:
    `l` - the listener to be removed

### getChangeListeners

    public ChangeListener[] getChangeListeners()

  Description copied from interface: `ChangeEventSupport`
  Returns an array of all the `ChangeListener`s added with addChangeListener().

  Specified by:
    `getChangeListeners` in interface `ChangeEventSupport`
  Returns:
    all of the `ChangeListener`s added or an empty array if no listeners have been added

### fireStateChanged

    public void fireStateChanged()

  Notifies all listeners that have registered interest for notification on this event type. The event instance is lazily created. The primary listeners will be views that need to be repainted because of changes in this model instance

  Specified by:
    `fireStateChanged` in interface `ChangeEventSupport`
  See Also:
    `EventListenerList`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD