import { Context } from './context'; import { BoundValue } from './binding'; export declare type Constructor = new (...args: any[]) => T; /** * Create an instance of a class which constructor has arguments * decorated with `@inject`. * * The function returns a class when all dependencies were * resolved synchronously, or a Promise otherwise. * * @param ctor The class constructor to call. * @param ctx The context containing values for `@inject` resolution */ export declare function instantiateClass(ctor: Constructor, ctx: Context): T | Promise; /** * Given a function with arguments decorated with `@inject`, * return the list of arguments resolved using the values * bound in `ctx`. * The function returns an argument array when all dependencies were * resolved synchronously, or a Promise otherwise. * * @param fn The function for which the arguments should be resolved. * @param ctx The context containing values for `@inject` resolution */ export declare function resolveInjectedArguments(fn: Function, ctx: Context): BoundValue[] | Promise; export declare type KV = { [p: string]: BoundValue; }; export declare function resolveInjectedProperties(fn: Function, ctx: Context): KV | Promise;