declare class Promise implements DojoJS.Thenable { /** * Add new callbacks to the promise. */ then(callback?: ((result: T) => U | DojoJS.Thenable) | null, errback?: ((error: any) => U | DojoJS.Thenable | void) | null, progback?: ((progress: any) => void) | null): Promise; /** * Inform the deferred it may cancel its asynchronous operation. */ cancel(reason?: any, strict?: boolean): any; /** * Checks whether the promise has been resolved. */ isResolved(): boolean; /** * Checks whether the promise has been rejected. */ isRejected(): boolean; /** * Checks whether the promise has been resolved or rejected. */ isFulfilled(): boolean; /** * Checks whether the promise has been canceled. */ isCanceled(): boolean; /** * Add a callback to be invoked when the promise is resolved * or rejected. */ always(callbackOrErrback: (result: T) => U | DojoJS.Thenable | void): Promise; /** * Add new errbacks to the promise. Follows ECMA specification naming. */ catch(errback: (error: any) => U | DojoJS.Thenable): Promise; /** * Add new errbacks to the promise. */ otherwise(errback: (error: any) => U | DojoJS.Thenable): Promise; trace(): this; traceRejected(): this; toString(): string; } declare global { namespace DojoJS { interface Thenable { /** * Add new callbacks to the promise. */ then(callback?: ((result: T) => U | Thenable) | null, errback?: ((error: any) => U | Thenable | void) | null, progback?: ((progress: any) => void) | null): Promise; } type Promise = InstanceType>; } } export = Promise; //# sourceMappingURL=Promise.d.ts.map