com.huaweicloud.sdk.aom.v2.model.Dimension2 Maven / Gradle / Ivy
package com.huaweicloud.sdk.aom.v2.model;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Objects;
/**
* 指标维度参数
*/
public class Dimension2 {
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "name")
private String name;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "value")
private String value;
public Dimension2 withName(String name) {
this.name = name;
return this;
}
/**
* 维度名称。
* @return name
*/
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public Dimension2 withValue(String value) {
this.value = value;
return this;
}
/**
* 维度取值。
* @return value
*/
public String getValue() {
return value;
}
public void setValue(String value) {
this.value = value;
}
@Override
public boolean equals(java.lang.Object obj) {
if (this == obj) {
return true;
}
if (obj == null || getClass() != obj.getClass()) {
return false;
}
Dimension2 that = (Dimension2) obj;
return Objects.equals(this.name, that.name) && Objects.equals(this.value, that.value);
}
@Override
public int hashCode() {
return Objects.hash(name, value);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Dimension2 {\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append(" value: ").append(toIndentedString(value)).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 ");
}
}