|
@@ -0,0 +1,53 @@
|
|
|
|
+package com.diagbot.enums;
|
|
|
|
+
|
|
|
|
+import com.diagbot.core.KeyedNamed;
|
|
|
|
+import lombok.Setter;
|
|
|
|
+
|
|
|
|
+/**
|
|
|
|
+ * @author zhoutg
|
|
|
|
+ * @Description: 诊断类型
|
|
|
|
+ * @date 2018年10月11日 下午3:33:22
|
|
|
|
+ */
|
|
|
|
+
|
|
|
|
+public enum DiseaseTypeEnum implements KeyedNamed {
|
|
|
|
+
|
|
|
|
+ identify(1, "鉴别诊断"),
|
|
|
|
+ pacs(2, "xxxx诊断");
|
|
|
|
+
|
|
|
|
+ @Setter
|
|
|
|
+ private int key;
|
|
|
|
+
|
|
|
|
+ @Setter
|
|
|
|
+ private String name;
|
|
|
|
+
|
|
|
|
+ DiseaseTypeEnum(int key, String name) {
|
|
|
|
+ this.key = key;
|
|
|
|
+ this.name = name;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ public static DiseaseTypeEnum getEnum(int key) {
|
|
|
|
+ for (DiseaseTypeEnum item : DiseaseTypeEnum.values()) {
|
|
|
|
+ if (item.key == key) {
|
|
|
|
+ return item;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ return null;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ public static String getName(int key) {
|
|
|
|
+ DiseaseTypeEnum item = getEnum(key);
|
|
|
|
+ return item != null ? item.name : null;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ public int getKey() {
|
|
|
|
+ return key;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ public String getName() {
|
|
|
|
+ return name;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+}
|