UNPKG

1.55 kBTypeScriptView Raw
1import type { Container } from "../Core/Container";
2import type { RecursivePartial } from "../Types";
3import type { IOptions } from "../Options/Interfaces/IOptions";
4import type { Options } from "../Options/Classes/Options";
5import type { IContainerPlugin, IInteractor, IMovePathGenerator, IParticleUpdater, IPlugin, IShapeDrawer } from "../Core/Interfaces";
6export declare class Plugins {
7 static getPlugin(plugin: string): IPlugin | undefined;
8 static addPlugin(plugin: IPlugin): void;
9 static getAvailablePlugins(container: Container): Map<string, IContainerPlugin>;
10 static loadOptions(options: Options, sourceOptions: RecursivePartial<IOptions>): void;
11 static getPreset(preset: string): RecursivePartial<IOptions> | undefined;
12 static addPreset(presetKey: string, options: RecursivePartial<IOptions>, override?: boolean): void;
13 static addShapeDrawer(type: string, drawer: IShapeDrawer): void;
14 static getShapeDrawer(type: string): IShapeDrawer | undefined;
15 static getSupportedShapes(): IterableIterator<string>;
16 static getPathGenerator(type: string): IMovePathGenerator | undefined;
17 static addPathGenerator(type: string, pathGenerator: IMovePathGenerator): void;
18 static getInteractors(container: Container): IInteractor[];
19 static addInteractor(name: string, initInteractor: (container: Container) => IInteractor): void;
20 static getUpdaters(container: Container): IParticleUpdater[];
21 static addParticleUpdater(name: string, initUpdater: (container: Container) => IParticleUpdater): void;
22}