1 /** PURE_IMPORTS_START tslib,_Subscriber PURE_IMPORTS_END */
2 import * as tslib_1 from "tslib";
3 import { Subscriber } from '../Subscriber';
4 export function isEmpty() {
5 return function (source) { return source.lift(new IsEmptyOperator()); };
7 var IsEmptyOperator = /*@__PURE__*/ (function () {
8 function IsEmptyOperator() {
10 IsEmptyOperator.prototype.call = function (observer, source) {
11 return source.subscribe(new IsEmptySubscriber(observer));
13 return IsEmptyOperator;
15 var IsEmptySubscriber = /*@__PURE__*/ (function (_super) {
16 tslib_1.__extends(IsEmptySubscriber, _super);
17 function IsEmptySubscriber(destination) {
18 return _super.call(this, destination) || this;
20 IsEmptySubscriber.prototype.notifyComplete = function (isEmpty) {
21 var destination = this.destination;
22 destination.next(isEmpty);
23 destination.complete();
25 IsEmptySubscriber.prototype._next = function (value) {
26 this.notifyComplete(false);
28 IsEmptySubscriber.prototype._complete = function () {
29 this.notifyComplete(true);
31 return IsEmptySubscriber;
33 //# sourceMappingURL=isEmpty.js.map