source: trip-planner-front/node_modules/rxjs/_esm5/internal/scheduled/scheduleArray.js@ eed0bf8

Last change on this file since eed0bf8 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 702 bytes
Line 
1/** PURE_IMPORTS_START _Observable,_Subscription PURE_IMPORTS_END */
2import { Observable } from '../Observable';
3import { Subscription } from '../Subscription';
4export function scheduleArray(input, scheduler) {
5 return new Observable(function (subscriber) {
6 var sub = new Subscription();
7 var i = 0;
8 sub.add(scheduler.schedule(function () {
9 if (i === input.length) {
10 subscriber.complete();
11 return;
12 }
13 subscriber.next(input[i++]);
14 if (!subscriber.closed) {
15 sub.add(this.schedule());
16 }
17 }));
18 return sub;
19 });
20}
21//# sourceMappingURL=scheduleArray.js.map
Note: See TracBrowser for help on using the repository browser.