@athenna/ioc
Version:
Global Ioc helper for Athenna ecosystem. Built on top of awilix.
35 lines (34 loc) • 866 B
TypeScript
/**
* @athenna/ioc
*
* (c) João Lenon <lenon@athenna.io>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
import type { ServiceOptions } from '#src';
export type ServiceMeta = {
type: string;
alias: string;
camelAlias?: string;
registered: boolean;
[key: string]: any;
};
export declare class Annotation {
/**
* Verify if provider is decorated or not.
*/
static isAnnotated(target: any): boolean;
/**
* Define all metadata for a service.
*/
static defineMeta(target: any, options: ServiceOptions): void;
/**
* Define the service as registered.
*/
static defineAsRegistered(target: any): void;
/**
* Get all the metadata from the service.
*/
static getMeta(target: any): ServiceMeta;
}