Class: kb.EventWatcher
Defined in: | src/core/event-watcher.coffee |
Overview
Used to provide a central place to aggregate registered Model events rather than having all kb.Observables register for updates independently.
Class Method Summary
- . (void) useOptionsOrCreate(options, emitter, obj, callback_options) Used to either register yourself with the existing emitter watcher or to create a new one.
Instance Method Summary
- # (void) destroy() Required clean up function to break cycles, release view emitters, etc.
- ~ (Model|ModelRef) emitter() Dual-purpose getter/setter for the observed emitter.
- # (void) registerCallbacks(obj, callback_info) Used to register callbacks for an emitter.
- # (void) releaseCallbacks(obj)
Class Method Details
.
(void)
useOptionsOrCreate(options, emitter, obj, callback_options)
Used to either register yourself with the existing emitter watcher or to create a new one.
Constructor Details
#
(void)
constructor(emitter, obj, callback_options)
Instance Method Details
#
(void)
destroy()
Required clean up function to break cycles, release view emitters, etc. Can be called directly, via kb.release(object) or as a consequence of ko.releaseNode(element).
~
(Model|ModelRef)
emitter()
~
(void)
emitter(new_emitter)
Dual-purpose getter/setter for the observed emitter.
#
(void)
registerCallbacks(obj, callback_info)
Used to register callbacks for an emitter.
#
(void)
releaseCallbacks(obj)