import { ValidatorRule, ValidatorMessages, ValidatorData, ValidatorRuleMap, ValueMap } from '../types'; /** * Returns current validator rules in use */ export declare const getValidatorRules: () => ValidatorRuleMap; /** * Adds a custom validator rule to the validator. If the rule is * already defined, the new rule will override the original. * * @param rule new rule to be added */ export declare const addValidatorRule: (key: string, rule: ValidatorRule) => void; /** * Validate a field using the provided rules * * @param valueKey key of value to be validated * @param values values of all fields * @param targetRules validator rules to use * @param customMessages custom validator messages */ export declare const validate: (valueKey: string, values?: ValueMap, targetRules?: { readonly [name: string]: any; }, customMessages?: ValidatorMessages) => ValidatorData;