rxjs-rails 2.5.2 → 3.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (72) hide show
  1. checksums.yaml +4 -4
  2. data/lib/rxjs/rails/version.rb +1 -1
  3. data/vendor/assets/javascripts/rx.aggregates.js +367 -284
  4. data/vendor/assets/javascripts/rx.aggregates.map +1 -1
  5. data/vendor/assets/javascripts/rx.aggregates.min.js +1 -1
  6. data/vendor/assets/javascripts/rx.all.compat.js +2405 -2438
  7. data/vendor/assets/javascripts/rx.all.compat.map +1 -1
  8. data/vendor/assets/javascripts/rx.all.compat.min.js +4 -4
  9. data/vendor/assets/javascripts/rx.all.js +2380 -2395
  10. data/vendor/assets/javascripts/rx.all.map +1 -1
  11. data/vendor/assets/javascripts/rx.all.min.js +4 -4
  12. data/vendor/assets/javascripts/rx.async.compat.js +311 -333
  13. data/vendor/assets/javascripts/rx.async.compat.map +1 -1
  14. data/vendor/assets/javascripts/rx.async.compat.min.js +1 -1
  15. data/vendor/assets/javascripts/rx.async.js +280 -327
  16. data/vendor/assets/javascripts/rx.async.map +1 -1
  17. data/vendor/assets/javascripts/rx.async.min.js +1 -1
  18. data/vendor/assets/javascripts/rx.backpressure.js +208 -176
  19. data/vendor/assets/javascripts/rx.backpressure.map +1 -1
  20. data/vendor/assets/javascripts/rx.backpressure.min.js +1 -1
  21. data/vendor/assets/javascripts/rx.binding.js +44 -27
  22. data/vendor/assets/javascripts/rx.binding.map +1 -1
  23. data/vendor/assets/javascripts/rx.binding.min.js +1 -1
  24. data/vendor/assets/javascripts/rx.coincidence.js +220 -453
  25. data/vendor/assets/javascripts/rx.coincidence.map +1 -1
  26. data/vendor/assets/javascripts/rx.coincidence.min.js +1 -1
  27. data/vendor/assets/javascripts/rx.compat.js +1366 -1173
  28. data/vendor/assets/javascripts/rx.compat.map +1 -1
  29. data/vendor/assets/javascripts/rx.compat.min.js +3 -2
  30. data/vendor/assets/javascripts/rx.core.binding.js +823 -0
  31. data/vendor/assets/javascripts/rx.core.binding.map +1 -0
  32. data/vendor/assets/javascripts/rx.core.binding.min.js +3 -0
  33. data/vendor/assets/javascripts/rx.core.js +1281 -0
  34. data/vendor/assets/javascripts/rx.core.map +1 -0
  35. data/vendor/assets/javascripts/rx.core.min.js +3 -0
  36. data/vendor/assets/javascripts/rx.core.testing.js +1242 -0
  37. data/vendor/assets/javascripts/rx.core.testing.map +1 -0
  38. data/vendor/assets/javascripts/rx.core.testing.min.js +3 -0
  39. data/vendor/assets/javascripts/rx.experimental.js +85 -123
  40. data/vendor/assets/javascripts/rx.experimental.map +1 -1
  41. data/vendor/assets/javascripts/rx.experimental.min.js +1 -1
  42. data/vendor/assets/javascripts/rx.joinpatterns.js +48 -37
  43. data/vendor/assets/javascripts/rx.joinpatterns.map +1 -1
  44. data/vendor/assets/javascripts/rx.joinpatterns.min.js +1 -1
  45. data/vendor/assets/javascripts/rx.js +1367 -1174
  46. data/vendor/assets/javascripts/rx.lite.compat.js +1621 -1403
  47. data/vendor/assets/javascripts/rx.lite.compat.map +1 -1
  48. data/vendor/assets/javascripts/rx.lite.compat.min.js +3 -3
  49. data/vendor/assets/javascripts/rx.lite.extras.compat.js +119 -89
  50. data/vendor/assets/javascripts/rx.lite.extras.compat.map +1 -1
  51. data/vendor/assets/javascripts/rx.lite.extras.compat.min.js +1 -1
  52. data/vendor/assets/javascripts/rx.lite.extras.js +119 -89
  53. data/vendor/assets/javascripts/rx.lite.extras.map +1 -1
  54. data/vendor/assets/javascripts/rx.lite.extras.min.js +1 -1
  55. data/vendor/assets/javascripts/rx.lite.js +1583 -1390
  56. data/vendor/assets/javascripts/rx.lite.map +1 -1
  57. data/vendor/assets/javascripts/rx.lite.min.js +3 -3
  58. data/vendor/assets/javascripts/rx.map +1 -1
  59. data/vendor/assets/javascripts/rx.min.js +3 -2
  60. data/vendor/assets/javascripts/rx.sorting.js +23 -27
  61. data/vendor/assets/javascripts/rx.sorting.map +1 -1
  62. data/vendor/assets/javascripts/rx.sorting.min.js +1 -1
  63. data/vendor/assets/javascripts/rx.testing.js +11 -15
  64. data/vendor/assets/javascripts/rx.testing.map +1 -1
  65. data/vendor/assets/javascripts/rx.testing.min.js +1 -1
  66. data/vendor/assets/javascripts/rx.time.js +117 -133
  67. data/vendor/assets/javascripts/rx.time.map +1 -1
  68. data/vendor/assets/javascripts/rx.time.min.js +1 -1
  69. data/vendor/assets/javascripts/rx.virtualtime.js +120 -39
  70. data/vendor/assets/javascripts/rx.virtualtime.map +1 -1
  71. data/vendor/assets/javascripts/rx.virtualtime.min.js +1 -1
  72. metadata +12 -3
