/**
* DevExtreme (ui/validation_rules.d.ts)
* Version: 21.1.0 (build 21016-0316)
* Build date: Sat Jan 16 2021
*
* Copyright (c) 2012 - 2021 Developer Express Inc. ALL RIGHTS RESERVED
* Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/
*/
/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface AsyncRule {
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    message?: string;
    /**
     */
    reevaluate?: boolean;
    /**
     */
    type: 'async';
    /**
     */
    validationCallback?: ((options: { value?: string | number, rule?: any, validator?: any, data?: any, column?: any, formItem?: any }) => Promise<any> | JQueryPromise<any>);
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface CompareRule {
    /**
     */
    comparisonTarget?: (() => any);
    /**
     */
    comparisonType?: '!=' | '!==' | '<' | '<=' | '==' | '===' | '>' | '>=';
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    message?: string;
    /**
     */
    reevaluate?: boolean;
    /**
     */
    type: 'compare';
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface CustomRule {
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    message?: string;
    /**
     */
    reevaluate?: boolean;
    /**
     */
    type: 'custom';
    /**
     */
    validationCallback?: ((options: { value?: string | number, rule?: any, validator?: any, data?: any, column?: any, formItem?: any }) => boolean);
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface EmailRule {
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    message?: string;
    /**
     */
    type: 'email';
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface NumericRule {
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    message?: string;
    /**
     */
    type: 'numeric';
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface PatternRule {
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    message?: string;
    /**
     */
    pattern?: RegExp | string;
    /**
     */
    type: 'pattern';
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface RangeRule {
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    max?: Date | number;
    /**
     */
    message?: string;
    /**
     */
    min?: Date | number;
    /**
     */
    reevaluate?: boolean;
    /**
     */
    type: 'range';
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface RequiredRule {
    /**
     */
    message?: string;
    /**
     */
    trim?: boolean;
    /**
     */
    type: 'required';
}

/**
 * Warning! This type is used for internal purposes. Do not import it directly.
 */
export interface StringLengthRule {
    /**
     */
    ignoreEmptyValue?: boolean;
    /**
     */
    max?: number;
    /**
     */
    message?: string;
    /**
     */
    min?: number;
    /**
     */
    trim?: boolean;
    /**
     */
    type: 'stringLength';
}
