rxjs-rails 2.2.20 → 2.2.26

Sign up to get free protection for your applications and to get access to all the features.
Files changed (40) hide show
  1. checksums.yaml +4 -4
  2. data/lib/rxjs/rails/version.rb +1 -1
  3. data/vendor/assets/javascripts/rx.aggregates.js +38 -20
  4. data/vendor/assets/javascripts/rx.aggregates.min.js +1 -1
  5. data/vendor/assets/javascripts/rx.all.compat.js +9288 -0
  6. data/vendor/assets/javascripts/rx.all.compat.min.js +3 -0
  7. data/vendor/assets/javascripts/rx.all.js +9102 -0
  8. data/vendor/assets/javascripts/rx.all.min.js +3 -0
  9. data/vendor/assets/javascripts/rx.async.compat.js +5 -4
  10. data/vendor/assets/javascripts/rx.async.compat.min.js +1 -1
  11. data/vendor/assets/javascripts/rx.async.js +5 -4
  12. data/vendor/assets/javascripts/rx.async.min.js +1 -1
  13. data/vendor/assets/javascripts/rx.backpressure.js +24 -12
  14. data/vendor/assets/javascripts/rx.backpressure.min.js +1 -1
  15. data/vendor/assets/javascripts/rx.binding.js +85 -85
  16. data/vendor/assets/javascripts/rx.coincidence.js +59 -15
  17. data/vendor/assets/javascripts/rx.coincidence.min.js +1 -1
  18. data/vendor/assets/javascripts/rx.compat.js +809 -742
  19. data/vendor/assets/javascripts/rx.compat.min.js +2 -2
  20. data/vendor/assets/javascripts/rx.core.compat.js +2629 -0
  21. data/vendor/assets/javascripts/rx.core.compat.min.js +1 -0
  22. data/vendor/assets/javascripts/rx.core.js +2511 -0
  23. data/vendor/assets/javascripts/rx.core.min.js +1 -0
  24. data/vendor/assets/javascripts/rx.experimental.js +43 -43
  25. data/vendor/assets/javascripts/rx.joinpatterns.js +281 -281
  26. data/vendor/assets/javascripts/rx.js +792 -725
  27. data/vendor/assets/javascripts/rx.lite.compat.js +890 -758
  28. data/vendor/assets/javascripts/rx.lite.compat.min.js +2 -2
  29. data/vendor/assets/javascripts/rx.lite.extras.js +664 -0
  30. data/vendor/assets/javascripts/rx.lite.extras.min.js +1 -0
  31. data/vendor/assets/javascripts/rx.lite.js +890 -758
  32. data/vendor/assets/javascripts/rx.lite.min.js +2 -2
  33. data/vendor/assets/javascripts/rx.min.js +2 -2
  34. data/vendor/assets/javascripts/rx.testing.js +166 -166
  35. data/vendor/assets/javascripts/rx.testing.min.js +1 -1
  36. data/vendor/assets/javascripts/rx.time.js +132 -131
  37. data/vendor/assets/javascripts/rx.time.min.js +1 -1
  38. data/vendor/assets/javascripts/rx.virtualtime.js +2 -2
  39. metadata +13 -4
  40. data/vendor/assets/javascripts/rx.node.js +0 -142
@@ -1,4 +1,4 @@
1
- // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information.
1
+ // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information.
2
2
 
3
3
  ;(function (factory) {
4
4
  var objectTypes = {
@@ -27,31 +27,31 @@
27
27
  return root.Rx;
28
28
  });
29
29
  } else if (typeof module === 'object' && module && module.exports === freeExports) {
30
- module.exports = factory(root, module.exports, require('./rx'));
30
+ module.exports = factory(root, module.exports, require('./rx.all'));
31
31
  } else {
32
32
  root.Rx = factory(root, {}, root.Rx);
33
33
  }
