import { ISimulation, SimulatorResponse, SimulatorRequest, NextSimulator, IDisposable, SimulationHandler, EngineConfig } from "./common/types"; import * as simulators from "./simulators"; import { SourceLayer } from "./extesions/source"; /** * Place where we load/unload simulators. It is also the primary entry-point for all requests. */ export declare class MockingEngine implements ISimulation { private config?; namespace: string; protected simulatorLayers: ISimulation[]; constructor(config?: EngineConfig | undefined); /** * Load the simulators * @param simulators array of simulator instances */ loadSimulators(simulators: ISimulation | ISimulation[]): IDisposable[]; /** * Return the instance of the SourceLayer */ getSourceLayer(): SourceLayer | undefined; private internalLoad; unloadSimulator(simulator: ISimulation): void; getSimulatorHandler(namespace: string): T | undefined; /** * This function is used to export out all of the layer handlers. * The handlers are then imported into express route. * * @returns SimulationHandler[] */ getSimulatorHandlers(): SimulationHandler[]; ingest(req: SimulatorRequest, res: SimulatorResponse, next: NextSimulator): any; /** * Load all simulators. This is an internal function. * NOTE: this function should dynamically load all of the simulators * that live in the `simulators` folder. */ private internalLoadSimulators; private loadStoreLayer; }