1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
| package org.jeecg.modules.base.enums;
|
|
| public enum ProductionTypeEnum {
| /**
| * 装配
| */
| ASSEMBLE,
| /**
| * 内法兰
| */
| INNERFLANGE,
| /**
| * 外法兰
| */
| OUTERFLANGE,
| /**
| * 热处理
| */
| HEATTREATMENT;
|
| /**
| * @param name 枚举的名称
| * @return 对应的 ProductionTypeEnum 枚举类型,如果未找到则返回 null
| */
| public static ProductionTypeEnum fromName(String name) {
| for (ProductionTypeEnum typeEnum : ProductionTypeEnum.values()) {
| if (typeEnum.name().equals(name)) {
| return typeEnum;
| }
| }
| return null;
| }
| }
|
|