typia
Version:
Superfast runtime validators with only one line
696 lines (695 loc) • 31.6 kB
TypeScript
import { StandardSchemaV1 } from "@standard-schema/spec";
import { AssertionGuard } from "./AssertionGuard";
import { IRandomGenerator } from "./IRandomGenerator";
import { IValidation } from "./IValidation";
import { Resolved } from "./Resolved";
import { TypeGuardError } from "./TypeGuardError";
export * as functional from "./functional";
export * as http from "./http";
export * as llm from "./llm";
export * as json from "./json";
export * as misc from "./misc";
export * as notations from "./notations";
export * as protobuf from "./protobuf";
export * as reflect from "./reflect";
export * as tags from "./tags";
export * from "./schemas/metadata/IJsDocTagInfo";
export * from "./schemas/json/IJsonApplication";
export * from "./schemas/json/IJsonSchemaCollection";
export * from "./schemas/json/IJsonSchemaUnit";
export * from "./AssertionGuard";
export * from "./IRandomGenerator";
export * from "./IValidation";
export * from "./TypeGuardError";
export * from "./Primitive";
export * from "./Resolved";
export * from "./CamelCase";
export * from "./PascalCase";
export * from "./SnakeCase";
export * from "./IReadableURLSearchParams";
/**
* Asserts a value type.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with a
* detailed reason, if the parametric value is not following the type `T`.
* Otherwise, if the value is following the type `T`, the input parameter will
* be returned.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link is} function
* instead. Otherwise, if you want to know all the errors, {@link validate} is
* the way to go. Also, if you want to automatically cast the parametric value
* to the type `T` when there is no problem (perform the assertion guard of
* type).
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link assertEquals} function
* instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Parametric input value
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assert<T>(input: T, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): T;
/**
* Asserts a value type.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with a
* detailed reason, if the parametric value is not following the type `T`.
* Otherwise, if the value is following the type `T`, the input parameter will
* be returned.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link is} function
* instead. Otherwise, if you want to know all the errors, {@link validate} is
* the way to go.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link assertEquals} function
* instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Parametric input value casted as `T`
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assert<T>(input: unknown, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): T;
/**
* Assertion guard of a value type.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with a
* detailed reason, if the parametric value is not following the type `T`.
* Otherwise, if the value is following the type `T`, nothing will be returned,
* but the input value will be automatically casted to the type `T`. This is the
* concept of "Assertion Guard" of a value type.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link is} function
* instead. Otherwise, if you want to know all the errors, {@link validate} is
* the way to go. Also, if you want to return the parametric value when there is
* no problem, you can use {@link assert} function instead.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link assertGuardEquals}
* function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assertGuard<T>(input: T, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): asserts input is T;
/**
* Assertion guard of a value type.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with a
* detailed reason, if the parametric value is not following the type `T`.
* Otherwise, if the value is following the type `T`, nothing will be returned,
* but the input value will be automatically casted to the type `T`. This is the
* concept of "Assertion Guard" of a value type.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link is} function
* instead. Otherwise, if you want to know all the errors, {@link validate} is
* the way to go. Also, if you want to return the parametric value when there is
* no problem, you can use {@link assert} function instead.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link assertGuardEquals}
* function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assertGuard<T>(input: unknown, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): asserts input is T;
/**
* Tests a value type.
*
* Tests a parametric value type and returns whether it's following the type `T`
* or not. If the parametric value is matched with the type `T`, `true` value
* will be returned. Otherwise, if the parametric value is not following the
* type `T`, `false` value will be returned.
*
* If what you want is not just knowing whether the parametric value is
* following the type `T` or not, but throwing an exception with a detailed
* reason, you can choose {@link assert} function instead. Also, if you want to
* know all the errors with detailed reasons, {@link validate} function will be
* useful.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link equals} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be tested
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Whether the parametric value is following the type `T` or not
*/
export declare function is<T>(input: T): input is T;
/**
* Tests a value type.
*
* Tests a parametric value type and returns whether it's following the type `T`
* or not. If the parametric value is matched with the type `T`, `true` value
* will be returned. Otherwise, if the parametric value is not following the
* type `T`, `false` value will be returned.
*
* If what you want is not just knowing whether the parametric value is
* following the type `T` or not, but throwing an exception with a detailed
* reason, you can choose {@link assert} function instead. Also, if you want to
* know all the errors with detailed reasons, {@link validate} function will be
* useful.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link equals} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be tested
* @returns Whether the parametric value is following the type `T` or not
*/
export declare function is<T>(input: unknown): input is T;
/**
* Validates a value type.
*
* Validates a parametric value type and archives all the type errors into an
* {@link IValidation.errors} array, if the parametric value is not following the
* type `T`. Of course, if the parametric value is following the type `T`, the
* {@link IValidation.errors} array will be empty and {@link IValidation.success}
* will have the `true` value.
*
* If what you want is not finding all the errors, but asserting the parametric
* value type with exception throwing, you can choose {@link assert} function
* instead. Otherwise, if you just want to know whether the parametric value is
* matched with the type `T`, {@link is} function is the way to go.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link validateEquals} function
* instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be validated
* @returns Validation result
*/
export declare function validate<T>(input: T): IValidation<T>;
/**
* Validates a value type.
*
* Validates a parametric value type and archives all the type errors into an
* {@link IValidation.errors} array, if the parametric value is not following the
* type `T`. Of course, if the parametric value is following the type `T`, the
* {@link IValidation.errors} array will be empty and {@link IValidation.success}
* will have the `true` value.
*
* If what you want is not finding all the errors, but asserting the parametric
* value type with exception throwing, you can choose {@link assert} function
* instead. Otherwise, if you just want to know whether the parametric value is
* matched with the type `T`, {@link is} function is the way to go.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link validateEquals} function
* instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be validated
* @returns Validation result
*/
export declare function validate<T>(input: unknown): IValidation<T>;
/**
* Asserts equality between a value and its type.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with
* detailed reason, if the parametric value is not following the type `T` or
* some superfluous property that is not listed on the type `T` has been found.
* Otherwise, the value is following the type `T` without any superfluous
* property, just input parameter would be returned.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link equals}
* function instead. Otherwise, if you want to know all the errors,
* {@link validateEquals} is the way to go.
*
* On the other hand, if you want to allow superfluous property that is not
* enrolled to the type `T`, you can use {@link assert} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Parametric input value
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assertEquals<T>(input: T, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): T;
/**
* Asserts equality between a value and its type.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with
* detailed reason, if the parametric value is not following the type `T` or
* some superfluous property that is not listed on the type `T` has been found.
* Otherwise, the value is following the type `T` without any superfluous
* property, just input parameter would be returned.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link equals}
* function instead. Otherwise, if you want to know all the errors,
* {@link validateEquals} is the way to go.
*
* On the other hand, if you want to allow superfluous property that is not
* enrolled to the type `T`, you can use {@link assert} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Parametric input value casted as `T`
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assertEquals<T>(input: unknown, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): T;
/**
* Assertion guard of a type with equality.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with
* detailed reason, if the parametric value is not following the type `T` or
* some superfluous property that is not listed on the type `T` has been found.
*
* Otherwise, the value is following the type `T` without any superfluous
* property, nothing will be returned, but the input value would be
* automatically casted to the type `T`. This is the concept of "Assertion
* Guard" of a value type.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link equals}
* function instead. Otherwise, if you want to know all the errors,
* {@link validateEquals} is the way to go. Also, if you want to returns the
* parametric value when no problem, you can use {@link assert} function
* instead.
*
* On the other hand, if you want to allow superfluous property that is not
* enrolled to the type `T`, you can use {@link assertEquals} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Parametric input value casted as `T`
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assertGuardEquals<T>(input: T, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): asserts input is T;
/**
* Assertion guard of a type with equality.
*
* Asserts a parametric value type and throws a {@link TypeGuardError} with
* detailed reason, if the parametric value is not following the type `T` or
* some superfluous property that is not listed on the type `T` has been found.
*
* Otherwise, the value is following the type `T` without any superfluous
* property, nothing will be returned, but the input value would be
* automatically casted to the type `T`. This is the concept of "Assertion
* Guard" of a value type.
*
* If what you want is not asserting but just knowing whether the parametric
* value is following the type `T` or not, you can choose the {@link equals}
* function instead. Otherwise, if you want to know all the errors,
* {@link validateEquals} is the way to go. Also, if you want to returns the
* parametric value when no problem, you can use {@link assertEquals} function
* instead.
*
* On the other hand, if you want to allow superfluous property that is not
* enrolled to the type `T`, you can use {@link assertGuard} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be asserted
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Parametric input value casted as `T`
* @throws A {@link TypeGuardError} instance with a detailed reason
*/
export declare function assertGuardEquals<T>(input: unknown, errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): asserts input is T;
/**
* Tests equality between a value and its type.
*
* Tests a parametric value type and returns whether it's equivalent to the type
* `T` or not. If the parametric value is matched with the type `T` and there's
* not any superfluous property that is not listed on the type `T`, `true` value
* will be returned. Otherwise, if the parametric value is not following the
* type `T` or some superfluous property exists, `false` value will be
* returned.
*
* If what you want is not just knowing whether the parametric value is
* following the type `T` or not, but throwing an exception with a detailed
* reason, you can choose {@link assertEquals} function instead. Also, if you
* want to know all the errors with detailed reasons, {@link validateEquals}
* function will be useful.
*
* On the other hand, if you want to allow superfluous property that is not
* enrolled to the type `T`, you can use {@link is} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be tested
* @returns Whether the parametric value is equivalent to the type `T` or not
*/
export declare function equals<T>(input: T): input is T;
/**
* Tests equality between a value and its type.
*
* Tests a parametric value type and returns whether it's equivalent to the type
* `T` or not. If the parametric value is matched with the type `T` and there's
* not any superfluous property that is not listed on the type `T`, `true` value
* will be returned. Otherwise, if the parametric value is not following the
* type `T` or some superfluous property exists, `false` value will be
* returned.
*
* If what you want is not just knowing whether the parametric value is
* following the type `T` or not, but throwing an exception with a detailed
* reason, you can choose {@link assertEquals} function instead. Also, if you
* want to know all the errors with detailed reasons, {@link validateEquals}
* function will be useful.
*
* On the other hand, if you want to allow superfluous property that is not
* enrolled to the type `T`, you can use {@link is} function instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param input A value to be tested
* @returns Whether the parametric value is equivalent to the type `T` or not
*/
export declare function equals<T>(input: unknown): input is T;
/**
* Validates equality between a value and its type.
*
* Validates a parametric value type and archives all the type errors into an
* {@link IValidation.errors} array, if the parametric value is not following the
* type `T` or some superfluous property that is not listed on the type `T` has
* been found. Of course, if the parametric value is following the type `T` and
* no superfluous property exists, the {@link IValidation.errors} array would be
* empty and {@link IValidation.success} would have the `true` value.
*
* If what you want is not finding all the error, but asserting the parametric
* value type with exception throwing, you can choose {@link assert} function
* instead. Otherwise, you just want to know whether the parametric value is
* matched with the type `T`, {@link is} function is the way to go.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link validateEquals} function
* instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template Type Of the input value
* @param input A value to be validated
* @returns Validation result
*/
export declare function validateEquals<T>(input: T): IValidation<T>;
/**
* Validates equality between a value and its type.
*
* Validates a parametric value type and archives all the type errors into an
* {@link IValidation.errors} array, if the parametric value is not following the
* type `T` or some superfluous property that is not listed on the type `T` has
* been found. Of course, if the parametric value is following the type `T` and
* no superfluous property exists, the {@link IValidation.errors} array would be
* empty and {@link IValidation.success} would have the `true` value.
*
* If what you want is not finding all the error, but asserting the parametric
* value type with exception throwing, you can choose {@link assert} function
* instead. Otherwise, you just want to know whether the parametric value is
* matched with the type `T`, {@link is} function is the way to go.
*
* On the other hand, if you don't want to allow any superfluous property that
* is not enrolled to the type `T`, you can use {@link validateEquals} function
* instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template Type Of the input value
* @param input A value to be validated
* @returns Validation result
*/
export declare function validateEquals<T>(input: unknown): IValidation<T>;
/**
* > You must configure the generic argument `T`.
*
* Generate random data.
*
* Generates a random data following type the `T`.
*
* For reference, this `typia.random()` function generates only primitive type.
* If there're some methods in the type `T` or its nested instances, those would
* be ignored. Also, when the type `T` has a `toJSON()` method, its return type
* will be generated instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of data to generate
* @param generator Random data generator
* @returns Randomly generated data
*/
export declare function random(generator?: Partial<IRandomGenerator>): never;
/**
* Generate random data.
*
* Generates a random data following type the `T`.
*
* For reference, this `typia.random()` function generates only primitive type.
* If there're some methods in the type `T` or its nested instances, those would
* be ignored. Also, when the type `T` has a `toJSON()` method, its return type
* will be generated instead.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of data to generate
* @param generator Random data generator
* @returns Randomly generated data
*/
export declare function random<T>(generator?: Partial<IRandomGenerator>): Resolved<T>;
/**
* Creates a reusable {@link assert} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createAssert(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): never;
/**
* Creates a reusable {@link assert} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns A reusable `assert` function
*/
export declare function createAssert<T>(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): (input: unknown) => T;
/**
* Creates a reusable {@link assertGuard} function.
*
* Note that, you've to declare the variable type of the factory function caller
* like below. If you don't declare the variable type, compilation error be
* thrown. This is the special rule of the TypeScript compiler.
*
* ```typescript
* // MUST DECLARE THE VARIABLE TYPE
* const func: typia.AssertionGuard<number> = typia.createAssertGuard<number>();
*
* // IF NOT, COMPILATION ERROR BE OCCURRED
* const func = typia.createAssertGuard<number>();
* ```
*
* > _Assertions require every name in the call target to be declared with an_
* > _explicit type annotation._
*
* @author Jeongho Nam - https://github.com/samchon
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createAssertGuard(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): never;
/**
* Creates a reusable {@link assertGuard} function.
*
* Note that, you've to declare the variable type of the factory function caller
* like below. If you don't declare the variable type, compilation error be
* thrown. This is the special rule of the TypeScript compiler.
*
* ```typescript
* // MUST DECLARE THE VARIABLE TYPE
* const func: typia.AssertionGuard<number> = typia.createAssertGuard<number>();
*
* // IF NOT, COMPILATION ERROR BE OCCURRED
* const func = typia.createAssertGuard<number>();
* ```
*
* > _Assertions require every name in the call target to be declared with an_
* > _explicit type annotation._
*
* @author Jeongho Nam - https://github.com/samchon
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
*/
export declare function createAssertGuard<T>(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): (input: unknown) => AssertionGuard<T>;
/**
* Creates a reusable {@link is} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createIs(): never;
/**
* Creates a reusable {@link is} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @returns A reusable `is` function
*/
export declare function createIs<T>(): (input: unknown) => input is T;
/**
* Creates a reusable {@link validate} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createValidate(): never;
/**
* Creates a reusable {@link validate} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @returns A reusable `validate` function
*/
export declare function createValidate<T>(): ((input: unknown) => IValidation<T>) & StandardSchemaV1<unknown, T>;
/**
* Creates a reusable {@link assertEquals} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createAssertEquals(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): never;
/**
* Creates a reusable {@link assertEquals} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns A reusable `assertEquals` function
*/
export declare function createAssertEquals<T>(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): (input: unknown) => T;
/**
* Creates a reusable {@link assertGuardEquals} function.
*
* Note that, you've to declare the variable type of the factory function caller
* like below. If you don't declare the variable type, compilation error be
* thrown. This is the special rule of the TypeScript compiler.
*
* ```typescript
* // MUST DECLARE THE VARIABLE TYPE
* const func: typia.AssertionGuard<number> = typia.createAssertGuardEquals<number>();
*
* // IF NOT, COMPILATION ERROR BE OCCURRED
* const func = typia.createAssertGuardEquals<number>();
* ```
*
* > _Assertions require every name in the call target to be declared with an_
* > _explicit type annotation._
*
* @author Jeongho Nam - https://github.com/samchon
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createAssertGuardEquals(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): never;
/**
* Creates a reusable {@link assertGuardEquals} function.
*
* Note that, you've to declare the variable type of the factory function caller
* like below. If you don't declare the variable type, compilation error be
* thrown. This is the special rule of the TypeScript compiler.
*
* ```typescript
* // MUST DECLARE THE VARIABLE TYPE
* const func: typia.AssertionGuard<number> = typia.createAssertGuardEquals<number>();
*
* // IF NOT, COMPILATION ERROR BE OCCURRED
* const func = typia.createAssertGuardEquals<number>();
* ```
*
* > _Assertions require every name in the call target to be declared with an_
* > _explicit type annotation._
*
* @author Jeongho Nam - https://github.com/samchon
* @param errorFactory Custom error factory. Default is `TypeGuardError`
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
*/
export declare function createAssertGuardEquals<T>(errorFactory?: undefined | ((props: TypeGuardError.IProps) => Error)): (input: unknown) => AssertionGuard<T>;
/**
* Creates a reusable {@link equals} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createEquals(): never;
/**
* Creates a reusable {@link equals} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @returns A reusable `equals` function
*/
export declare function createEquals<T>(): (input: unknown) => input is T;
/**
* Creates a reusable {@link validateEquals} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createValidateEquals(): never;
/**
* Creates a reusable {@link validateEquals} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @returns A reusable `validateEquals` function
*/
export declare function createValidateEquals<T>(): ((input: unknown) => IValidation<T>) & StandardSchemaV1<unknown, T>;
/**
* Creates a reusable {@link random} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @param generator Random data generator
* @returns Nothing until you configure the generic argument `T`
* @throws Compile error
* @danger You must configure the generic argument `T`
*/
export declare function createRandom(generator?: Partial<IRandomGenerator>): never;
/**
* Creates a reusable {@link random} function.
*
* @author Jeongho Nam - https://github.com/samchon
* @template T Type of the input value
* @param generator Random data generator
* @returns A reusable `random` function
*/
export declare function createRandom<T>(generator?: Partial<IRandomGenerator>): () => Resolved<T>;