declare abstract class CallbackCollectionBase any> { protected __callbacks: Set; /** * Adds a callback. * @param callback The callback to add. */ add(callback: C): DestroyFunction; /** * Removes the callback. * @param callback The callback to remove. */ remove(callback: C): void; /** * Removes all callbacks. */ clear(): void; /** * Returns a frozen object containig the add and remove methods. Useful for exposing these methods to the public * without also exposing the trigger method. */ getManipulators(): Readonly<{ add: (callback: C) => DestroyFunction; remove: (callback: C) => void; }>; } /** * A collection of callbacks. */ export declare class CallbackCollection any> extends CallbackCollectionBase { /** * Calls all registered callbacks with the provided arguments. * @param args The parametes for the callback invocations. */ trigger(...args: Parameters): PromiseSettledResult>[]; } /** * A collection of asynchronous callbacks. */ export declare class AsyncCallbackCollection Promise> extends CallbackCollectionBase { /** * Calls all registered callbacks with the provided arguments. * @param args The parametes for the callback invocations. */ trigger(...args: Parameters): Promise>>[]>; } /** * A function that removes the callback from the collection when called. */ type DestroyFunction = () => void; export {}; //# sourceMappingURL=CallbackCollection.d.ts.map