import { TypeParameter, TypeProperty, TypePropertySignature } from '../reflection/type.js'; /** Property-like types that have a name and type. */ export type PropertyLikeType = TypeProperty | TypePropertySignature | TypeParameter; /** * Controls how property names are transformed during serialization. * * Make sure to change the id when implementing a custom naming strategy, * since caches are based on it. * * @example * ```typescript * class MyNamingStrategy extends NamingStrategy { * constructor() { * super('my-strategy'); * } * * getPropertyName(type: PropertyLikeType, forSerializer: string): string | undefined { * const name = super.getPropertyName(type, forSerializer); * return name ? name.toUpperCase() : undefined; * } * } * ``` */ export declare class NamingStrategy { id: string; constructor(id?: string); /** Pre-formatted cache key prefix: `{id}_`. Lazily computed. */ _cacheKeyPrefix?: string; /** * Get the serialized property name for a type property. * * @param type - The property type * @param forSerializer - The serializer name (e.g., 'json', 'bson') * @returns The property name to use, or undefined to skip */ getPropertyName(type: PropertyLikeType, forSerializer: string): string | undefined; } /** * Built-in naming strategy that converts camelCase to snake_case. * * @example * ```typescript * // With underscoreNamingStrategy: * // userName -> user_name * // firstName -> first_name * // HTTPResponse -> _h_t_t_p_response * ``` */ /** Default naming strategy singleton. Avoids allocating a new instance on every call. */ export declare const defaultNamingStrategy: NamingStrategy; export declare const underscoreNamingStrategy: { getPropertyName(type: PropertyLikeType, forSerializer: string): string | undefined; id: string; /** Pre-formatted cache key prefix: `{id}_`. Lazily computed. */ _cacheKeyPrefix?: string; }; export declare type __ΩPropertyLikeType = any[];