package net.joystart.vehicle.enums;
import net.joystart.order.enums.OrderStatus;
public enum VehicleStatus { /** 未定义 */ UNDEFINED(-1){public String getName(){return "未定义";}}, /** 可用 */ CANRENT(7){public String getName(){return "可用";}}, /** 已租 */ RENTING(8){public String getName(){return "已租";}}, /** 禁用*/ DISABLED(9){public String getName(){return "禁用";}}, /** 待整备*/ TOREORGANIZE(12){public String getName(){return "待整备";}}, /** 调整中 */ ADJUSTING(13){public String getName(){return "调整中";}}, /** 维修中 */ REPAIRING(14){public String getName(){return "维修中";}}, /** 保养中 */ MAINTAINING(15){public String getName(){return "保养中";}}, /** 换车中 */ CHANGINGVEHICLE(16){public String getName(){return "换车中";}}; private int value; private VehicleStatus(int value){ this.value=value; } public int getValue(){ return this.value; } /** * 根据INT数值获取对应的枚举值 * @param value * @return */ public static VehicleStatus valueOf(int value){ switch(value){ case 7: return CANRENT; case 8: return RENTING; case 9: return DISABLED; case 12: return TOREORGANIZE; case 13: return ADJUSTING; case 14: return REPAIRING; case 15: return MAINTAINING; case 16: return CHANGINGVEHICLE; } return UNDEFINED; } public abstract String getName(); }