import { ValidationFunction, ValidationOptions, Validator } from "@n7e/validation"; /** * Has the ability to validate arbitrary objects against a given set of rules. */ declare class DefaultValidator implements Validator { /** * Default validation options. */ private static defaultOptions; /** * Default instance validation options. */ private readonly options; /** * Available validation rules. */ private readonly rules; /** * Encountered validation issues. */ private issues; /** * Create a new validator instance. * * @param rules - Available validation rules. * @param options - Default instance validation options. */ constructor(rules: Map, options?: Partial); /** {@inheritDoc} */ validate(target: Object, rules: { [property: string]: string; }, options?: Partial): Promise; /** * Validate target property against given rules. * * @param target - Arbitrary target. * @param property - Target property. * @param rules - Rules to validate property against. * @param strategy - Validation strategy. * @returns Promise resolving when the operation is done. */ private validateTarget; /** * Validate target property against a given rule. * * @param target - Arbitrary target. * @param property - Target property. * @param rule - Rule to validate property against. * @returns Promise resolving when the operation is done. */ private check; /** * Checks the presence of the given target property. * * @param target - Arbitrary target. * @param property - Property to check for. */ private checkPresence; /** * Extract the logical parts of a given rule. * * @param rule - Arbitrary rule. * @returns Logical rule parts. */ private parse; } export default DefaultValidator;