import { AnyInjectableType, InjectionToken, InjectionTokenType } from "../../token/injection-token.mjs"; import { DIError } from "../../errors/di-error.mjs"; //#region src/internal/core/token-resolver.d.mts /** * Handles token validation and resolution. * * Focuses on token validation, normalization, and argument validation. * Name generation is handled by NameResolver. */ declare class TokenResolver { private readonly logger; constructor(logger?: Console | null); /** * Normalizes a token to an InjectionToken. * Handles class constructors by getting their injectable token. * * @param token A class constructor, InjectionToken, BoundInjectionToken, or FactoryInjectionToken * @returns The normalized InjectionTokenType */ normalizeToken(token: AnyInjectableType): InjectionTokenType; /** * Gets the underlying "real" token from wrapped tokens. * For BoundInjectionToken and FactoryInjectionToken, returns the wrapped token. * For other tokens, returns the token itself. * * @param token The token to unwrap * @returns The underlying InjectionToken */ getRealToken(token: InjectionTokenType): InjectionToken; /** * Convenience method that normalizes a token and then gets the real token. * Useful for checking registry entries where you need the actual registered token. * * @param token Any injectable type * @returns The underlying InjectionToken */ getRegistryToken(token: AnyInjectableType): InjectionToken; /** * Validates and resolves token arguments, handling factory token resolution and validation. * * @param token The token to validate * @param args Optional arguments * @returns [error, { actualToken, validatedArgs }] */ validateAndResolveTokenArgs(token: AnyInjectableType, args?: any): [DIError | undefined, { actualToken: InjectionTokenType; validatedArgs?: any; }]; } //#endregion export { TokenResolver }; //# sourceMappingURL=token-resolver.d.mts.map