import { PromiseInspection } from './PromiseInspection'; export interface Deferred { resolve: (val: T) => any; reject: (err: T) => any; promise: Promise; } export declare function defer(): Deferred; export declare function now(): number; export declare function duration(t1: number, t2: number): number; export declare function checkOptionalTime(time?: number): boolean; export declare function checkRequiredTime(time: number): boolean; export declare function delay(millis: number): Promise<{}>; export declare function reflect(promise: Promise): Promise | PromiseInspection<{}>>; export declare function tryPromise(cb: () => T | PromiseLike): Promise;