org.hibernate.validator.util
Class ValidatorTypeHelper

java.lang.Object
  extended by org.hibernate.validator.util.ValidatorTypeHelper

public final class ValidatorTypeHelper
extends java.lang.Object

Helper methods around ConstraintValidator types.

Author:
Emmanuel Bernanrd, Hardy Ferentschik

Method Summary
static
<T extends java.lang.annotation.Annotation>
java.util.Map<java.lang.reflect.Type,java.lang.Class<? extends javax.validation.ConstraintValidator<?,?>>>
getValidatorsTypes(java.util.List<java.lang.Class<? extends javax.validation.ConstraintValidator<T,?>>> validators)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getValidatorsTypes

public static <T extends java.lang.annotation.Annotation> java.util.Map<java.lang.reflect.Type,java.lang.Class<? extends javax.validation.ConstraintValidator<?,?>>> getValidatorsTypes(java.util.List<java.lang.Class<? extends javax.validation.ConstraintValidator<T,?>>> validators)
Parameters:
validators - List of constraint validator classes (for a given constraint).
Returns:
Return a Map<Class, Class<? extends ConstraintValidator>> where the map key is the type the validator accepts and value the validator class itself.


Copyright © 2011 Oracle Corporation. All Rights Reserved.