MCPcopy Create free account

hub / github.com/chuckpreslar/emission / functions

Functions23 in github.com/chuckpreslar/emission

↓ 11 callersMethodAddListener
AddListener appends the listener argument to the event arguments slice in the Emitter's events map. If the number of listeners for an event is greater
emitter.go:41
↓ 11 callersFunctionNewEmitter
NewEmitter returns a new Emitter object, defaulting the number of maximum listeners per event to the DefaultMaxListeners constant and initializing its
emitter.go:307
↓ 6 callersMethodEmit
Emit attempts to use the reflect package to Call each listener stored in the Emitter's events map with the supplied arguments. Each listener is called
emitter.go:157
↓ 6 callersMethodRemoveListener
RemoveListener removes the listener argument from the event arguments slice in the Emitter's events map. If the reflect Value of the listener does no
emitter.go:74
↓ 3 callersMethodGetListenerCount
GetListenerCount gets count of listeners for a given event.
emitter.go:295
↓ 2 callersMethodOn
On is an alias for AddListener.
emitter.go:66
↓ 2 callersMethodOnce
Once generates a new function which invokes the supplied listener only once before removing itself from the event's listener slice in the Emitter's ev
emitter.go:117
↓ 1 callersMethodEmitSync
EmitSync attempts to use the reflect package to Call each listener stored in the Emitter's events map with the supplied arguments. Each listener is ca
emitter.go:223
↓ 1 callersMethodRecoverWith
RecoverWith sets the listener to call when a panic occurs, recovering from panics and attempting to keep the application from crashing.
emitter.go:276
MethodOff
Off is an alias for RemoveListener.
emitter.go:108
MethodReceiver
(evt string)
emitter_test.go:135
MethodSetMaxListeners
SetMaxListeners sets the maximum number of listeners per event for the Emitter. If -1 is passed as the maximum, all events may have unlimited listener
emitter.go:286
FunctionTestAddListener
(t *testing.T)
emitter_test.go:7
FunctionTestCountListener
(t *testing.T)
emitter_test.go:118
FunctionTestEmit
(t *testing.T)
emitter_test.go:18
FunctionTestEmitSync
(t *testing.T)
emitter_test.go:31
FunctionTestEmitWithMultipleListeners
(t *testing.T)
emitter_test.go:44
FunctionTestOnce
(t *testing.T)
emitter_test.go:75
FunctionTestRecoveryWith
(t *testing.T)
emitter_test.go:89
FunctionTestRemoveDoubleListener
(t *testing.T)
emitter_test.go:148
FunctionTestRemoveListener
(t *testing.T)
emitter_test.go:62
FunctionTestRemoveOnce
(t *testing.T)
emitter_test.go:103
FunctionTestRemoveStructMethod
(t *testing.T)
emitter_test.go:137