{"ast":null,"code":"import _classCallCheck from \"C:/Users/kgamal/Downloads/HijriGregorianDatepicker-master/HijriGregorianDatepicker-master/node_modules/@babel/runtime/helpers/esm/classCallCheck\";\nimport _createClass from \"C:/Users/kgamal/Downloads/HijriGregorianDatepicker-master/HijriGregorianDatepicker-master/node_modules/@babel/runtime/helpers/esm/createClass\";\nimport { empty } from './observable/empty';\nimport { of } from './observable/of';\nimport { throwError } from './observable/throwError';\nexport var NotificationKind = /*@__PURE__*/function (NotificationKind) {\n  NotificationKind[\"NEXT\"] = \"N\";\n  NotificationKind[\"ERROR\"] = \"E\";\n  NotificationKind[\"COMPLETE\"] = \"C\";\n  return NotificationKind;\n}({});\nexport var Notification = /*@__PURE__*/function () {\n  var Notification = /*#__PURE__*/function () {\n    function Notification(kind, value, error) {\n      _classCallCheck(this, Notification);\n\n      this.kind = kind;\n      this.value = value;\n      this.error = error;\n      this.hasValue = kind === 'N';\n    }\n\n    _createClass(Notification, [{\n      key: \"observe\",\n      value: function observe(observer) {\n        switch (this.kind) {\n          case 'N':\n            return observer.next && observer.next(this.value);\n\n          case 'E':\n            return observer.error && observer.error(this.error);\n\n          case 'C':\n            return observer.complete && observer.complete();\n        }\n      }\n    }, {\n      key: \"do\",\n      value: function _do(next, error, complete) {\n        var kind = this.kind;\n\n        switch (kind) {\n          case 'N':\n            return next && next(this.value);\n\n          case 'E':\n            return error && error(this.error);\n\n          case 'C':\n            return complete && complete();\n        }\n      }\n    }, {\n      key: \"accept\",\n      value: function accept(nextOrObserver, error, complete) {\n        if (nextOrObserver && typeof nextOrObserver.next === 'function') {\n          return this.observe(nextOrObserver);\n        } else {\n          return this.do(nextOrObserver, error, complete);\n        }\n      }\n    }, {\n      key: \"toObservable\",\n      value: function toObservable() {\n        var kind = this.kind;\n\n        switch (kind) {\n          case 'N':\n            return of(this.value);\n\n          case 'E':\n            return throwError(this.error);\n\n          case 'C':\n            return empty();\n        }\n\n        throw new Error('unexpected notification kind value');\n      }\n    }], [{\n      key: \"createNext\",\n      value: function createNext(value) {\n        if (typeof value !== 'undefined') {\n          return new Notification('N', value);\n        }\n\n        return Notification.undefinedValueNotification;\n      }\n    }, {\n      key: \"createError\",\n      value: function createError(err) {\n        return new Notification('E', undefined, err);\n      }\n    }, {\n      key: \"createComplete\",\n      value: function createComplete() {\n        return Notification.completeNotification;\n      }\n    }]);\n\n    return Notification;\n  }();\n\n  Notification.completeNotification = /*@__PURE__*/new Notification('C');\n  Notification.undefinedValueNotification = /*@__PURE__*/new Notification('N', undefined);\n  return Notification;\n}(); //# sourceMappingURL=Notification.js.map","map":null,"metadata":{},"sourceType":"module"}