Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
DataType |
|
| 1.0;1 |
1 | package org.kuali.rice.krad.datadictionary.validation; | |
2 | ||
3 | import javax.xml.bind.annotation.XmlEnum; | |
4 | import java.util.Date; | |
5 | ||
6 | /** | |
7 | * A simple data type enum inherited from the Kuali Student project, that can be used to define a specific data type for a dictionary object | |
8 | * or one of its member attributes. | |
9 | * | |
10 | * @author Kuali Rice Team (rice.collab@kuali.org) | |
11 | */ | |
12 | 2 | @XmlEnum |
13 | public enum DataType { | |
14 | 1 | STRING(String.class), DATE(Date.class), TRUNCATED_DATE(Date.class), BOOLEAN(Boolean.class), INTEGER(Integer.class), FLOAT(Float.class), DOUBLE(Double.class), LONG(Long.class), COMPLEX(Object.class); |
15 | ||
16 | private Class<?> type; | |
17 | ||
18 | 9 | private DataType(Class<?> type) { |
19 | 9 | this.type = type; |
20 | 9 | } |
21 | ||
22 | public Class<?> getType() { | |
23 | 0 | return type; |
24 | } | |
25 | } |