import { DynamicModule } from '@nestjs/common'; import { Constructor } from '@rsdk/common'; import type { PlatformOptions } from '../types'; import type { Config } from './config.abstract'; import type { ConfigSource } from './sources'; import type { AppNameStrategyType } from './types'; export interface ConfigModuleOptions { /** * By convention every configuration key should have unique prefix * for current service. It is inferred from application name */ appName: string; /** * Additional asynchronous configuration sources. For example a source * that loads configuration from Consul or other remote system. */ sources?: Constructor[]; /** * Strategy for detect key name for get config values from environments (default: AppNameStrategyType.PLATFORM) */ appNameStrategy?: AppNameStrategyType; } export declare class PlatformConfigModule { /** * Use this method to imports specific configuration property * into given module * * @param alias It's not so easy to use plain property key because * of prefix and source key issues. That's why we use aliases. Specify * the same string that was used to define property in * @Property() or @ExtraEnv() decorator. * * @returns DynamicModule */ static forProperty(alias: string): DynamicModule; static createConfigProvider(ctor: Constructor): DynamicModule; static forRoot(options: PlatformOptions): DynamicModule; private static getPropertyProvider; /** * Use this method to import specified configuration section * into given module * @param ctor Pass constructor of configuration section class * @returns DynamicModule */ static forFeature(ctor: Constructor): DynamicModule; }