minor adjustment to readme
[dotfiles/.git] / .config / coc / extensions / node_modules / coc-prettier / node_modules / rxjs / _esm2015 / internal / scheduler / QueueAction.js
1 import { AsyncAction } from './AsyncAction';
2 export class QueueAction extends AsyncAction {
3     constructor(scheduler, work) {
4         super(scheduler, work);
5         this.scheduler = scheduler;
6         this.work = work;
7     }
8     schedule(state, delay = 0) {
9         if (delay > 0) {
10             return super.schedule(state, delay);
11         }
12         this.delay = delay;
13         this.state = state;
14         this.scheduler.flush(this);
15         return this;
16     }
17     execute(state, delay) {
18         return (delay > 0 || this.closed) ?
19             super.execute(state, delay) :
20             this._execute(state, delay);
21     }
22     requestAsyncId(scheduler, id, delay = 0) {
23         if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) {
24             return super.requestAsyncId(scheduler, id, delay);
25         }
26         return scheduler.flush(this);
27     }
28 }
29 //# sourceMappingURL=QueueAction.js.map