package com.demo.persistence.validator;

import static java.lang.annotation.ElementType.FIELD;
import static java.lang.annotation.ElementType.METHOD;
import static java.lang.annotation.RetentionPolicy.RUNTIME;

import java.lang.annotation.Documented;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;
import org.hibernate.validator.ValidatorClass;
import com.demo.persistence.validator.MandatoryValidator;

 * Designates a property that is required to have a value. It cannot be null or
 * empty. The default message is "validator.required" which is assumed to exist
 * in the expected resource bundle
 * @author alexiaa
 * @version $Revision: 2$
@Target( { METHOD, FIELD })
public @interface Mandatory {
    /** Default message. */
    String message() default "Property marked as mandatory and cannot be left blank.";