package de.jottyfan.camporganizer.module.registration.validate;

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 jotty
 *
 */
@Target({ ElementType.TYPE })
@Retention(RetentionPolicy.RUNTIME)
@Constraint(validatedBy = UnusedUsernameValidator.class)
@Documented
public @interface UnusedUsername {
	String message() default "username is already in use";

	String field();

	Class<?>[] groups() default {};

	Class<? extends Payload>[] payload() default {};
}