@@ -1 +1 @@
1
- {"version":3,"file":"rx.async.min.js","sources":["rx.async.js"],"names":["factory","objectTypes","boolean","function","object","number","string","undefined","root","window","this","freeExports","exports","nodeType","freeModule","module","freeGlobal","global","define","amd","Rx","require","call","exp","toThunk","obj","ctx","Array","isArray","objectToThunk","isGeneratorFunction","observableSpawn","isGenerator","isObservable","observableToThunk","isPromise","promiseToThunk","fnString","isObject","done","run","fn","key","finished","results","pending","err","res","e","keys","Object","length","constructor","timeoutScheduler","schedule","i","len","observable","value","hasValue","subscribe","v","promise","then","name","next","throwString","handleError","createListener","element","handler","addEventListener","disposableCreate","removeEventListener","Error","createEventListener","el","eventName","disposables","CompositeDisposable","prototype","toString","add","item","Observable","observableFromPromise","fromPromise","observableThrow","throwError","AnonymousObservable","AsyncSubject","Disposable","create","Scheduler","immediate","isScheduler","slice","internals","spawn","isGenFun","exit","bind","ret","arguments","push","gen","TypeError","called","apply","args","hasCallback","pop","start","func","context","scheduler","observableToAsync","toAsync","subject","result","onError","onNext","onCompleted","asObservable","fromCallback","selector","observer","publishLast","refCount","fromNodeCallback","config","useNativeEvents","fromEvent","addListener","fromEventPattern","h","removeListener","on","off","publish","addHandler","removeHandler","innerHandler","returnValue","startAsync","functionAsync"],"mappings":";CAEE,SAAUA,GACR,GAAIC,IACAC,WAAW,EACXC,YAAY,EACZC,QAAU,EACVC,QAAU,EACVC,QAAU,EACVC,WAAa,GAGbC,EAAQP,QAAmBQ,UAAW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MAAIxD,GAAQgE,YACHC,EACL,SAAUC,GAAKlE,EAAQgE,YAAYxD,EAAW0D,IAC9C,SAAUA,GAAKlE,EAAQmE,eAAe3D,EAAW0D,IACjDV,GAICzG,EAAG8G,OAAOC,iBAEa,kBAAf9D,GAAQoE,IAA4C,kBAAhBpE,GAAQqE,IAOlD,GAAIjD,GAAoB,SAAUqC,GACvC,MAAOnD,GACLN,EACAQ,EACA,SAAkB7B,GAChB,GAAIJ,GAAUI,CAEd,IAAI6E,EACF,IACEjF,EAAUiF,EAAStB,WACnB,MAAOzD,GACP,MAAOgF,GAASN,QAAQ1E,GAI5BgF,EAASL,OAAO7E,OAEnB+F,UAAUX,WAvBFM,EACL,SAAUC,GAAKlE,EAAQoE,GAAG5D,EAAW0D,IACrC,SAAUA,GAAKlE,EAAQqE,IAAI7D,EAAW0D,IACtCV,GA8BR,IAAIS,GAAmBlD,EAAWkD,iBAAmB,SAAUM,EAAYC,EAAehB,GACxF,MAAO,IAAIpC,GAAoB,SAAUqC,GACvC,QAASgB,GAAc9F,GACrB,GAAIuE,GAASvE,CACb,IAAI6E,EACF,IACEN,EAASM,EAAStB,WAClB,MAAOzD,GACP,MAAOgF,GAASN,QAAQ1E,GAG5BgF,EAASL,OAAOF,GAGlB,GAAIwB,GAAcH,EAAWE,EAC7B,OAAOtE,GAAiB,WAClBqE,GACFA,EAAcC,EAAcC,OAG/BJ,UAAUX,WAkBb,OAVF5C,GAAW4D,WAAa,SAAUC,GAChC,GAAInF,EACJ,KACEA,EAAUmF,IACV,MAAOjG,GACP,MAAOuC,GAAgBvC,GAEzB,MAAOqC,GAAsBvB,IAGtB1C"}
1
+ {"version":3,"file":"rx.async.min.js","sources":["rx.async.js"],"names":["factory","objectTypes","function","object","freeExports","exports","nodeType","freeSelf","self","Object","freeWindow","window","freeModule","module","freeGlobal","global","root","this","define","amd","Rx","require","call","exp","undefined","tryCatcher","tryCatchTarget","apply","arguments","e","errorObj","tryCatch","fn","isFunction","TypeError","toObservable","obj","Observable","isObservable","isPromise","fromPromise","isGeneratorFunction","isGenerator","spawn","thunkToObservable","isArrayLike","isIterable","arrayToObservable","isObject","objectToObservable","from","flatMap","toArray","defer","observable","key","results","observables","push","map","next","constructor","keys","i","len","length","forkJoin","AnonymousObservable","o","err","res","onError","args","onNext","onCompleted","throw","ctor","name","displayName","prototype","createCbObservable","ctx","selector","AsyncSubject","createCbHandler","asObservable","Array","createNodeObservable","createNodeHandler","ListenDisposable","n","_e","_n","_fn","addEventListener","isDisposed","createEventListener","el","eventName","handler","disposables","CompositeDisposable","elemToString","toString","add","item","eventHandler","observableFromPromise","observableThrow","throwError","disposableCreate","Disposable","create","immediateScheduler","Scheduler","immediate","timeoutScheduler","isScheduler","helpers","wrap","createObservable","__generatorFunction__","gen","processGenerator","ret","done","value","g","subscribe","start","func","context","scheduler","observableToAsync","toAsync","subject","schedule","result","fromCallback","fromNodeCallback","dispose","removeEventListener","config","useNativeEvents","fromEvent","element","addListener","fromEventPattern","h","removeListener","on","off","publish","refCount","addHandler","removeHandler","innerHandler","returnValue","startAsync","functionAsync","promise"],"mappings":";CAEE,SAAUA,GACV,GAAIC,IACFC,YAAY,EACZC,QAAU,GAIVC,EAAcH,QAAmBI,WAAYA,UAAYA,QAAQC,UAAYD,QAC7EE,EAAWN,QAAmBO,QAASA,KAAKC,QAAUD,KACtDE,EAAaT,QAAmBU,UAAWA,QAAUA,OAAOF,QAAUE,OACtEC,EAAaX,QAAmBY,UAAWA,SAAWA,OAAOP,UAAYO,OAEzEC,GADgBF,GAAcA,EAAWP,UAAYD,GAAeA,EACvDA,GAAeQ,GAA+B,gBAAVG,SAAsBA,QAAUA,OAAON,QAAUM,QAEhGC,EAAOA,EAAOF,GAAgBJ,KAAgBO,MAAQA,KAAKN,SAAYD,GAAeH,GAAYU,IAGhF,mBAAXC,SAAyBA,OAAOC,IACzCD,QAAQ,eAAgB,WAAY,SAAUE,EAAIf,GAEhD,MADAW,GAAKI,GAAKpB,EAAQgB,EAAMX,E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B,GAAcH,EAAWE,EAC7B,OAAO9C,GAAiB,WACtB7E,EAAW0H,IAAkBA,EAAcC,EAAcC,OAE1DL,UAAUC,WAkBf,OAVApH,GAAWyH,WAAa,SAAUC,GAChC,GAAIC,EACJ,KACEA,EAAUD,IACV,MAAOlI,GACP,MAAO+E,GAAgB/E,GAEzB,MAAO8E,GAAsBqD,IAGxB5I"}
@@ -1,3 +1,3 @@
1
1
  /* Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information.*/
