All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cn.vonce.validator.annotation.VRegex Maven / Gradle / Ivy

There is a newer version: 0.9.6
Show newest version
package cn.vonce.validator.annotation;

import cn.vonce.validator.rule.impl.ValidateRegex;

import java.lang.annotation.*;

/**
 * 校验是否符合正则表达式的规则
 *
 * @author Jovi
 * @version 1.0
 * @email [email protected]
 * @date 2020/1/21 15:49
 */
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.FIELD, ElementType.PARAMETER})
@Documented
@Validate(type = ValidateRegex.class)
public @interface VRegex {

    /**
     * 字段名称
     *
     * @return
     */
    String name() default "";

    /**
     * 消息提示
     *
     * @return
     */
    String value() default "";

    /**
     * 正则表达式
     *
     * @return
     */
    String val();

    /**
     * 分组校验
     *
     * @return
     */
    String[] group() default "";

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy