ludc
2025-01-16 986aa62ed00bee39363bab41b4eeb8259d446efd
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
package com.vci.lcstatuspck;
 
import com.vci.starter.web.annotation.VciLifeCycle;
import com.vci.starter.web.annotation.VciLifeCycleTrans;
import com.vci.starter.web.enumpck.BaseEnum;
 
/**
 * @author ludc
 * @date 2024/7/16 14:31
 */
 
@VciLifeCycle(
        name = "FileObjectLC",
        text = "文件生命周期",
        startStatus = "FileInit",
        translations = {@VciLifeCycleTrans(
                source = "FileInit",
                target = "FileTransing",
                name = "开始上传"
        ), @VciLifeCycleTrans(
                source = "FileTransing",
                target = "FileTransFinish",
                name = "上传完成"
        ), @VciLifeCycleTrans(
                source = "FileTransing",
                target = "FileRelease",
                name = "上传完成后直接发布"
        ), @VciLifeCycleTrans(
                source = "FileTransFinish",
                target = "FileRelease",
                name = "上传完成后转发布"
        )}
)
public enum FileLCStatus implements BaseEnum {
    INIT("FileInit", "初始化"),
    TRANSING("FileTransing", "上传中"),
    TRANS_FINISH("FileTransFinish", "上传完成"),
    FILE_RELEASE("FileRelease", "已生效"),
    LINKED("FileLinked", "关联的文件");
 
    private String value;
    private String text;
 
    public String getValue() {
        return this.value;
    }
 
    public void setValue(String value) {
        this.value = value;
    }
 
    public String getText() {
        return this.text;
    }
 
    public void setText(String text) {
        this.text = text;
    }
 
    private FileLCStatus(String value, String text) {
        this.value = value;
        this.text = text;
    }
 
    public static String getTextByValue(String value) {
        FileLCStatus[] var1 = values();
        int var2 = var1.length;
 
        for(int var3 = 0; var3 < var2; ++var3) {
            FileLCStatus eu = var1[var3];
            if (eu.value.equalsIgnoreCase(value)) {
                return eu.text;
            }
        }
 
        return "";
    }
 
    public static String getValueByText(String text) {
        FileLCStatus[] var1 = values();
        int var2 = var1.length;
 
        for(int var3 = 0; var3 < var2; ++var3) {
            FileLCStatus eu = var1[var3];
            if (eu.text.equalsIgnoreCase(text)) {
                return eu.value;
            }
        }
 
        return "";
    }
}