34
34
  }.call(this, function (root, exp, Rx, undefined) {
35
35
 
36
- // Defaults
37
- var Observer = Rx.Observer,
38
- Observable = Rx.Observable,
39
- Notification = Rx.Notification,
40
- VirtualTimeScheduler = Rx.VirtualTimeScheduler,
41
- Disposable = Rx.Disposable,
42
- disposableEmpty = Disposable.empty,
43
- disposableCreate = Disposable.create,
44
- CompositeDisposable = Rx.CompositeDisposable,
45
- SingleAssignmentDisposable = Rx.SingleAssignmentDisposable,
46
- slice = Array.prototype.slice,
47
- inherits = Rx.internals.inherits,
48
- defaultComparer = Rx.internals.isEqual;
49
-
50
- function argsOrArray(args, idx) {
51
- return args.length === 1 && Array.isArray(args[idx]) ?
52
- args[idx] :
53
- slice.call(args);
54
- }
36
+ // Defaults
37
+ var Observer = Rx.Observer,
38
+ Observable = Rx.Observable,
39
+ Notification = Rx.Notification,
40
+ VirtualTimeScheduler = Rx.VirtualTimeScheduler,
41
+ Disposable = Rx.Disposable,
42
+ disposableEmpty = Disposable.empty,
43
+ disposableCreate = Disposable.create,
44
+ CompositeDisposable = Rx.CompositeDisposable,
45
+ SingleAssignmentDisposable = Rx.SingleAssignmentDisposable,
46
+ slice = Array.prototype.slice,
47
+ inherits = Rx.internals.inherits,
48
+ defaultComparer = Rx.internals.isEqual;
49
+
50
+ function argsOrArray(args, idx) {
51
+ return args.length === 1 && Array.isArray(args[idx]) ?
52
+ args[idx] :
53
+ slice.call(args);
54
+ }
55
55
 
56
56
  /**
57
57
  * @private
@@ -218,150 +218,150 @@
218
218
  return '(' + this.subscribe + ', ' + this.unsubscribe === Number.MAX_VALUE ? 'Infinite' : this.unsubscribe + ')';
219
219
  };
220
220
 
221
- /** @private */
222
- var MockDisposable = Rx.MockDisposable = function (scheduler) {
223
- this.scheduler = scheduler;
224
- this.disposes = [];
225
- this.disposes.push(this.scheduler.clock);
226
- };
227
-
228
- /*
229
- * @memberOf MockDisposable#
230
- * @prviate
231
- */
232
- MockDisposable.prototype.dispose = function () {
233
- this.disposes.push(this.scheduler.clock);
234
- };
235
-
236
- /** @private */
237
- var MockObserver = (function (_super) {
238
- inherits(MockObserver, _super);
239
-
240
- /*
241
- * @constructor
242
- * @prviate
243
- */
244
- function MockObserver(scheduler) {
245
- _super.call(this);
246
- this.scheduler = scheduler;
247
- this.messages = [];
248
- }
249
-
250
- var MockObserverPrototype = MockObserver.prototype;
251
-
252
- /*
253
- * @memberOf MockObserverPrototype#
254
- * @prviate
255
- */
256
- MockObserverPrototype.onNext = function (value) {
257
- this.messages.push(new Recorded(this.scheduler.clock, Notification.createOnNext(value)));
258
- };
259
-
260
- /*
261
- * @memberOf MockObserverPrototype#
262
- * @prviate
263
- */
264
- MockObserverPrototype.onError = function (exception) {
265
- this.messages.push(new Recorded(this.scheduler.clock, Notification.createOnError(exception)));
266
- };
267
-
268
- /*
269
- * @memberOf MockObserverPrototype#
270
- * @prviate
271
- */
272
- MockObserverPrototype.onCompleted = function () {
273
- this.messages.push(new Recorded(this.scheduler.clock, Notification.createOnCompleted()));
274
- };
275
-
276
- return MockObserver;
277
- })(Observer);
278
-
279
- /** @private */
280
- var HotObservable = (function (_super) {
281
-
282
- function subscribe(observer) {
283
- var observable = this;
284
- this.observers.push(observer);
285
- this.subscriptions.push(new Subscription(this.scheduler.clock));
286
- var index = this.subscriptions.length - 1;
287
- return disposableCreate(function () {
288
- var idx = observable.observers.indexOf(observer);
289
- observable.observers.splice(idx, 1);
290
- observable.subscriptions[index] = new Subscription(observable.subscriptions[index].subscribe, observable.scheduler.clock);
291
- });
292
- }
293
-
294
- inherits(HotObservable, _super);
295
-
296
- /**
297
- * @private
298
- * @constructor
299
- */
300
- function HotObservable(scheduler, messages) {
301
- _super.call(this, subscribe);
302
- var message, notification, observable = this;
303
- this.scheduler = scheduler;
304
- this.messages = messages;
305
- this.subscriptions = [];
306
- this.observers = [];
307
- for (var i = 0, len = this.messages.length; i < len; i++) {
308
- message = this.messages[i];
309
- notification = message.value;
310
- (function (innerNotification) {
311
- scheduler.scheduleAbsoluteWithState(null, message.time, function () {
312
- var obs = observable.observers.slice(0);
313
-
314
- for (var j = 0, jLen = obs.length; j < jLen; j++) {
315
- innerNotification.accept(obs[j]);
316
- }
317
- return disposableEmpty;
318
- });
319
- })(notification);
320
- }
321
- }
322
-
323
- return HotObservable;
324
- })(Observable);
325
-
326
- /** @private */
327
- var ColdObservable = (function (_super) {
328
-
329
- function subscribe(observer) {
330
- var message, notification, observable = this;
331
- this.subscriptions.push(new Subscription(this.scheduler.clock));
332
- var index = this.subscriptions.length - 1;
333
- var d = new CompositeDisposable();
334
- for (var i = 0, len = this.messages.length; i < len; i++) {
335
- message = this.messages[i];
336
- notification = message.value;
337
- (function (innerNotification) {
338
- d.add(observable.scheduler.scheduleRelativeWithState(null, message.time, function () {
339
- innerNotification.accept(observer);
340
- return disposableEmpty;
341
- }));
342
- })(notification);
343
- }
344
- return disposableCreate(function () {
345
- observable.subscriptions[index] = new Subscription(observable.subscriptions[index].subscribe, observable.scheduler.clock);
346
- d.dispose();
347
- });
348
- }
349
-
350
- inherits(ColdObservable, _super);
351
-
352
- /**
353
- * @private
354
- * @constructor
355
- */
356
- function ColdObservable(scheduler, messages) {
357
- _super.call(this, subscribe);
358
- this.scheduler = scheduler;
359
- this.messages = messages;
360
- this.subscriptions = [];
361
- }
362
-
363
- return ColdObservable;
364
- })(Observable);
221
+ /** @private */
222
+ var MockDisposable = Rx.MockDisposable = function (scheduler) {
223
+ this.scheduler = scheduler;
224
+ this.disposes = [];
225
+ this.disposes.push(this.scheduler.clock);
226
+ };
227
+
228
+ /*
229
+ * @memberOf MockDisposable#
230
+ * @prviate
231
+ */
232
+ MockDisposable.prototype.dispose = function () {
233
+ this.disposes.push(this.scheduler.clock);
234
+ };
235
+
236
+ /** @private */
237
+ var MockObserver = (function (_super) {
238
+ inherits(MockObserver, _super);
239
+
240
+ /*
241
+ * @constructor
242
+ * @prviate
243
+ */
244
+ function MockObserver(scheduler) {
245
+ _super.call(this);
246
+ this.scheduler = scheduler;
247
+ this.messages = [];
248
+ }
249
+
250
+ var MockObserverPrototype = MockObserver.prototype;
251
+
252
+ /*
253
+ * @memberOf MockObserverPrototype#
254
+ * @prviate
255
+ */
256
+ MockObserverPrototype.onNext = function (value) {
257
+ this.messages.push(new Recorded(this.scheduler.clock, Notification.createOnNext(value)));
258
+ };
259
+
260
+ /*
261
+ * @memberOf MockObserverPrototype#
262
+ * @prviate
263
+ */
264
+ MockObserverPrototype.onError = function (exception) {
265
+ this.messages.push(new Recorded(this.scheduler.clock, Notification.createOnError(exception)));
266
+ };
267
+
268
+ /*
269
+ * @memberOf MockObserverPrototype#
270
+ * @prviate
271
+ */
272
+ MockObserverPrototype.onCompleted = function () {
273
+ this.messages.push(new Recorded(this.scheduler.clock, Notification.createOnCompleted()));
274
+ };
275
+
276
+ return MockObserver;
277
+ })(Observer);
278
+
279
+ /** @private */
280
+ var HotObservable = (function (_super) {
281
+
282
+ function subscribe(observer) {
283
+ var observable = this;
284
+ this.observers.push(observer);
285
+ this.subscriptions.push(new Subscription(this.scheduler.clock));
286
+ var index = this.subscriptions.length - 1;
287
+ return disposableCreate(function () {
288
+ var idx = observable.observers.indexOf(observer);
289
+ observable.observers.splice(idx, 1);
290
+ observable.subscriptions[index] = new Subscription(observable.subscriptions[index].subscribe, observable.scheduler.clock);
291
+ });
292
+ }
293
+
294
+ inherits(HotObservable, _super);
295
+
296
+ /**
297
+ * @private
298
+ * @constructor
299
+ */
300
+ function HotObservable(scheduler, messages) {
301
+ _super.call(this, subscribe);
302
+ var message, notification, observable = this;
303
+ this.scheduler = scheduler;
304
+ this.messages = messages;
305
+ this.subscriptions = [];
306
+ this.observers = [];
307
+ for (var i = 0, len = this.messages.length; i < len; i++) {
308
+ message = this.messages[i];
309
+ notification = message.value;
310
+ (function (innerNotification) {
311
+ scheduler.scheduleAbsoluteWithState(null, message.time, function () {
312
+ var obs = observable.observers.slice(0);
313
+
314
+ for (var j = 0, jLen = obs.length; j < jLen; j++) {
315
+ innerNotification.accept(obs[j]);
316
+ }
317
+ return disposableEmpty;
318
+ });
319
+ })(notification);
320
+ }
321
+ }
322
+
323
+ return HotObservable;
324
+ })(Observable);
325
+
326
+ /** @private */
327
+ var ColdObservable = (function (_super) {
328
+
329
+ function subscribe(observer) {
330
+ var message, notification, observable = this;
331
+ this.subscriptions.push(new Subscription(this.scheduler.clock));
332
+ var index = this.subscriptions.length - 1;
333
+ var d = new CompositeDisposable();
334
+ for (var i = 0, len = this.messages.length; i < len; i++) {
335
+ message = this.messages[i];
336
+ notification = message.value;
337
+ (function (innerNotification) {
338
+ d.add(observable.scheduler.scheduleRelativeWithState(null, message.time, function () {
339
+ innerNotification.accept(observer);
340
+ return disposableEmpty;
341
+ }));
342
+ })(notification);
343
+ }
344
+ return disposableCreate(function () {
345
+ observable.subscriptions[index] = new Subscription(observable.subscriptions[index].subscribe, observable.scheduler.clock);
346
+ d.dispose();
347
+ });
348
+ }
349
+
350
+ inherits(ColdObservable, _super);
351
+
352
+ /**
353
+ * @private
354
+ * @constructor
355
+ */
356
+ function ColdObservable(scheduler, messages) {
357
+ _super.call(this, subscribe);
358
+ this.scheduler = scheduler;
359
+ this.messages = messages;
360
+ this.subscriptions = [];
361
+ }
362
+
363
+ return ColdObservable;
364
+ })(Observable);
365
365
 
366
366
  /** Virtual time scheduler used for testing applications and libraries built using Reactive Extensions. */
367
367
  Rx.TestScheduler = (function (_super) {
@@ -496,5 +496,5 @@
496
496
  return TestScheduler;
497
497
  })(VirtualTimeScheduler);
498
498
 
499
- return Rx;
499
+ return Rx;
500
500
  }));