2
- (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.binding","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 Array.isArray(a)?e.call(b,a):i(a)?z(a.call(b)):j(a)?z(a):h(a)?f(a):isPromise(a)?g(a):typeof a===w?a:y(a)||Array.isArray(a)?e.call(b,a):a}function e(a){var b=this;return function(c){function e(a,e){if(!f)try{if(a=d(a,b),typeof a!==w)return i[e]=a,--h||c(null,i);a.call(b,function(a,b){if(!f){if(a)return f=!0,c(a);i[e]=b,--h||c(null,i)}})}catch(g){f=!0,c(g)}}var f,g=Object.keys(a),h=g.length,i=new a.constructor;if(!h)return void u.schedule(function(){c(null,i)});for(var j=0,k=g.length;k>j;j++)e(a[g[j]],g[j])}}function f(a){return function(b){var c,d=!1;a.subscribe(function(a){c=a,d=!0},b,function(){d&&b(null,c)})}}function g(a){return function(b){a.then(function(a){b(null,a)},b)}}function h(a){return a&&typeof a.subscribe===w}function i(a){return a&&a.constructor&&"GeneratorFunction"===a.constructor.name}function j(a){return a&&typeof a.next===w&&typeof a[x]===w}function k(a){a&&u.schedule(function(){throw a})}function l(a,b,c){if(a.addEventListener)return a.addEventListener(b,c,!1),s(function(){a.removeEventListener(b,c,!1)});throw new Error("No listener found")}function m(a,b,c){var d=new t;if("[object NodeList]"===Object.prototype.toString.call(a))for(var e=0,f=a.length;f>e;e++)d.add(m(a.item(e),b,c));else a&&d.add(l(a,b,c));return d}var n=c.Observable,o=(n.prototype,n.fromPromise),p=n.throwError,q=c.AnonymousObservable,r=c.AsyncSubject,s=c.Disposable.create,t=c.CompositeDisposable,u=(c.Scheduler.immediate,c.Scheduler["default"]),v=c.Scheduler.isScheduler,w=(Array.prototype.slice,"function"),x="throw",y=c.internals.isObject,z=c.spawn=function(a){var b=i(a);return function(c){function e(a,b){u.schedule(c.bind(g,a,b))}function f(a,b){var c;if(arguments.length>2)for(var b=[],i=1,j=arguments.length;j>i;i++)b.push(arguments[i]);if(a)try{c=h[x](a)}catch(k){return e(k)}if(!a)try{c=h.next(b)}catch(k){return e(k)}if(c.done)return e(null,c.value);if(c.value=d(c.value,g),typeof c.value!==w)f(new TypeError("Rx.spawn only supports a function, Promise, Observable, Object or Array."));else{var l=!1;try{c.value.call(g,function(){l||(l=!0,f.apply(g,arguments))})}catch(k){u.schedule(function(){l||(l=!0,f.call(g,k))})}}}var g=this,h=a;if(b){for(var i=[],j=0,l=arguments.length;l>j;j++)i.push(arguments[j]);var l=i.length,m=l&&typeof i[l-1]===w;c=m?i.pop():k,h=a.apply(this,i)}else c=c||k;f()}};n.start=function(a,b,c){return A(a,b,c)()};var A=n.toAsync=function(a,b,c){return v(c)||(c=u),function(){var d=arguments,e=new r;return c.schedule(function(){var c;try{c=a.apply(b,d)}catch(f){return void e.onError(f)}e.onNext(c),e.onCompleted()}),e.asObservable()}};n.fromCallback=function(a,b,c){return function(){for(var d=arguments.length,e=new Array(d),f=0;d>f;f++)e[f]=arguments[f];return new q(function(d){function f(){for(var a=arguments.length,e=new Array(a),f=0;a>f;f++)e[f]=arguments[f];if(c){try{e=c.apply(b,e)}catch(g){return d.onError(g)}d.onNext(e)}else e.length<=1?d.onNext.apply(d,e):d.onNext(e);d.onCompleted()}e.push(f),a.apply(b,e)}).publishLast().refCount()}},n.fromNodeCallback=function(a,b,c){return function(){for(var d=arguments.length,e=new Array(d),f=0;d>f;f++)e[f]=arguments[f];return new q(function(d){function f(a){if(a)return void d.onError(a);for(var e=arguments.length,f=[],g=1;e>g;g++)f[g-1]=arguments[g];if(c){try{f=c.apply(b,f)}catch(h){return d.onError(h)}d.onNext(f)}else f.length<=1?d.onNext.apply(d,f):d.onNext(f);d.onCompleted()}e.push(f),a.apply(b,e)}).publishLast().refCount()}},c.config.useNativeEvents=!1,n.fromEvent=function(a,b,d){return a.addListener?B(function(c){a.addListener(b,c)},function(c){a.removeListener(b,c)},d):c.config.useNativeEvents||"function"!=typeof a.on||"function"!=typeof a.off?new q(function(c){return m(a,b,function(a){var b=a;if(d)try{b=d(arguments)}catch(e){return c.onError(e)}c.onNext(b)})}).publish().refCount():B(function(c){a.on(b,c)},function(c){a.off(b,c)},d)};var B=n.fromEventPattern=function(a,b,c){return new q(function(d){function e(a){var b=a;if(c)try{b=c(arguments)}catch(e){return d.onError(e)}d.onNext(b)}var f=a(e);return s(function(){b&&b(e,f)})}).publish().refCount()};return n.startAsync=function(a){var b;try{b=a()}catch(c){return p(c)}return o(b)},c});
2
+ (function(a){var b={"function":!0,object:!0},c=b[typeof exports]&&exports&&!exports.nodeType&&exports,d=b[typeof self]&&self.Object&&self,e=b[typeof window]&&window&&window.Object&&window,f=b[typeof module]&&module&&!module.nodeType&&module,g=(f&&f.exports===c&&c,c&&f&&"object"==typeof global&&global&&global.Object&&global),h=h=g||e!==(this&&this.window)&&e||d||this;"function"==typeof define&&define.amd?define(["./rx.binding","exports"],function(b,c){return h.Rx=a(h,c,b),h.Rx}):"object"==typeof module&&module&&module.exports===c?module.exports=a(h,module.exports,require("./rx")):h.Rx=a(h,{},h.Rx)}).call(this,function(a,b,c,d){function e(){try{return t.apply(this,arguments)}catch(a){return G.e=a,G}}function f(a){if(!F(a))throw new TypeError("fn must be a function");return t=a,e}function g(a){return a?u.isObservable(a)?a:E(a)?u.fromPromise(a):l(a)||k(a)?H.call(this,a):F(a)?j.call(this,a):isArrayLike(a)||isIterable(a)?h.call(this,a):isObject(a)?i.call(this,a):a:a}function h(a){return u.from(a).flatMap(g).toArray()}function i(a){function b(a,b){c[b]=d,f.push(a.map(function(a){c[b]=a}))}for(var c=new a.constructor,e=Object.keys(a),f=[],h=0,i=e.length;i>h;h++){var j=e[h],k=g.call(this,a[j]);k&&u.isObservable(k)?b(k,j):c[j]=a[j]}return u.forkJoin.apply(u,f).map(function(){return c})}function j(a){var b=this;return new x(function(c){a.call(b,function(){var a=arguments[0],b=arguments[1];if(a)return c.onError(a);if(arguments.length>2){for(var d=[],e=1,f=arguments.length;f>e;e++)d.push(arguments[e]);b=d}c.onNext(b),c.onCompleted()})})}function k(a){return F(a.next)&&F(a.throw)}function l(a){var b=a.constructor;return b?"GeneratorFunction"===b.name||"GeneratorFunction"===b.displayName?!0:k(b.prototype):!1}function m(a,b,c,d){var e=new y;return d.push(n(e,b,c)),a.apply(b,d),e.asObservable()}function n(a,b,c){return function(){for(var d=arguments.length,e=new Array(d),g=0;d>g;g++)e[g]=arguments[g];if(F(c)){if(e=f(c).apply(b,e),e===G)return a.onError(e.e);a.onNext(e)}else a.onNext(e.length<=1?e[0]:e);a.onCompleted()}}function o(a,b,c,d){var e=new y;return d.push(p(e,b,c)),a.apply(b,d),e.asObservable()}function p(a,b,c){return function(){var d=arguments[0];if(d)return a.onError(d);for(var e=arguments.length,g=[],h=1;e>h;h++)g[h-1]=arguments[h];if(F(c)){var g=f(c).apply(b,g);if(g===G)return a.onError(g.e);a.onNext(g)}else a.onNext(g.length<=1?g[0]:g);a.onCompleted()}}function q(a,b,c){this._e=a,this._n=b,this._fn=c,this._e.addEventListener(this._n,this._fn,!1),this.isDisposed=!1}function r(a,b,c){var d=new A,e=Object.prototype.toString.call(a);if("[object NodeList]"===e||"[object HTMLCollection]"===e)for(var f=0,g=a.length;g>f;f++)d.add(r(a.item(f),b,c));else a&&d.add(new q(a,b,c));return d}function s(a,b){return function(){var c=arguments[0];return F(b)&&(c=f(b).apply(null,arguments),c===G)?a.onError(c.e):void a.onNext(c)}}var t,u=c.Observable,v=(u.prototype,u.fromPromise),w=u.throwError,x=c.AnonymousObservable,y=c.AsyncSubject,z=c.Disposable.create,A=c.CompositeDisposable,B=c.Scheduler.immediate,C=c.Scheduler["default"],D=c.Scheduler.isScheduler,E=c.helpers.isPromise,F=c.helpers.isFunction,G={e:{}};u.wrap=function(a){function b(){return u.spawn.call(this,a.apply(this,arguments))}return b.__generatorFunction__=a,b};var H=u.spawn=function(){for(var a=arguments[0],b=this,c=[],d=1,e=arguments.length;e>d;d++)c.push(arguments[d]);return new x(function(d){function e(b){var c=f(a.next).call(a,b);return c===G?d.onError(c.e):void i(c)}function h(b){var c=f(a.next).call(a,b);return c===G?d.onError(c.e):void i(c)}function i(a){if(a.done)return d.onNext(a.value),void d.onCompleted();var c=g.call(b,a.value);u.isObservable(c)?j.add(c.subscribe(e,h)):h(new TypeError("type not supported"))}var j=new A;return F(a)&&(a=a.apply(b,c)),a&&F(a.next)?(e(),j):(d.onNext(a),d.onCompleted())})};u.start=function(a,b,c){return I(a,b,c)()};var I=u.toAsync=function(a,b,c){return D(c)||(c=C),function(){var d=arguments,e=new y;return c.schedule(function(){var c;try{c=a.apply(b,d)}catch(f){return void e.onError(f)}e.onNext(c),e.onCompleted()}),e.asObservable()}};u.fromCallback=function(a,b,c){return function(){"undefined"==typeof b&&(b=this);for(var d=arguments.length,e=new Array(d),f=0;d>f;f++)e[f]=arguments[f];return m(a,b,c,e)}},u.fromNodeCallback=function(a,b,c){return function(){"undefined"==typeof b&&(b=this);for(var d=arguments.length,e=new Array(d),f=0;d>f;f++)e[f]=arguments[f];return o(a,b,c,e)}},q.prototype.dispose=function(){this.isDisposed||(this._e.removeEventListener(this._n,this._fn,!1),this.isDisposed=!0)},c.config.useNativeEvents=!1,u.fromEvent=function(a,b,d){return a.addListener?J(function(c){a.addListener(b,c)},function(c){a.removeListener(b,c)},d):c.config.useNativeEvents||"function"!=typeof a.on||"function"!=typeof a.off?new x(function(c){return r(a,b,s(c,d))}).publish().refCount():J(function(c){a.on(b,c)},function(c){a.off(b,c)},d)};var J=u.fromEventPattern=function(a,b,c,d){return D(d)||(d=B),new x(function(d){function e(){var a=arguments[0];return F(c)&&(a=f(c).apply(null,arguments),a===G)?d.onError(a.e):void d.onNext(a)}var g=a(e);return z(function(){F(b)&&b(e,g)})}).publish().refCount()};return u.startAsync=function(a){var b;try{b=a()}catch(c){return w(c)}return v(b)},c});
3
3
  //# sourceMappingURL=rx.async.map
