| 1234567891011121314151617181920212223 |
- package edu.nju.model;
- public enum BugSeverity {
- 待定(0),较轻(1),一般(2),严重(3),紧急(4);
- private int id;
- BugSeverity(int i) {
- this.id=id;
- }
- public int getId(){
- return this.id;
- }
- public static BugSeverity getValue(int code){
- for(BugSeverity bugSeverity:values()){
- if(bugSeverity.getId()==code){
- return bugSeverity;
- }
- }
- return null;
- }
- }
|