import 'reflect-metadata'; import { Injector } from '@alterior/di'; import { ApplicationOptions } from './app-options'; import { Runtime } from './modules'; export declare class ApplicationOptionsRef { constructor(options: ApplicationOptions); readonly options: ApplicationOptions; } /** * Represents the current runtime execution context. * This is exposed via a zone-local variable, and the Runtime * populates it with useful information as it becomes available. */ export declare class ExecutionContext { /** * Retrieve the Alterior application which is currently being executed. * If an application has not been bootstrapped yet, the value is null. */ private _application; get application(): Application; /** * Optionally acquire the current application. This may be needed for getters that can run before the application * is fully built. */ set application(value: Application); /** * Optionally acquire the current application. This may be needed for getters that can run before the application * is fully built. */ get optionalApplication(): Application | undefined; static readonly ZONE_LOCAL_NAME = "@alterior/runtime:ExecutionContext"; /** * Get the current execution context, if any. */ static get current(): ExecutionContext; /** * Execute the given function in a new zone which has * this ExecutionContext instance as the current execution context. */ run(callback: () => Promise): Promise; runSync(callback: () => T): T; } /** * Handles bootstrapping the application. */ export declare class Application { readonly runtime: Runtime; private _optionsRef; private _args; start(): void; stop(): void; get injector(): Injector; inject(ctor: { new (...args: any[]): T; }, notFoundValue?: T): T; get args(): string[]; get options(): ApplicationOptions; private static loadOptions; private static validateEntryModule; /** * Bootstrap an Alterior application. */ static bootstrap(entryModule: Function, options?: ApplicationOptions): Application; } //# sourceMappingURL=application.d.ts.map