package com.jsowell.common.enums.ykc;

/**
 * 充电桩状态enum
 */
public enum PileStatusEnum {
	UNKNOWN("0", "未知"),
	ON_LINE("1", "在线"),
	OFF_LINE("2","离线"),
	FAULT("3", "故障"),
	;

	private String value;
	private String label;

	public String getValue() {
		return value;
	}

	public void setValue(String value) {
		this.value = value;
	}

	public String getLabel() {
		return label;
	}

	public void setLabel(String label) {
		this.label = label;
	}

	PileStatusEnum(String value, String label) {
		this.value = value;
		this.label = label;
	}

	public static String getStatusDescription(String status) {
		for (PileStatusEnum pileStatusEnum : PileStatusEnum.values()) {
			if (pileStatusEnum.getValue().equals(status)) {
				return pileStatusEnum.getLabel();
			}
		}
		return "";
	}
}