@@ -1,35 +1,31 @@
1
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
- var objectTypes = {
5
- 'boolean': false,
6
- 'function': true,
7
- 'object': true,
8
- 'number': false,
9
- 'string': false,
10
- 'undefined': false
11
- };
4
+ var objectTypes = {
5
+ 'function': true,
6
+ 'object': true
7
+ };
12
8
 
13
- var root = (objectTypes[typeof window] && window) || this,
14
- freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports,
15
- freeModule = objectTypes[typeof module] && module && !module.nodeType && module,
16
- moduleExports = freeModule && freeModule.exports === freeExports && freeExports,
17
- freeGlobal = objectTypes[typeof global] && global;
9
+ var
10
+ freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports,
11
+ freeSelf = objectTypes[typeof self] && self.Object && self,
12
+ freeWindow = objectTypes[typeof window] && window && window.Object && window,
13
+ freeModule = objectTypes[typeof module] && module && !module.nodeType && module,
14
+ moduleExports = freeModule && freeModule.exports === freeExports && freeExports,
15
+ freeGlobal = freeExports && freeModule && typeof global == 'object' && global && global.Object && global;
18
16
 
19
- if (freeGlobal && (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal)) {
20
- root = freeGlobal;
21
- }
17
+ var root = root = freeGlobal || ((freeWindow !== (this && this.window)) && freeWindow) || freeSelf || this;
22
18
 
