com.dahuatech.icc.brm.enums.OperationLockEnum Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of java-sdk-brm Show documentation
Show all versions of java-sdk-brm Show documentation
Dahua ICC Open API SDK for Java
package com.dahuatech.icc.brm.enums;
/**
* 操作权限锁枚举
*/
public enum OperationLockEnum {
//增加
ADD(1),
//修改
UPDATE(2),
//删除
DELETE(3),
//添加设备
ADD_DEVICE(4);
private Integer code;
private OperationLockEnum(Integer code){
this.code = code;
}
public Integer getCode() {
return code;
}
public void setCode(Integer code) {
this.code = code;
}
public static OperationLockEnum forValue(String code) {
if(code == null || code.length() == 0){
return null;
}
for (OperationLockEnum typeEnum : OperationLockEnum.values()) {
if (typeEnum.getCode().equals(code)) {
return typeEnum;
}
}
return null;
}
}