import { ShowAlert } from '../../@types/types'; import * as i0 from "@angular/core"; export interface UserWaitingOptions { name: string; showAlert?: ShowAlert; totalReqWait: number; updateTotalReqWait: (total: number) => void; } export type UserWaitingType = (options: UserWaitingOptions) => Promise; /** * Service for handling user waiting room actions, including notifications and updating request counts. * * @class * @name UserWaiting * @description Manages the logic when a user joins the waiting room by displaying alerts and incrementing the total request count. * * @method * userWaiting * @async * * @param {UserWaitingOptions} options - The options for handling user waiting actions: * - `name` {string}: Name of the user joining the waiting room. * - `showAlert` {ShowAlert}: Optional function for showing an alert with a customizable message, type, and duration. * - `totalReqWait` {number}: Current count of waiting requests. * - `updateTotalReqWait` {Function}: Updates the total waiting request count. * * @returns {Promise} Resolves after alert is shown and request count is updated. * * @example * const options = { * name: 'Alice', * showAlert: ({ message, type, duration }) => console.log(message), * totalReqWait: 3, * updateTotalReqWait: (newTotal) => console.log(`Updated count: ${newTotal}`) * }; * await userWaitingService.userWaiting(options); */ export declare class UserWaiting { userWaiting: ({ name, showAlert, totalReqWait, updateTotalReqWait, }: UserWaitingOptions) => Promise; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; }