package com.unis.detectionnum.server.aenum;

public enum CompareTypeEnum {
	MORE_THAN(">","大于"),LESS_THAN("<","小于"),EQUAL("=","等于");
	private String id;
	private String name;
	private CompareTypeEnum(String id,String name){
		this.id=id;
		this.name=name;
	}
	
	public static CompareTypeEnum getById(final String id){
		CompareTypeEnum[] compareTypeEnums=CompareTypeEnum.values();
		for (CompareTypeEnum compareTypeEnum : compareTypeEnums) {
			if(compareTypeEnum.getId().equals(id)){
				return compareTypeEnum;
			}
		}
		return null;
	}
	
	public String getId() {
		return id;
	}
	public String getName() {
		return name;
	}
}
