Class: kb.TriggeredObservable

Defined in: src/triggering/triggered-observable.coffee

Instance Method Summary

Constructor Details

# (ko.observable) constructor(emitter, event_selector)

Note: the constructor does not return 'this' but a ko.observable

Used to create a new kb.Observable.

Parameters:

  • emitter ( Model ) the emitter to observe (can be null)
  • event_selector ( String ) the event name to trigger Knockout subscriptions on.

Returns:

  • ( ko.observable ) — the constructor does not return 'this' but a ko.observable

Instance Method Details

# (void) destroy()

Required clean up function to break cycles, release view models, etc. Can be called directly, via kb.release(object) or as a consequence of ko.releaseNode(element).

~ (Model|ModelRef|Collection) emitter()
~ (void) emitter(new_emitter)

Dual-purpose getter/setter for the observed emitter.

Overloads:

~ (Model|ModelRef|Collection) emitter()

Gets the emitter or emitter reference

Returns:

  • ( Model|ModelRef|Collection ) — the emitter whose events are being bound (can be null)

~ (void) emitter(new_emitter)

Sets the emitter or emitter reference

Parameters:

  • new_emitter ( Model|ModelRef|Collection ) the emitter whose events will be bound (can be null)

    Quickly fuzzy find classes, mixins, methods, file:

    Control the navigation frame:

    You can focus and blur the search input: