import { CamelCase, IValidation, PascalCase, SnakeCase } from "@typia/interface"; import { TypeGuardError } from "./TypeGuardError"; /** * Converts property names to camelCase. * * Transforms all property names in the object (including nested) to camelCase * convention. Creates a new object with renamed properties. * * Does not validate the input. For validation, use: * * - {@link assertCamel} — Throws on type mismatch * - {@link isCamel} — Returns `null` on type mismatch * - {@link validateCamel} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @returns New object with camelCase property names */ export declare function camel(input: T): CamelCase; /** * Converts property names to camelCase with assertion. * * Transforms all property names to camelCase with {@link assert} validation. * Throws {@link TypeGuardError} on type mismatch. * * Related functions: * * - {@link camel} — No validation * - {@link isCamel} — Returns `null` instead of throwing * - {@link validateCamel} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @param errorFactory Custom error factory receiving * {@link TypeGuardError.IProps} * @returns New object with camelCase property names * @throws {TypeGuardError} When input doesn't conform to type `T` */ export declare function assertCamel(input: T, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): CamelCase; /** * Converts property names to camelCase with type checking. * * Transforms all property names to camelCase with {@link is} validation. Returns * `null` on type mismatch. * * Related functions: * * - {@link camel} — No validation * - {@link assertCamel} — Throws instead of returning `null` * - {@link validateCamel} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @returns New object with camelCase property names, or `null` if invalid */ export declare function isCamel(input: T): CamelCase | null; /** * Converts property names to camelCase with validation. * * Transforms all property names to camelCase with {@link validate} validation. * Returns {@link IValidation.IFailure} with all errors on mismatch, or * {@link IValidation.ISuccess} with converted object. * * Related functions: * * - {@link camel} — No validation * - {@link assertCamel} — Throws on first error * - {@link isCamel} — Returns `null` instead of error details * * @template T Type of input value * @param input Object to convert * @returns Validation result containing converted object or errors */ export declare function validateCamel(input: T): IValidation>; /** * Converts property names to PascalCase. * * Transforms all property names in the object (including nested) to PascalCase * convention. Creates a new object with renamed properties. * * Does not validate the input. For validation, use: * * - {@link assertPascal} — Throws on type mismatch * - {@link isPascal} — Returns `null` on type mismatch * - {@link validatePascal} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @returns New object with PascalCase property names */ export declare function pascal(input: T): PascalCase; /** * Converts property names to PascalCase with assertion. * * Transforms all property names to PascalCase with {@link assert} validation. * Throws {@link TypeGuardError} on type mismatch. * * Related functions: * * - {@link pascal} — No validation * - {@link isPascal} — Returns `null` instead of throwing * - {@link validatePascal} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @param errorFactory Custom error factory receiving * {@link TypeGuardError.IProps} * @returns New object with PascalCase property names * @throws {TypeGuardError} When input doesn't conform to type `T` */ export declare function assertPascal(input: T, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): PascalCase; /** * Converts property names to PascalCase with type checking. * * Transforms all property names to PascalCase with {@link is} validation. * Returns `null` on type mismatch. * * Related functions: * * - {@link pascal} — No validation * - {@link assertPascal} — Throws instead of returning `null` * - {@link validatePascal} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @returns New object with PascalCase property names, or `null` if invalid */ export declare function isPascal(input: T): PascalCase | null; /** * Converts property names to PascalCase with validation. * * Transforms all property names to PascalCase with {@link validate} validation. * Returns {@link IValidation.IFailure} with all errors on mismatch, or * {@link IValidation.ISuccess} with converted object. * * Related functions: * * - {@link pascal} — No validation * - {@link assertPascal} — Throws on first error * - {@link isPascal} — Returns `null` instead of error details * * @template T Type of input value * @param input Object to convert * @returns Validation result containing converted object or errors */ export declare function validatePascal(input: T): IValidation>; /** * Converts property names to snake_case. * * Transforms all property names in the object (including nested) to snake_case * convention. Creates a new object with renamed properties. * * Does not validate the input. For validation, use: * * - {@link assertSnake} — Throws on type mismatch * - {@link isSnake} — Returns `null` on type mismatch * - {@link validateSnake} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @returns New object with snake_case property names */ export declare function snake(input: T): SnakeCase; /** * Converts property names to snake_case with assertion. * * Transforms all property names to snake_case with {@link assert} validation. * Throws {@link TypeGuardError} on type mismatch. * * Related functions: * * - {@link snake} — No validation * - {@link isSnake} — Returns `null` instead of throwing * - {@link validateSnake} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @param errorFactory Custom error factory receiving * {@link TypeGuardError.IProps} * @returns New object with snake_case property names * @throws {TypeGuardError} When input doesn't conform to type `T` */ export declare function assertSnake(input: T, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): SnakeCase; /** * Converts property names to snake_case with type checking. * * Transforms all property names to snake_case with {@link is} validation. * Returns `null` on type mismatch. * * Related functions: * * - {@link snake} — No validation * - {@link assertSnake} — Throws instead of returning `null` * - {@link validateSnake} — Returns detailed validation errors * * @template T Type of input value * @param input Object to convert * @returns New object with snake_case property names, or `null` if invalid */ export declare function isSnake(input: T): SnakeCase | null; /** * Converts property names to snake_case with validation. * * Transforms all property names to snake_case with {@link validate} validation. * Returns {@link IValidation.IFailure} with all errors on mismatch, or * {@link IValidation.ISuccess} with converted object. * * Related functions: * * - {@link snake} — No validation * - {@link assertSnake} — Throws on first error * - {@link isSnake} — Returns `null` instead of error details * * @template T Type of input value * @param input Object to convert * @returns Validation result containing converted object or errors */ export declare function validateSnake(input: T): IValidation>; /** * Creates reusable {@link camel} function. * * @danger You must configure the generic argument `T` */ export declare function createCamel(): never; /** * Creates reusable {@link camel} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createCamel(): (input: T) => CamelCase; /** * Creates reusable {@link assertCamel} function. * * @danger You must configure the generic argument `T` */ export declare function createAssertCamel(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): never; /** * Creates reusable {@link assertCamel} function. * * @template T Type of input value * @param errorFactory Custom error factory receiving * {@link TypeGuardError.IProps} * @returns Reusable conversion function */ export declare function createAssertCamel(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): (input: T) => CamelCase; /** * Creates reusable {@link isCamel} function. * * @danger You must configure the generic argument `T` */ export declare function createIsCamel(): never; /** * Creates reusable {@link isCamel} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createIsCamel(): (input: T) => CamelCase | null; /** * Creates reusable {@link validateCamel} function. * * @danger You must configure the generic argument `T` */ export declare function createValidateCamel(): never; /** * Creates reusable {@link validateCamel} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createValidateCamel(): (input: T) => IValidation>; /** * Creates reusable {@link pascal} function. * * @danger You must configure the generic argument `T` */ export declare function createPascal(): never; /** * Creates reusable {@link pascal} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createPascal(): (input: T) => PascalCase; /** * Creates reusable {@link assertPascal} function. * * @danger You must configure the generic argument `T` */ export declare function createAssertPascal(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): never; /** * Creates reusable {@link assertPascal} function. * * @template T Type of input value * @param errorFactory Custom error factory receiving * {@link TypeGuardError.IProps} * @returns Reusable conversion function */ export declare function createAssertPascal(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): (input: T) => PascalCase; /** * Creates reusable {@link isPascal} function. * * @danger You must configure the generic argument `T` */ export declare function createIsPascal(): never; /** * Creates reusable {@link isPascal} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createIsPascal(): (input: T) => PascalCase | null; /** * Creates reusable {@link validatePascal} function. * * @danger You must configure the generic argument `T` */ export declare function createValidatePascal(): never; /** * Creates reusable {@link validatePascal} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createValidatePascal(): (input: T) => IValidation>; /** * Creates reusable {@link snake} function. * * @danger You must configure the generic argument `T` */ export declare function createSnake(): never; /** * Creates reusable {@link snake} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createSnake(): (input: T) => SnakeCase; /** * Creates reusable {@link assertSnake} function. * * @danger You must configure the generic argument `T` */ export declare function createAssertSnake(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): never; /** * Creates reusable {@link assertSnake} function. * * @template T Type of input value * @param errorFactory Custom error factory receiving * {@link TypeGuardError.IProps} * @returns Reusable conversion function */ export declare function createAssertSnake(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): (input: T) => SnakeCase; /** * Creates reusable {@link isSnake} function. * * @danger You must configure the generic argument `T` */ export declare function createIsSnake(): never; /** * Creates reusable {@link isSnake} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createIsSnake(): (input: T) => SnakeCase | null; /** * Creates reusable {@link validateSnake} function. * * @danger You must configure the generic argument `T` */ export declare function createValidateSnake(): never; /** * Creates reusable {@link validateSnake} function. * * @template T Type of input value * @returns Reusable conversion function */ export declare function createValidateSnake(): (input: T) => IValidation>;