com.huaweicloud.sdk.iotda.v5.model.FreezeDeviceRequest Maven / Gradle / Ivy
package com.huaweicloud.sdk.iotda.v5.model;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Objects;
/**
* Request Object
*/
public class FreezeDeviceRequest {
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "Instance-Id")
private String instanceId;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "device_id")
private String deviceId;
public FreezeDeviceRequest withInstanceId(String instanceId) {
this.instanceId = instanceId;
return this;
}
/**
* **参数说明**:实例ID。物理多租下各实例的唯一标识,一般华为云租户无需携带该参数,仅在物理多租场景下从管理面访问API时需要携带该参数。您可以在IoTDA管理控制台界面,选择左侧导航栏“总览”页签查看当前实例的ID
* @return instanceId
*/
public String getInstanceId() {
return instanceId;
}
public void setInstanceId(String instanceId) {
this.instanceId = instanceId;
}
public FreezeDeviceRequest withDeviceId(String deviceId) {
this.deviceId = deviceId;
return this;
}
/**
* **参数说明**:设备ID,用于唯一标识一个设备。在注册设备时直接指定,或者由物联网平台分配获得。由物联网平台分配时,生成规则为\"product_id\" + \"_\" + \"node_id\"拼接而成。 **取值范围**:长度不超过128,只允许字母、数字、下划线(_)、连接符(-)的组合。
* @return deviceId
*/
public String getDeviceId() {
return deviceId;
}
public void setDeviceId(String deviceId) {
this.deviceId = deviceId;
}
@Override
public boolean equals(java.lang.Object obj) {
if (this == obj) {
return true;
}
if (obj == null || getClass() != obj.getClass()) {
return false;
}
FreezeDeviceRequest that = (FreezeDeviceRequest) obj;
return Objects.equals(this.instanceId, that.instanceId) && Objects.equals(this.deviceId, that.deviceId);
}
@Override
public int hashCode() {
return Objects.hash(instanceId, deviceId);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class FreezeDeviceRequest {\n");
sb.append(" instanceId: ").append(toIndentedString(instanceId)).append("\n");
sb.append(" deviceId: ").append(toIndentedString(deviceId)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}