@@ -1 +1 @@
1
- (function(a){var b={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,undefined:!1},c=b[typeof window]&&window||this,d=b[typeof exports]&&exports&&!exports.nodeType&&exports,e=b[typeof module]&&module&&!module.nodeType&&module,f=(e&&e.exports===d&&d,b[typeof global]&&global);!f||f.global!==f&&f.window!==f||(c=f),"function"==typeof define&&define.amd?define(["rx.virtualtime","exports"],function(b,d){return c.Rx=a(c,d,b),c.Rx}):"object"==typeof module&&module&&module.exports===d?module.exports=a(c,module.exports,require("./rx")):c.Rx=a(c,{},c.Rx)}).call(this,function(a,b,c){function d(a,b){return 1===a.length&&Array.isArray(a[b])?a[b]:o.call(a)}function e(a){this.predicate=a}function f(a){this.predicate=a}var g=c.Observer,h=c.Observable,i=c.Notification,j=c.VirtualTimeScheduler,k=c.Disposable,l=k.empty,m=k.create,n=c.CompositeDisposable,o=(c.SingleAssignmentDisposable,Array.prototype.slice),p=c.internals.inherits,q=c.internals.isEqual;e.prototype.equals=function(a){return a===this?!0:null==a?!1:"N"!==a.kind?!1:this.predicate(a.value)},f.prototype.equals=function(a){return a===this?!0:null==a?!1:"E"!==a.kind?!1:this.predicate(a.exception)};var r=c.ReactiveTest={created:100,subscribed:200,disposed:1e3,onNext:function(a,b){return"function"==typeof b?new s(a,new e(b)):new s(a,i.createOnNext(b))},onError:function(a,b){return"function"==typeof b?new s(a,new f(b)):new s(a,i.createOnError(b))},onCompleted:function(a){return new s(a,i.createOnCompleted())},subscribe:function(a,b){return new t(a,b)}},s=c.Recorded=function(a,b,c){this.time=a,this.value=b,this.comparer=c||q};s.prototype.equals=function(a){return this.time===a.time&&this.comparer(this.value,a.value)},s.prototype.toString=function(){return this.value.toString()+"@"+this.time};var t=c.Subscription=function(a,b){this.subscribe=a,this.unsubscribe=b||Number.MAX_VALUE};t.prototype.equals=function(a){return this.subscribe===a.subscribe&&this.unsubscribe===a.unsubscribe},t.prototype.toString=function(){return"("+this.subscribe+", "+this.unsubscribe===Number.MAX_VALUE?"Infinite":this.unsubscribe+")"};var u=c.MockDisposable=function(a){this.scheduler=a,this.disposes=[],this.disposes.push(this.scheduler.clock)};u.prototype.dispose=function(){this.disposes.push(this.scheduler.clock)};var v=function(a){function b(b){a.call(this),this.scheduler=b,this.messages=[]}p(b,a);var c=b.prototype;return c.onNext=function(a){this.messages.push(new s(this.scheduler.clock,i.createOnNext(a)))},c.onError=function(a){this.messages.push(new s(this.scheduler.clock,i.createOnError(a)))},c.onCompleted=function(){this.messages.push(new s(this.scheduler.clock,i.createOnCompleted()))},b}(g),w=function(a){function b(a){var b=this;this.observers.push(a),this.subscriptions.push(new t(this.scheduler.clock));var c=this.subscriptions.length-1;return m(function(){var d=b.observers.indexOf(a);b.observers.splice(d,1),b.subscriptions[c]=new t(b.subscriptions[c].subscribe,b.scheduler.clock)})}function c(c,d){a.call(this,b);var e,f,g=this;this.scheduler=c,this.messages=d,this.subscriptions=[],this.observers=[];for(var h=0,i=this.messages.length;i>h;h++)e=this.messages[h],f=e.value,function(a){c.scheduleAbsoluteWithState(null,e.time,function(){for(var b=g.observers.slice(0),c=0,d=b.length;d>c;c++)a.accept(b[c]);return l})}(f)}return p(c,a),c}(h),x=function(a){function b(a){var b,c,d=this;this.subscriptions.push(new t(this.scheduler.clock));for(var e=this.subscriptions.length-1,f=new n,g=0,h=this.messages.length;h>g;g++)b=this.messages[g],c=b.value,function(c){f.add(d.scheduler.scheduleRelativeWithState(null,b.time,function(){return c.accept(a),l}))}(c);return m(function(){d.subscriptions[e]=new t(d.subscriptions[e].subscribe,d.scheduler.clock),f.dispose()})}function c(c,d){a.call(this,b),this.scheduler=c,this.messages=d,this.subscriptions=[]}return p(c,a),c}(h);return c.TestScheduler=function(a){function b(a,b){return a>b?1:b>a?-1:0}function c(){a.call(this,0,b)}return p(c,a),c.prototype.scheduleAbsoluteWithState=function(b,c,d){return c<=this.clock&&(c=this.clock+1),a.prototype.scheduleAbsoluteWithState.call(this,b,c,d)},c.prototype.add=function(a,b){return a+b},c.prototype.toDateTimeOffset=function(a){return new Date(a).getTime()},c.prototype.toRelative=function(a){return a},c.prototype.startWithTiming=function(a,b,c,d){var e,f,g=this.createObserver();return this.scheduleAbsoluteWithState(null,b,function(){return e=a(),l}),this.scheduleAbsoluteWithState(null,c,function(){return f=e.subscribe(g),l}),this.scheduleAbsoluteWithState(null,d,function(){return f.dispose(),l}),this.start(),g},c.prototype.startWithDispose=function(a,b){return this.startWithTiming(a,r.created,r.subscribed,b)},c.prototype.startWithCreate=function(a){return this.startWithTiming(a,r.created,r.subscribed,r.disposed)},c.prototype.createHotObservable=function(){var a=d(arguments,0);return new w(this,a)},c.prototype.createColdObservable=function(){var a=d(arguments,0);return new x(this,a)},c.prototype.createObserver=function(){return new v(this)},c}(j),c});
1
+ (function(a){var b={"boolean":!1,"function":!0,object:!0,number:!1,string:!1,undefined:!1},c=b[typeof window]&&window||this,d=b[typeof exports]&&exports&&!exports.nodeType&&exports,e=b[typeof module]&&module&&!module.nodeType&&module,f=(e&&e.exports===d&&d,b[typeof global]&&global);!f||f.global!==f&&f.window!==f||(c=f),"function"==typeof define&&define.amd?define(["rx.virtualtime","exports"],function(b,d){return c.Rx=a(c,d,b),c.Rx}):"object"==typeof module&&module&&module.exports===d?module.exports=a(c,module.exports,require("./rx.all")):c.Rx=a(c,{},c.Rx)}).call(this,function(a,b,c){function d(a,b){return 1===a.length&&Array.isArray(a[b])?a[b]:o.call(a)}function e(a){this.predicate=a}function f(a){this.predicate=a}var g=c.Observer,h=c.Observable,i=c.Notification,j=c.VirtualTimeScheduler,k=c.Disposable,l=k.empty,m=k.create,n=c.CompositeDisposable,o=(c.SingleAssignmentDisposable,Array.prototype.slice),p=c.internals.inherits,q=c.internals.isEqual;e.prototype.equals=function(a){return a===this?!0:null==a?!1:"N"!==a.kind?!1:this.predicate(a.value)},f.prototype.equals=function(a){return a===this?!0:null==a?!1:"E"!==a.kind?!1:this.predicate(a.exception)};var r=c.ReactiveTest={created:100,subscribed:200,disposed:1e3,onNext:function(a,b){return"function"==typeof b?new s(a,new e(b)):new s(a,i.createOnNext(b))},onError:function(a,b){return"function"==typeof b?new s(a,new f(b)):new s(a,i.createOnError(b))},onCompleted:function(a){return new s(a,i.createOnCompleted())},subscribe:function(a,b){return new t(a,b)}},s=c.Recorded=function(a,b,c){this.time=a,this.value=b,this.comparer=c||q};s.prototype.equals=function(a){return this.time===a.time&&this.comparer(this.value,a.value)},s.prototype.toString=function(){return this.value.toString()+"@"+this.time};var t=c.Subscription=function(a,b){this.subscribe=a,this.unsubscribe=b||Number.MAX_VALUE};t.prototype.equals=function(a){return this.subscribe===a.subscribe&&this.unsubscribe===a.unsubscribe},t.prototype.toString=function(){return"("+this.subscribe+", "+this.unsubscribe===Number.MAX_VALUE?"Infinite":this.unsubscribe+")"};var u=c.MockDisposable=function(a){this.scheduler=a,this.disposes=[],this.disposes.push(this.scheduler.clock)};u.prototype.dispose=function(){this.disposes.push(this.scheduler.clock)};var v=function(a){function b(b){a.call(this),this.scheduler=b,this.messages=[]}p(b,a);var c=b.prototype;return c.onNext=function(a){this.messages.push(new s(this.scheduler.clock,i.createOnNext(a)))},c.onError=function(a){this.messages.push(new s(this.scheduler.clock,i.createOnError(a)))},c.onCompleted=function(){this.messages.push(new s(this.scheduler.clock,i.createOnCompleted()))},b}(g),w=function(a){function b(a){var b=this;this.observers.push(a),this.subscriptions.push(new t(this.scheduler.clock));var c=this.subscriptions.length-1;return m(function(){var d=b.observers.indexOf(a);b.observers.splice(d,1),b.subscriptions[c]=new t(b.subscriptions[c].subscribe,b.scheduler.clock)})}function c(c,d){a.call(this,b);var e,f,g=this;this.scheduler=c,this.messages=d,this.subscriptions=[],this.observers=[];for(var h=0,i=this.messages.length;i>h;h++)e=this.messages[h],f=e.value,function(a){c.scheduleAbsoluteWithState(null,e.time,function(){for(var b=g.observers.slice(0),c=0,d=b.length;d>c;c++)a.accept(b[c]);return l})}(f)}return p(c,a),c}(h),x=function(a){function b(a){var b,c,d=this;this.subscriptions.push(new t(this.scheduler.clock));for(var e=this.subscriptions.length-1,f=new n,g=0,h=this.messages.length;h>g;g++)b=this.messages[g],c=b.value,function(c){f.add(d.scheduler.scheduleRelativeWithState(null,b.time,function(){return c.accept(a),l}))}(c);return m(function(){d.subscriptions[e]=new t(d.subscriptions[e].subscribe,d.scheduler.clock),f.dispose()})}function c(c,d){a.call(this,b),this.scheduler=c,this.messages=d,this.subscriptions=[]}return p(c,a),c}(h);return c.TestScheduler=function(a){function b(a,b){return a>b?1:b>a?-1:0}function c(){a.call(this,0,b)}return p(c,a),c.prototype.scheduleAbsoluteWithState=function(b,c,d){return c<=this.clock&&(c=this.clock+1),a.prototype.scheduleAbsoluteWithState.call(this,b,c,d)},c.prototype.add=function(a,b){return a+b},c.prototype.toDateTimeOffset=function(a){return new Date(a).getTime()},c.prototype.toRelative=function(a){return a},c.prototype.startWithTiming=function(a,b,c,d){var e,f,g=this.createObserver();return this.scheduleAbsoluteWithState(null,b,function(){return e=a(),l}),this.scheduleAbsoluteWithState(null,c,function(){return f=e.subscribe(g),l}),this.scheduleAbsoluteWithState(null,d,function(){return f.dispose(),l}),this.start(),g},c.prototype.startWithDispose=function(a,b){return this.startWithTiming(a,r.created,r.subscribed,b)},c.prototype.startWithCreate=function(a){return this.startWithTiming(a,r.created,r.subscribed,r.disposed)},c.prototype.createHotObservable=function(){var a=d(arguments,0);return new w(this,a)},c.prototype.createColdObservable=function(){var a=d(arguments,0);return new x(this,a)},c.prototype.createObserver=function(){return new v(this)},c}(j),c});