Package org.hibernate.validator.constraints

Examples of org.hibernate.validator.constraints.Length.max()


    // determine max length
    int maxlen = -1;
    final Length aLength = m.getAnnotation(Length.class);
    if(aLength != null) {
      maxlen = aLength.max();
    }
    else {
      // try Size anno
      final Size aSize = m.getAnnotation(Size.class);
      if(aSize != null) {
View Full Code Here


    // determine max length
    int maxlen = -1;
    final Length aLength = m.getAnnotation(Length.class);
    if(aLength != null) {
      maxlen = aLength.max();
    }
    else {
      // try Size anno
      final Size aSize = m.getAnnotation(Size.class);
      if(aSize != null) {
View Full Code Here

   
    public int getMaxLength(final String propertyName){
       
        final Length maxLength = getPropertyLengthAnnotation(propertyName);
               
        return maxLength == null ? -1 : maxLength.max();
       
    }
   
    public void setWrappedInstanceClass(Class<T> wrappedInstanceClass){
       
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.