import type { Agile } from '../agile'; import { Integration } from './integration'; export declare class Integrations { agileInstance: () => Agile; integrations: Set; static initialIntegrations: Integration[]; /** * Registers the specified Integration in each existing or not-yet created Agile Instance. * * @public * @param integration - Integration to be registered in each Agile Instance. */ static addInitialIntegration(integration: Integration): void; /** * Fires on each external added Integration. * * @public * @param callback - Callback to be fired when an Integration was externally added. */ static onRegisterInitialIntegration(callback: (integration: Integration) => void): void; /** * The Integrations Class manages all Integrations for an Agile Instance * and provides an interface to easily update * and invoke functions in all registered Integrations. * * @internal * @param agileInstance - Instance of Agile the Integrations belongs to. * @param config - Configuration object */ constructor(agileInstance: Agile, config?: IntegrationsConfigInterface); /** * Integrates the specified Integration into AgileTs * and sets it to ready when the binding was successful. * * @public * @param integration - Integration to be integrated into AgileTs. */ integrate(integration: Integration): Promise; /** * Updates the specified UI-Component Instance * with the updated data object in all registered Integrations that are ready. * * In doing so, it calls the `updateMethod()` method * in all registered Integrations with the specified parameters. * * @public * @param componentInstance - Component Instance to be updated. * @param updatedData - Data object with updated data. */ update(componentInstance: any, updatedData: Object): void; /** * Returns a boolean indicating whether any Integration * has been registered with the Agile Instance or not. * * @public */ hasIntegration(): boolean; } export interface IntegrationsConfigInterface { /** * Whether external added Integrations * are to integrate automatically into the Integrations Class. * For example, when the package '@agile-ts/react' was installed, * whether to automatically integrate the 'reactIntegration'. * @default true */ autoIntegrate?: boolean; }