1 | declare type Callback = (...args: any[]) => any;
|
2 | declare type AsyncFunction = (...args: any[]) => Promise<any>;
|
3 | declare class AsyncAbort {
|
4 | private id;
|
5 | private func;
|
6 | private args;
|
7 | private chains;
|
8 | constructor(func: AsyncFunction, args?: Array<any>);
|
9 | then(cb: Callback): AsyncAbort;
|
10 | catch(cb: Callback): AsyncAbort;
|
11 | finally(cb: Callback): AsyncAbort;
|
12 | call(): Callback;
|
13 | }
|
14 | export default AsyncAbort;
|