goog.labs.observe
Namespacegoog.labs.observe.Notice
ClassA notice object encapsulates information about a notification fired by an observable. … more
goog.labs.observe.Observable
InterfaceInterface for an observable object. @interface … more
goog.labs.observe.ObservableSet
ClassCreates a set of observables. An ObservableSet is a collection of observables. Observers may be reigstered and will receive notifications when any of the observables notify. This class is meant to simplify management of observations on multiple observables of the same nature. … more
goog.labs.observe.ObservationSet
ClassA set of observations. An observation is defined by an observable and an observer. The set keeps track of observations and allows their removal. … more
goog.labs.observe.Observer
InterfaceA class implementing {@code Observer} may be informed of changes in observable object. … more
goog.labs.observe.SimpleObservable
ClassA simple implementation of {@code goog.labs.observe.Observable} that can be used as a standalone observable or as a base class for other observable object. When another class wants to implement observable without extending {@code SimpleObservable}, they can create an instance of {@code SimpleObservable}, specifying {@code opt_actualObservable}, and delegate to the instance. Here is a trivial example:
ClassA = function() { goog.base(this); this.observable_ = new SimpleObservable(this); this.registerDisposable(this.observable_); }; goog.inherits(ClassA, goog.Disposable); ClassA.prototype.observe = function(observer) { this.observable_.observe(observer); }; ClassA.prototype.unobserve = function(observer) { this.observable_.unobserve(observer); }; ClassA.prototype.notify = function(opt_data) { this.observable_.notify(opt_data); };… more