23
- // Because of build optimizers
24
- if (typeof define === 'function' && define.amd) {
25
- define(['rx'], function (Rx, exports) {
26
- return factory(root, exports, Rx);
27
- });
28
- } else if (typeof module === 'object' && module && module.exports === freeExports) {
29
- module.exports = factory(root, module.exports, require('./rx'));
30
- } else {
31
- root.Rx = factory(root, {}, root.Rx);
32
- }
19
+ // Because of build optimizers
20
+ if (typeof define === 'function' && define.amd) {
21
+ define(['./rx'], function (Rx, exports) {
22
+ return factory(root, exports, Rx);
23
+ });
24
+ } else if (typeof module === 'object' && module && module.exports === freeExports) {
25
+ module.exports = factory(root, module.exports, require('./rx'));
26
+ } else {
27
+ root.Rx = factory(root, {}, root.Rx);
28
+ }
33
29
  }.call(this, function (root, exp, Rx, undefined) {
34
30
 
35
31
  // References
@@ -49,8 +45,28 @@
49
45
  currentThreadScheduler = Rx.Scheduler.currentThread,
50
46
  identity = Rx.helpers.identity,
51
47
  isScheduler = Rx.Scheduler.isScheduler,
48
+ isFunction = Rx.helpers.isFunction,
52
49
  checkDisposed = Rx.Disposable.checkDisposed;
53
50
 
51
+ var errorObj = {e: {}};
52
+ var tryCatchTarget;
53
+ function tryCatcher() {
54
+ try {
55
+ return tryCatchTarget.apply(this, arguments);
56
+ } catch (e) {
57
+ errorObj.e = e;
58
+ return errorObj;
59
+ }
60
+ }
61
+ function tryCatch(fn) {
62
+ if (!isFunction(fn)) { throw new TypeError('fn must be a function'); }
63
+ tryCatchTarget = fn;
64
+ return tryCatcher;
65
+ }
66
+ function thrower(e) {
67
+ throw e;
68
+ }
69
+
54
70
  /**
55
71
  * Used to pause and resume streams.
56
72
  */
@@ -141,26 +157,15 @@
141
157
  err;
142
158
 
143
159
  function next(x, i) {
144
- values[i] = x
145
- var res;
160
+ values[i] = x;
146
161
  hasValue[i] = true;
147
162
  if (hasValueAll || (hasValueAll = hasValue.every(identity))) {
148
- if (err) {
149
- o.onError(err);
150
- return;
151
- }
152
-
153
- try {
154
- res = resultSelector.apply(null, values);
155
- } catch (ex) {
156
- o.onError(ex);
157
- return;
158
- }
163
+ if (err) { return o.onError(err); }
164
+ var res = tryCatch(resultSelector).apply(null, values);
165
+ if (res === errorObj) { return o.onError(res.e); }
159
166
  o.onNext(res);
160
167
  }
161
- if (isDone && values[1]) {
162
- o.onCompleted();
163
- }
168
+ isDone && values[1] && o.onCompleted();
164
169
  }
165
170
 
166
171
  return new CompositeDisposable(
@@ -199,10 +204,12 @@
199
204
  function subscribe(o) {
200
205
  var q = [], previousShouldFire;
201
206
 
207
+ function drainQueue() { while (q.length > 0) { o.onNext(q.shift()); } }
208
+
202
209
  var subscription =
203
210
  combineLatestSource(
204
211
  this.source,
205
- this.pauser.distinctUntilChanged().startWith(false),
212
+ this.pauser.startWith(false).distinctUntilChanged(),
206
213
  function (data, shouldFire) {
207
214
  return { data: data, shouldFire: shouldFire };
208
215
  })
@@ -211,11 +218,7 @@
211
218
  if (previousShouldFire !== undefined && results.shouldFire != previousShouldFire) {
212
219
  previousShouldFire = results.shouldFire;
213
220
  // change in shouldFire
214
- if (results.shouldFire) {
215
- while (q.length > 0) {
216
- o.onNext(q.shift());
217
- }
218
- }
221
+ if (results.shouldFire) { drainQueue(); }
219
222
  } else {
220
223
  previousShouldFire = results.shouldFire;
221
224
  // new data
@@ -227,17 +230,11 @@
227
230
  }
228
231
  },
229
232
  function (err) {
230
- // Empty buffer before sending error
231
- while (q.length > 0) {
232
- o.onNext(q.shift());
233
- }
233
+ drainQueue();
234
234
  o.onError(err);
235
235
  },
236
236
  function () {
237
- // Empty buffer before sending completion
238
- while (q.length > 0) {
239
- o.onNext(q.shift());
240
- }
237
+ drainQueue();
241
238
  o.onCompleted();
242
239
  }
243
240
  );
@@ -282,144 +279,147 @@
282
279
  return new PausableBufferedObservable(this, subject);
283
280
  };
284
281
 
285
- var ControlledObservable = (function (__super__) {
282
+ var ControlledObservable = (function (__super__) {
286
283
 
287
- inherits(ControlledObservable, __super__);
284
+ inherits(ControlledObservable, __super__);
288
285
 
289
- function subscribe (observer) {
290
- return this.source.subscribe(observer);
291
- }
292
-
293
- function ControlledObservable (source, enableQueue, scheduler) {
294
- __super__.call(this, subscribe, source);
295
- this.subject = new ControlledSubject(enableQueue, scheduler);
296
- this.source = source.multicast(this.subject).refCount();
297
- }
286
+ function subscribe (observer) {
287
+ return this.source.subscribe(observer);
288
+ }
298
289
 
299
- ControlledObservable.prototype.request = function (numberOfItems) {
300
- return this.subject.request(numberOfItems == null ? -1 : numberOfItems);
301
- };
290
+ function ControlledObservable (source, enableQueue, scheduler) {
291
+ __super__.call(this, subscribe, source);
292
+ this.subject = new ControlledSubject(enableQueue, scheduler);
293
+ this.source = source.multicast(this.subject).refCount();
294
+ }
302
295
 
303
- return ControlledObservable;
296
+ ControlledObservable.prototype.request = function (numberOfItems) {
297
+ return this.subject.request(numberOfItems == null ? -1 : numberOfItems);
298
+ };
304
299
 
305
- }(Observable));
300
+ return ControlledObservable;
306
301
 
307
- var ControlledSubject = (function (__super__) {
302
+ }(Observable));
308
303
 
309
- function subscribe (observer) {
310
- return this.subject.subscribe(observer);
311
- }
304
+ var ControlledSubject = (function (__super__) {
312
305
 
313
- inherits(ControlledSubject, __super__);
314
-
315
- function ControlledSubject(enableQueue, scheduler) {
316
- enableQueue == null && (enableQueue = true);
317
-
318
- __super__.call(this, subscribe);
319
- this.subject = new Subject();
320
- this.enableQueue = enableQueue;
321
- this.queue = enableQueue ? [] : null;
322
- this.requestedCount = 0;
323
- this.requestedDisposable = disposableEmpty;
324
- this.error = null;
325
- this.hasFailed = false;
326
- this.hasCompleted = false;
327
- this.scheduler = scheduler || currentThreadScheduler;
328
- }
306
+ function subscribe (observer) {
307
+ return this.subject.subscribe(observer);
308
+ }
329
309
 
330
- addProperties(ControlledSubject.prototype, Observer, {
331
- onCompleted: function () {
332
- this.hasCompleted = true;
333
- if (!this.enableQueue || this.queue.length === 0) {
334
- this.subject.onCompleted();
335
- } else {
336
- this.queue.push(Notification.createOnCompleted());
337
- }
338
- },
339
- onError: function (error) {
340
- this.hasFailed = true;
341
- this.error = error;
342
- if (!this.enableQueue || this.queue.length === 0) {
343
- this.subject.onError(error);
344
- } else {
345
- this.queue.push(Notification.createOnError(error));
346
- }
347
- },
348
- onNext: function (value) {
349
- var hasRequested = false;
310
+ inherits(ControlledSubject, __super__);
311
+
312
+ function ControlledSubject(enableQueue, scheduler) {
313
+ enableQueue == null && (enableQueue = true);
314
+
315
+ __super__.call(this, subscribe);
316
+ this.subject = new Subject();
317
+ this.enableQueue = enableQueue;
318
+ this.queue = enableQueue ? [] : null;
319
+ this.requestedCount = 0;
320
+ this.requestedDisposable = null;
321
+ this.error = null;
322
+ this.hasFailed = false;
323
+ this.hasCompleted = false;
324
+ this.scheduler = scheduler || currentThreadScheduler;
325
+ }
350
326
 
351
- if (this.requestedCount === 0) {
352
- this.enableQueue && this.queue.push(Notification.createOnNext(value));
353
- } else {
354
- (this.requestedCount !== -1 && this.requestedCount-- === 0) && this.disposeCurrentRequest();
355
- hasRequested = true;
356
- }
357
- hasRequested && this.subject.onNext(value);
358
- },
359
- _processRequest: function (numberOfItems) {
360
- if (this.enableQueue) {
361
- while ((this.queue.length >= numberOfItems && numberOfItems > 0) ||
362
- (this.queue.length > 0 && this.queue[0].kind !== 'N')) {
363
- var first = this.queue.shift();
364
- first.accept(this.subject);
365
- if (first.kind === 'N') {
366
- numberOfItems--;
367
- } else {
368
- this.disposeCurrentRequest();
369
- this.queue = [];
370
- }
327
+ addProperties(ControlledSubject.prototype, Observer, {
328
+ onCompleted: function () {
329
+ this.hasCompleted = true;
330
+ if (!this.enableQueue || this.queue.length === 0) {
331
+ this.subject.onCompleted();
332
+ this.disposeCurrentRequest()
333
+ } else {
334
+ this.queue.push(Notification.createOnCompleted());
335
+ }
336
+ },
337
+ onError: function (error) {
338
+ this.hasFailed = true;
339
+ this.error = error;
340
+ if (!this.enableQueue || this.queue.length === 0) {
341
+ this.subject.onError(error);
342
+ this.disposeCurrentRequest()
343
+ } else {
344
+ this.queue.push(Notification.createOnError(error));
345
+ }
346
+ },
347
+ onNext: function (value) {
348
+ if (this.requestedCount <= 0) {
349
+ this.enableQueue && this.queue.push(Notification.createOnNext(value));
350
+ } else {
351
+ (this.requestedCount-- === 0) && this.disposeCurrentRequest();
352
+ this.subject.onNext(value);
353
+ }
354
+ },
355
+ _processRequest: function (numberOfItems) {
356
+ if (this.enableQueue) {
357
+ while (this.queue.length > 0 && (numberOfItems > 0 || this.queue[0].kind !== 'N')) {
358
+ var first = this.queue.shift();
359
+ first.accept(this.subject);
360
+ if (first.kind === 'N') {
361
+ numberOfItems--;
362
+ } else {
363
+ this.disposeCurrentRequest();
364
+ this.queue = [];
371
365
  }
372
-
373
- return { numberOfItems : numberOfItems, returnValue: this.queue.length !== 0};
374
366
  }
367
+ }
375
368
 
376
- return { numberOfItems: numberOfItems, returnValue: false };
377
- },
378
- request: function (number) {
379
- this.disposeCurrentRequest();
380
- var self = this;
369
+ return numberOfItems;
370
+ },
371
+ request: function (number) {
372
+ this.disposeCurrentRequest();
373
+ var self = this;
381
374
 
382
- this.requestedDisposable = this.scheduler.scheduleWithState(number,
383
- function(s, i) {
384
- var r = self._processRequest(i), remaining = r.numberOfItems;
385
- if (!r.returnValue) {
386
- self.requestedCount = remaining;
387
- self.requestedDisposable = disposableCreate(function () {
388
- self.requestedCount = 0;
389
- });
390
- }
391
- });
375
+ this.requestedDisposable = this.scheduler.scheduleWithState(number,
376
+ function(s, i) {
377
+ var remaining = self._processRequest(i);
378
+ var stopped = self.hasCompleted || self.hasFailed
379
+ if (!stopped && remaining > 0) {
380
+ self.requestedCount = remaining;
392
381
 
393
- return this.requestedDisposable;
394
- },
395
- disposeCurrentRequest: function () {
382
+ return disposableCreate(function () {
383
+ self.requestedCount = 0;
384
+ });
385
+ // Scheduled item is still in progress. Return a new
386
+ // disposable to allow the request to be interrupted
387
+ // via dispose.
388
+ }
389
+ });
390
+
391
+ return this.requestedDisposable;
392
+ },
393
+ disposeCurrentRequest: function () {
394
+ if (this.requestedDisposable) {
396
395
  this.requestedDisposable.dispose();
397
- this.requestedDisposable = disposableEmpty;
396
+ this.requestedDisposable = null;
398
397
  }
399
- });
400
-
401
- return ControlledSubject;
402
- }(Observable));
403
-
404
- /**
405
- * Attaches a controller to the observable sequence with the ability to queue.
406
- * @example
407
- * var source = Rx.Observable.interval(100).controlled();
408
- * source.request(3); // Reads 3 values
409
- * @param {bool} enableQueue truthy value to determine if values should be queued pending the next request
410
- * @param {Scheduler} scheduler determines how the requests will be scheduled
411
- * @returns {Observable} The observable sequence which is paused based upon the pauser.
412
- */
413
- observableProto.controlled = function (enableQueue, scheduler) {
414
-
415
- if (enableQueue && isScheduler(enableQueue)) {
416
- scheduler = enableQueue;
417
- enableQueue = true;
418
398
  }
399
+ });
400
+
401
+ return ControlledSubject;
402
+ }(Observable));
403
+
404
+ /**
405
+ * Attaches a controller to the observable sequence with the ability to queue.
406
+ * @example
407
+ * var source = Rx.Observable.interval(100).controlled();
408
+ * source.request(3); // Reads 3 values
409
+ * @param {bool} enableQueue truthy value to determine if values should be queued pending the next request
410
+ * @param {Scheduler} scheduler determines how the requests will be scheduled
411
+ * @returns {Observable} The observable sequence which only propagates values on request.
412
+ */
413
+ observableProto.controlled = function (enableQueue, scheduler) {
414
+
415
+ if (enableQueue && isScheduler(enableQueue)) {
416
+ scheduler = enableQueue;
417
+ enableQueue = true;
418
+ }
419
419
 
420
- if (enableQueue == null) { enableQueue = true; }
421
- return new ControlledObservable(this, enableQueue, scheduler);
422
- };
420
+ if (enableQueue == null) { enableQueue = true; }
421
+ return new ControlledObservable(this, enableQueue, scheduler);
422
+ };
423
423
 
424
424
  var StopAndWaitObservable = (function (__super__) {
425
425
 
@@ -575,5 +575,37 @@
575
575
  return new WindowedObservable(this, windowSize);
576
576
  };
577
577
 
578
- return Rx;
578
+ /**
579
+ * Pipes the existing Observable sequence into a Node.js Stream.
580
+ * @param {Stream} dest The destination Node.js stream.
581
+ * @returns {Stream} The destination stream.
582
+ */
583
+ observableProto.pipe = function (dest) {
584
+ var source = this.pausableBuffered();
585
+
586
+ function onDrain() {
587
+ source.resume();
588
+ }
589
+
590
+ dest.addListener('drain', onDrain);
591
+
592
+ source.subscribe(
593
+ function (x) {
594
+ !dest.write(String(x)) && source.pause();
595
+ },
596
+ function (err) {
597
+ dest.emit('error', err);
598
+ },
599
+ function () {
600
+ // Hack check because STDIO is not closable
601
+ !dest._isStdio && dest.end();
602
+ dest.removeListener('drain', onDrain);
603
+ });
604
+
605
+ source.resume();
606
+
607
+ return dest;
608
+ };
609
+
610
+ return Rx;
579
611
  }));