com.huaweicloud.sdk.cloudtest.v1.model.AuthInfo Maven / Gradle / Ivy
package com.huaweicloud.sdk.cloudtest.v1.model;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Objects;
/**
* AuthInfo
*/
public class AuthInfo {
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "access_key")
private String accessKey;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "secret_key")
private String secretKey;
public AuthInfo withAccessKey(String accessKey) {
this.accessKey = accessKey;
return this;
}
/**
* 访问密钥
* @return accessKey
*/
public String getAccessKey() {
return accessKey;
}
public void setAccessKey(String accessKey) {
this.accessKey = accessKey;
}
public AuthInfo withSecretKey(String secretKey) {
this.secretKey = secretKey;
return this;
}
/**
* 私钥
* @return secretKey
*/
public String getSecretKey() {
return secretKey;
}
public void setSecretKey(String secretKey) {
this.secretKey = secretKey;
}
@Override
public boolean equals(java.lang.Object obj) {
if (this == obj) {
return true;
}
if (obj == null || getClass() != obj.getClass()) {
return false;
}
AuthInfo that = (AuthInfo) obj;
return Objects.equals(this.accessKey, that.accessKey) && Objects.equals(this.secretKey, that.secretKey);
}
@Override
public int hashCode() {
return Objects.hash(accessKey, secretKey);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class AuthInfo {\n");
sb.append(" accessKey: ").append(toIndentedString(accessKey)).append("\n");
sb.append(" secretKey: ").append(toIndentedString(secretKey)).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 ");
}
}