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

love.keeping.starter.web.components.validation.IsEnum Maven / Gradle / Ivy

The newest version!
package love.keeping.starter.web.components.validation;

import love.keeping.starter.web.enums.BaseEnum;

import java.io.Serializable;
import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
import javax.validation.Constraint;
import javax.validation.Payload;

/**
 * 校验枚举类型
 *
 * @author Keeping
 */
@Target({ElementType.FIELD, ElementType.PARAMETER})
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Constraint(validatedBy = EnumValidator.class)
public @interface IsEnum {

  String message();

  Class[] groups() default {};

  Class[] payload() default {};

  Class> enumClass();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy