@shopware-ag/dive
Version:
Shopware Spatial Framework
19 lines (18 loc) • 849 B
TypeScript
export declare class DIVEDeferredPromise<T> implements Promise<T> {
readonly isDIVEDeferredPromise: true;
readonly [Symbol.toStringTag]: string;
private _promise;
private _resolve;
private _reject;
private _settled;
constructor();
get settled(): boolean;
get pending(): boolean;
then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | null, onrejected?: ((reason: unknown) => TResult2 | PromiseLike<TResult2>) | null): Promise<TResult1 | TResult2>;
catch<TResult = never>(onrejected?: ((reason: unknown) => TResult | PromiseLike<TResult>) | null): Promise<T | TResult>;
finally(onfinally?: (() => void) | null): Promise<T>;
resolve(value: T | PromiseLike<T>): void;
reject(reason?: unknown): void;
reset(): this;
private _createPromise;
}