RemovableEventDispatcher
| Kind of class: | public class |
|---|---|
| Package: | org.casalib.events |
| Inherits from: | EventDispatcher |
| Implements: | |
| Known subclasses: | |
| Version: | 12/11/08 |
| Author: | Aaron Clinger |
| Classpath: | org.casalib.events.RemovableEventDispatcher |
| File last modified: | Thursday, 19 February 2009, 11:33:36 |
Extends
EventDispatcher to allow for simple and quick removal of event listeners.Summary
Constructor
- RemovableEventDispatcher (target:IEventDispatcher = null)
- Creates a new RemovableEventDispatcher.
Instance properties
- destroyed : Boolean
Instance methods
- removeEventsForType (type:String) : void
- Removes all events of a specific type.
- removeEventsForListener (listener:Function) : void
- Removes all events that report to the specified listener.
- removeEventListeners : void
- Removes all event listeners.
- destroy : void
- Removes any event listeners and stops all internal processes to help allow for prompt garbage collection.
- destroy : void
Constructor
RemovableEventDispatcher
public function RemovableEventDispatcher (target:IEventDispatcher = null)Creates a new RemovableEventDispatcher.Parameters:target:The target object for events dispatched to the EventDispatcher object.Instance properties
destroyed
public destroyed:Boolean(read)Instance methods
destroy
public function destroy () : voidRemoves any event listeners and stops all internal processes to help allow for prompt garbage collection.#
Always callEventDispatcherbefore deleting last object pointer.Specified by:removeEventListeners
public function removeEventListeners () : voidRemoves all event listeners.#Specified by:removeEventsForListener
public function removeEventsForListener (listener:Function) : voidRemoves all events that report to the specified listener.#Parameters:listener:The listener function that processes the event.#Specified by: - removeEventListeners : void
- removeEventsForListener (listener:Function) : void