当前位置:网站首页>Enum demo
Enum demo
2022-06-30 09:27:00 【Xiao Lu, a migrant worker in Beijing】
public enum ContactTypeEnum {
CALL_CONNECTED("CallEstablish"," call establishment 、 transfer "),
BE_CONSULT_CONNECTED("BeConsultEstablish"," Being consulted "),
BE_CONFERENCED("BeConferenceEstablish"," By conference "),
CONSULT_TRANSFER("ConsultTransfer"," Consult and transfer ");
private String code;
private String desc;
ContactTypeEnum(String code, String desc) {
this.code = code;
this.desc = desc;
}
public String getCode() {
return code;
}
public void setCode(String code) {
this.code = code;
}
public String getDesc() {
return desc;
}
public void setDesc(String desc) {
this.desc = desc;
}
public static ContactTypeEnum getFromCode(String code){
for (ContactTypeEnum type : ContactTypeEnum.values()){
if (type.getCode() == code)
return type;
}
return null;
}
}
边栏推荐
- Esp32 (4): overview of the overall code architecture
- Opencv learning notes -day10 logical operation of image pixels (usage of rectangle function and rect function and bit related operation in openCV)
- Common query and aggregation of ES
- Use V-IF with V-for
- Experience of an acmer
- Net framework system requirements
- Flink sql -- No factory implements ‘org. apache. flink. table. delegation. ExecutorFactory‘.
- Terminal -- Zsh of terminal three swordsmen
- QT downloading files through URL
- Mysq database remote connection error, remote connection is not allowed
猜你喜欢
Metasploit practice - SSH brute force cracking process
Talk about how the kotlin process started?
Talk about how the kotlin collaboration process establishes structured concurrency
QT connection to Shentong database
Maxiouassigner of mmdet line by line interpretation
7. know JNI and NDK
桂林 稳健医疗收购桂林乳胶100%股权 填补乳胶产品线空白
I once met a girl whom I most wanted to take care of all my life. Later... No later
Esp32 (4): overview of the overall code architecture
Small program learning path 1 - getting to know small programs
随机推荐
So the toolbar can still be used like this? The toolbar uses the most complete parsing. Netizen: finally, you don't have to always customize the title bar!
Baidu map JS browsing terminal
POJ 1753 flip game (DFS 𞓜 bit operation)
Opencv learning notes-day5 (arithmetic operation of image pixels, add() addition function, subtract() subtraction function, divide() division function, multiply() multiplication function
7. know JNI and NDK
ES6 learning road 5 symbol
Microsoft. Bcl. Async usage summary -- in Net framework 4.5 project Net framework version 4.5 and above can use async/await asynchronous feature in C 5
Unsupportedclassversionerror is reported when starting jar package. How to repair it
Esp32 (6): Bluetooth and WiFi functions for function development
Solution to pychart's failure in importing torch package
Rew acoustic test (V): equipment required for test
Pytorch for former Torch users - Tensors
Experience of an acmer
The elegant combination of walle and Jianbao
Use V-IF with V-for
Splice and slice functions of JS
Esp32 (IX): OTA function of function development
Rew acoustic test (II): offline test
2020-11-02
Design specification for smart speakers v1.0