Coverage Report - org.kuali.student.common.ui.client.validator.ValidationMessageKeys
 
Classes in this File Line Coverage Branch Coverage Complexity
ValidationMessageKeys
100%
29/29
N/A
1
 
 1  
 /**
 2  
  * Copyright 2010 The Kuali Foundation Licensed under the
 3  
  * Educational Community License, Version 2.0 (the "License"); you may
 4  
  * not use this file except in compliance with the License. You may
 5  
  * obtain a copy of the License at
 6  
  *
 7  
  * http://www.osedu.org/licenses/ECL-2.0
 8  
  *
 9  
  * Unless required by applicable law or agreed to in writing,
 10  
  * software distributed under the License is distributed on an "AS IS"
 11  
  * BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
 12  
  * or implied. See the License for the specific language governing
 13  
  * permissions and limitations under the License.
 14  
  */
 15  
 
 16  
 package org.kuali.student.common.ui.client.validator;
 17  
 
 18  1
 public enum ValidationMessageKeys {
 19  1
         REQUIRED("validation.required"),
 20  1
         MIN_OCCURS("validation.minOccurs", "minOccurs"),
 21  1
         MAX_OCCURS("validation.maxOccurs", "maxOccurs"),
 22  1
         REQUIRES_FIELD("validation.requiresField"),
 23  1
         VALID_CHARS("validation.validCharsFailed"),
 24  1
         OCCURS("validation.occurs"),
 25  1
         BOOLEAN("validation.mustBeBoolean"),
 26  1
         DOUBLE("validation.mustBeDouble"),
 27  1
         OUT_OF_RANGE("validation.outOfRange"),
 28  1
         MAX_VALUE("validation.maxValueFailed", "maxValue"),
 29  1
         MIN_VALUE("validation.minValueFailed", "minValue"),
 30  1
         FLOAT("validation.mustBeFloat"),
 31  1
         LONG("validation.mustBeLong"),
 32  1
         INTEGER("validation.mustBeInteger"),
 33  1
         DATE("validation.mustBeDate"),
 34  1
         LENGTH_OUT_OF_RANGE("validation.lengthOutOfRange"),
 35  1
         MAX_LENGTH("validation.maxLengthFailed", "maxLength"),
 36  1
         MIN_LENGTH("validation.minLengthFailed", "minLength")
 37  
         ;
 38  
         private final String key;
 39  
         private final String property;
 40  
         
 41  12
         private ValidationMessageKeys(final String key) {        
 42  12
                 this.key = key;
 43  12
                 this.property = "";
 44  12
         }
 45  
 
 46  6
         private ValidationMessageKeys(final String key, final String property) {        
 47  6
                 this.key = key;
 48  6
                 this.property = property;
 49  6
         }
 50  
         
 51  
         public String getKey() {
 52  3
                 return this.key;
 53  
         }
 54  
         
 55  
         public String getProperty(){
 56  6
                 return this.property;
 57  
         }
 58  
 }