Debian Codegraph @

node/rxjs/dist/esm5/internal/util/executeSchedule.js

raw
1 export function executeSchedule(parentSubscription, scheduler, work, delay, repeat) {
2 if (delay === void 0) { delay = 0; }
3 if (repeat === void 0) { repeat = false; }
4 var scheduleSubscription = scheduler.schedule(function () {
5 work();
6 if (repeat) {
7 parentSubscription.add(this.schedule(null, delay));
8 }
9 else {
10 this.unsubscribe();
11 }
12 }, delay);
13 parentSubscription.add(scheduleSubscription);
14 if (!repeat) {
15 return scheduleSubscription;
16 }
17 }
18 //# sourceMappingURL=executeSchedule.js.map