Index (Frames) | Index (No Frames) | Package | Package Tree | Tree
javax.swing.event

Class EventListenerList

java.lang.Object
|
+--javax.swing.event.EventListenerList

All Implemented Interfaces:

Serializable


public class EventListenerList

extends Object

implements Serializable

EventListenerList

Author:

Field Summary

java.lang.Object[]listenerList

Listener list

Constructor Summary

EventListenerList()

EventListenerList constructor

Method Summary

voidadd(java.lang.Class t, java.util.EventListener listener)

Add Listener
intgetListenerCount()

Get the total number of listeners
intgetListenerCount(java.lang.Class t)

Get the number of listeners of a particular type
java.lang.Object[]getListenerList()

Get a list of listenerType/listener pairs
java.util.EventListener[]getListeners(java.lang.Class c)

Get list of listeners of a particular type
voidremove(java.lang.Class t, java.util.EventListener listener)

Remove a listener
java.lang.StringtoString()

Get a string representation

Field Details

listenerList

protected Object[] listenerList

Listener list


Constructor Details

EventListenerList

public EventListenerList()

EventListenerList constructor


Method Details

add

public void add(java.lang.Class t, java.util.EventListener listener)

Add Listener

Parameters:


getListenerCount

public int getListenerCount()

Get the total number of listeners

Returns:


getListenerCount

public int getListenerCount(java.lang.Class t)

Get the number of listeners of a particular type

Parameters:


getListenerList

public Object[] getListenerList()

Get a list of listenerType/listener pairs


getListeners

public EventListener[] getListeners(java.lang.Class c)

Get list of listeners of a particular type

Parameters:


remove

public void remove(java.lang.Class t, java.util.EventListener listener)

Remove a listener

Parameters:


toString

public String toString()

Get a string representation