Click or drag to resize

GlobalEventsT Class

A manager of events that do not belong to any specific object but instead can be listened to by anyone and invoked by anyone. Useful for GameLoaded, MatchEnded and similar events. This uses EventT instances behind the scenes. This version is for events with args. See GlobalEvents if you don't need to send data with the events. Events are differentiated by an integer. You are expected to create constants to define your events.
Inheritance Hierarchy
SystemObject
  Archon.SwissArmyLib.EventsGlobalEventsT

Namespace:  Archon.SwissArmyLib.Events
Assembly:  Archon.SwissArmyLib (in Archon.SwissArmyLib.dll) Version: 1.0.0.0 (1.0.0.0)
Syntax
C#
public static class GlobalEvents<T>
Request Example View Source

Type Parameters

T

[Missing <typeparam name="T"/> documentation for "T:Archon.SwissArmyLib.Events.GlobalEvents`1"]

The GlobalEventsT type exposes the following members.

Methods
  NameDescription
Public methodStatic memberAddListener(Int32, IEventListenerT, Int32)
Adds a listener for an event.
Public methodStatic memberAddListener(Int32, ActionT, Int32)
Adds a listener for an event.
Public methodStatic memberClear
Clears all listeners for all events.
Public methodStatic memberClear(Int32)
Clears all listeners for a single event.
Public methodStatic memberInvoke
Invokes an event.
Public methodStatic memberRemoveListener(ActionT)
Removes the specified listener from all events.
Public methodStatic memberRemoveListener(IEventListenerT)
Removes the specified listener from all events.
Public methodStatic memberRemoveListener(Int32, IEventListenerT)
Removes a listener for an event.
Public methodStatic memberRemoveListener(Int32, ActionT)
Removes a listener for an event.
Top
See Also