com.huaweicloud.sdk.osm.v2.model.CreateSessionRequest Maven / Gradle / Ivy
package com.huaweicloud.sdk.osm.v2.model;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.Objects;
/**
* Request Object
*/
public class CreateSessionRequest {
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "x-service-key")
private String xServiceKey;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "x-site")
private String xSite;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "x-language")
private String xLanguage;
public CreateSessionRequest withXServiceKey(String xServiceKey) {
this.xServiceKey = xServiceKey;
return this;
}
/**
* 调用智能客服服务标志。
* @return xServiceKey
*/
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "x-service-key")
public String getXServiceKey() {
return xServiceKey;
}
public void setXServiceKey(String xServiceKey) {
this.xServiceKey = xServiceKey;
}
public CreateSessionRequest withXSite(String xSite) {
this.xSite = xSite;
return this;
}
/**
* 站点标记,0-中国站 1-国际站
* @return xSite
*/
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "x-site")
public String getXSite() {
return xSite;
}
public void setXSite(String xSite) {
this.xSite = xSite;
}
public CreateSessionRequest withXLanguage(String xLanguage) {
this.xLanguage = xLanguage;
return this;
}
/**
* 区域语言简写,en-us zh-cn
* @return xLanguage
*/
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "x-language")
public String getXLanguage() {
return xLanguage;
}
public void setXLanguage(String xLanguage) {
this.xLanguage = xLanguage;
}
@Override
public boolean equals(java.lang.Object obj) {
if (this == obj) {
return true;
}
if (obj == null || getClass() != obj.getClass()) {
return false;
}
CreateSessionRequest that = (CreateSessionRequest) obj;
return Objects.equals(this.xServiceKey, that.xServiceKey) && Objects.equals(this.xSite, that.xSite)
&& Objects.equals(this.xLanguage, that.xLanguage);
}
@Override
public int hashCode() {
return Objects.hash(xServiceKey, xSite, xLanguage);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class CreateSessionRequest {\n");
sb.append(" xServiceKey: ").append(toIndentedString(xServiceKey)).append("\n");
sb.append(" xSite: ").append(toIndentedString(xSite)).append("\n");
sb.append(" xLanguage: ").append(toIndentedString(xLanguage)).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 ");
}
}