text: "use strict";
  var __extends = (this && this.__extends) || function (d, b) {
      for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
      function __() { this.constructor = d; }
      d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  };
  var most_1 = require("most");
  var multicast_1 = require("@most/multicast");
  function sync() {
      return asSync(most_1.never());
  }
  exports.sync = sync;
  function asSync(stream) {
      return new SyncSubject(new multicast_1.MulticastSource(stream.source));
  }
  exports.asSync = asSync;
  var SyncSubject = (function (_super) {
      __extends(SyncSubject, _super);
      function SyncSubject(source) {
          return _super.call(this, source) || this;
      }
      SyncSubject.prototype.next = function (value) {
          this.source.event(most_1.defaultScheduler.now(), value);
          return this;
      };
      SyncSubject.prototype.error = function (err) {
          this.source.error(most_1.defaultScheduler.now(), err);
          return this;
      };
      SyncSubject.prototype.complete = function (value) {
          this.source.end(most_1.defaultScheduler.now(), value);
          return this;
      };
      return SyncSubject;
  }(most_1.Stream));
  exports.SyncSubject = SyncSubject;
  //# sourceMappingURL=index.js.map