Package org.apache.batik.dom.events
Class EventListenerList
java.lang.Object
org.apache.batik.dom.events.EventListenerList
Class to manager event listeners for one event type.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
EventListenerTable entry class. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected IntTable
Counts of listener entries with a given namespace URI.protected EventListenerList.Entry
Linked list of entries.protected EventListenerList.Entry[]
Cache of listeners with any namespace URI.protected HashMap
Caches of listeners with a given namespace URI.protected int
Total number of event listners. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addListener
(String namespaceURI, Object group, EventListener listener) Adds a listener.Returns an array containing all event listener entries.getEventListeners
(String namespaceURI) Returns an array of EventListeners that match the given namespace URI.boolean
hasEventListener
(String namespaceURI) Returns whether there is an event listener for the given namespace URI.void
removeListener
(String namespaceURI, EventListener listener) Removes a listener.int
size()
Returns the number of event listeners stored in this object.
-
Field Details
-
n
protected int nTotal number of event listners. -
head
Linked list of entries. -
counts
Counts of listener entries with a given namespace URI. -
listeners
Cache of listeners with any namespace URI. -
listenersNS
Caches of listeners with a given namespace URI.
-
-
Constructor Details
-
EventListenerList
public EventListenerList()
-
-
Method Details
-
addListener
Adds a listener. -
removeListener
Removes a listener. -
getEventListeners
Returns an array containing all event listener entries. -
getEventListeners
Returns an array of EventListeners that match the given namespace URI. -
hasEventListener
Returns whether there is an event listener for the given namespace URI. -
size
public int size()Returns the number of event listeners stored in this object.
-