Event

From Web Computing Documentation
(Difference between revisions)
Jump to: navigation, search
 
Line 4: Line 4:
   
 
*henkolib
 
*henkolib
**henkolib.event
+
**henkolib.events
***[[Event|henkolib.event.Event]]
+
***[[Event|henkolib.events.Event]]
   
 
==Class overview==
 
==Class overview==

Latest revision as of 13:21, 16 August 2011

class Event <T> implements PublicEvent<T>

  • henkolib
    • henkolib.events
      • henkolib.events.Event

[edit] Class overview

Represents an Event with customizable arguments. Should be kept private in the class that invokes it. Use the PublicSimpleEvent interface for publishing the event.

[edit] Public functions

new ()

subscribe (func : T->Void)

func Callback function.

Subscribes the given callback function to the Event.

unsubscribe (func : T->Void)

func Callback function.

Unsubscribes the given callback function to the Event.

invoke (arg : T)

arg The object to pass to callback functions.

Invokes the Event by calling all subscribed callback functions with the given parameter.

Personal tools
Modules