com.volcengine.escloud.model.InstanceConfigurationForCreateInstanceInOneStepInput Maven / Gradle / Ivy
/*
* escloud
* No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
*
* OpenAPI spec version: common-version
*
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*/
package com.volcengine.escloud.model;
import java.util.Objects;
import java.util.Arrays;
import com.google.gson.TypeAdapter;
import com.google.gson.annotations.JsonAdapter;
import com.google.gson.annotations.SerializedName;
import com.google.gson.stream.JsonReader;
import com.google.gson.stream.JsonWriter;
import com.volcengine.escloud.model.NetworkSpecForCreateInstanceInOneStepInput;
import com.volcengine.escloud.model.NodeSpecsAssignForCreateInstanceInOneStepInput;
import com.volcengine.escloud.model.SubnetForCreateInstanceInOneStepInput;
import com.volcengine.escloud.model.VPCForCreateInstanceInOneStepInput;
import io.swagger.v3.oas.annotations.media.Schema;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
/**
* InstanceConfigurationForCreateInstanceInOneStepInput
*/
public class InstanceConfigurationForCreateInstanceInOneStepInput {
@SerializedName("AdminPassword")
private String adminPassword = null;
@SerializedName("AutoRenew")
private Boolean autoRenew = null;
/**
* Gets or Sets chargeType
*/
@JsonAdapter(ChargeTypeEnum.Adapter.class)
public enum ChargeTypeEnum {
@SerializedName("PrePaid")
PREPAID("PrePaid"),
@SerializedName("PostPaid")
POSTPAID("PostPaid");
private String value;
ChargeTypeEnum(String value) {
this.value = value;
}
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
public static ChargeTypeEnum fromValue(String input) {
for (ChargeTypeEnum b : ChargeTypeEnum.values()) {
if (b.value.equals(input)) {
return b;
}
}
return null;
}
public static class Adapter extends TypeAdapter {
@Override
public void write(final JsonWriter jsonWriter, final ChargeTypeEnum enumeration) throws IOException {
jsonWriter.value(String.valueOf(enumeration.getValue()));
}
@Override
public ChargeTypeEnum read(final JsonReader jsonReader) throws IOException {
Object value = jsonReader.nextString();
return ChargeTypeEnum.fromValue((String)(value));
}
}
} @SerializedName("ChargeType")
private ChargeTypeEnum chargeType = null;
@SerializedName("ConfigurationCode")
private String configurationCode = null;
@SerializedName("DeletionProtection")
private Boolean deletionProtection = null;
@SerializedName("EnableCerebro")
private Boolean enableCerebro = null;
@SerializedName("EnableHttps")
private Boolean enableHttps = null;
@SerializedName("EnablePureMaster")
private Boolean enablePureMaster = null;
@SerializedName("InstanceName")
private String instanceName = null;
@SerializedName("NetworkSpecs")
private List networkSpecs = null;
@SerializedName("NodeSpecsAssigns")
private List nodeSpecsAssigns = null;
@SerializedName("Period")
private Integer period = null;
@SerializedName("ProjectName")
private String projectName = null;
@SerializedName("RegionId")
private String regionId = null;
@SerializedName("Subnet")
private SubnetForCreateInstanceInOneStepInput subnet = null;
@SerializedName("VPC")
private VPCForCreateInstanceInOneStepInput VPC = null;
/**
* Gets or Sets version
*/
@JsonAdapter(VersionEnum.Adapter.class)
public enum VersionEnum {
@SerializedName("V6_7")
V6_7("V6_7"),
@SerializedName("V7_10")
V7_10("V7_10"),
@SerializedName("V7_TLS")
V7_TLS("V7_TLS"),
@SerializedName("V7_BYTE")
V7_BYTE("V7_BYTE"),
@SerializedName("OPEN_SEARCH_2_9")
OPEN_SEARCH_2_9("OPEN_SEARCH_2_9");
private String value;
VersionEnum(String value) {
this.value = value;
}
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
public static VersionEnum fromValue(String input) {
for (VersionEnum b : VersionEnum.values()) {
if (b.value.equals(input)) {
return b;
}
}
return null;
}
public static class Adapter extends TypeAdapter {
@Override
public void write(final JsonWriter jsonWriter, final VersionEnum enumeration) throws IOException {
jsonWriter.value(String.valueOf(enumeration.getValue()));
}
@Override
public VersionEnum read(final JsonReader jsonReader) throws IOException {
Object value = jsonReader.nextString();
return VersionEnum.fromValue((String)(value));
}
}
} @SerializedName("Version")
private VersionEnum version = null;
@SerializedName("ZoneId")
private String zoneId = null;
public InstanceConfigurationForCreateInstanceInOneStepInput adminPassword(String adminPassword) {
this.adminPassword = adminPassword;
return this;
}
/**
* Get adminPassword
* @return adminPassword
**/
@Schema(description = "")
public String getAdminPassword() {
return adminPassword;
}
public void setAdminPassword(String adminPassword) {
this.adminPassword = adminPassword;
}
public InstanceConfigurationForCreateInstanceInOneStepInput autoRenew(Boolean autoRenew) {
this.autoRenew = autoRenew;
return this;
}
/**
* Get autoRenew
* @return autoRenew
**/
@Schema(description = "")
public Boolean isAutoRenew() {
return autoRenew;
}
public void setAutoRenew(Boolean autoRenew) {
this.autoRenew = autoRenew;
}
public InstanceConfigurationForCreateInstanceInOneStepInput chargeType(ChargeTypeEnum chargeType) {
this.chargeType = chargeType;
return this;
}
/**
* Get chargeType
* @return chargeType
**/
@Schema(description = "")
public ChargeTypeEnum getChargeType() {
return chargeType;
}
public void setChargeType(ChargeTypeEnum chargeType) {
this.chargeType = chargeType;
}
public InstanceConfigurationForCreateInstanceInOneStepInput configurationCode(String configurationCode) {
this.configurationCode = configurationCode;
return this;
}
/**
* Get configurationCode
* @return configurationCode
**/
@Schema(description = "")
public String getConfigurationCode() {
return configurationCode;
}
public void setConfigurationCode(String configurationCode) {
this.configurationCode = configurationCode;
}
public InstanceConfigurationForCreateInstanceInOneStepInput deletionProtection(Boolean deletionProtection) {
this.deletionProtection = deletionProtection;
return this;
}
/**
* Get deletionProtection
* @return deletionProtection
**/
@Schema(description = "")
public Boolean isDeletionProtection() {
return deletionProtection;
}
public void setDeletionProtection(Boolean deletionProtection) {
this.deletionProtection = deletionProtection;
}
public InstanceConfigurationForCreateInstanceInOneStepInput enableCerebro(Boolean enableCerebro) {
this.enableCerebro = enableCerebro;
return this;
}
/**
* Get enableCerebro
* @return enableCerebro
**/
@Schema(description = "")
public Boolean isEnableCerebro() {
return enableCerebro;
}
public void setEnableCerebro(Boolean enableCerebro) {
this.enableCerebro = enableCerebro;
}
public InstanceConfigurationForCreateInstanceInOneStepInput enableHttps(Boolean enableHttps) {
this.enableHttps = enableHttps;
return this;
}
/**
* Get enableHttps
* @return enableHttps
**/
@Schema(description = "")
public Boolean isEnableHttps() {
return enableHttps;
}
public void setEnableHttps(Boolean enableHttps) {
this.enableHttps = enableHttps;
}
public InstanceConfigurationForCreateInstanceInOneStepInput enablePureMaster(Boolean enablePureMaster) {
this.enablePureMaster = enablePureMaster;
return this;
}
/**
* Get enablePureMaster
* @return enablePureMaster
**/
@Schema(description = "")
public Boolean isEnablePureMaster() {
return enablePureMaster;
}
public void setEnablePureMaster(Boolean enablePureMaster) {
this.enablePureMaster = enablePureMaster;
}
public InstanceConfigurationForCreateInstanceInOneStepInput instanceName(String instanceName) {
this.instanceName = instanceName;
return this;
}
/**
* Get instanceName
* @return instanceName
**/
@Schema(description = "")
public String getInstanceName() {
return instanceName;
}
public void setInstanceName(String instanceName) {
this.instanceName = instanceName;
}
public InstanceConfigurationForCreateInstanceInOneStepInput networkSpecs(List networkSpecs) {
this.networkSpecs = networkSpecs;
return this;
}
public InstanceConfigurationForCreateInstanceInOneStepInput addNetworkSpecsItem(NetworkSpecForCreateInstanceInOneStepInput networkSpecsItem) {
if (this.networkSpecs == null) {
this.networkSpecs = new ArrayList();
}
this.networkSpecs.add(networkSpecsItem);
return this;
}
/**
* Get networkSpecs
* @return networkSpecs
**/
@Valid
@Schema(description = "")
public List getNetworkSpecs() {
return networkSpecs;
}
public void setNetworkSpecs(List networkSpecs) {
this.networkSpecs = networkSpecs;
}
public InstanceConfigurationForCreateInstanceInOneStepInput nodeSpecsAssigns(List nodeSpecsAssigns) {
this.nodeSpecsAssigns = nodeSpecsAssigns;
return this;
}
public InstanceConfigurationForCreateInstanceInOneStepInput addNodeSpecsAssignsItem(NodeSpecsAssignForCreateInstanceInOneStepInput nodeSpecsAssignsItem) {
if (this.nodeSpecsAssigns == null) {
this.nodeSpecsAssigns = new ArrayList();
}
this.nodeSpecsAssigns.add(nodeSpecsAssignsItem);
return this;
}
/**
* Get nodeSpecsAssigns
* @return nodeSpecsAssigns
**/
@Valid
@Schema(description = "")
public List getNodeSpecsAssigns() {
return nodeSpecsAssigns;
}
public void setNodeSpecsAssigns(List nodeSpecsAssigns) {
this.nodeSpecsAssigns = nodeSpecsAssigns;
}
public InstanceConfigurationForCreateInstanceInOneStepInput period(Integer period) {
this.period = period;
return this;
}
/**
* Get period
* @return period
**/
@Schema(description = "")
public Integer getPeriod() {
return period;
}
public void setPeriod(Integer period) {
this.period = period;
}
public InstanceConfigurationForCreateInstanceInOneStepInput projectName(String projectName) {
this.projectName = projectName;
return this;
}
/**
* Get projectName
* @return projectName
**/
@Schema(description = "")
public String getProjectName() {
return projectName;
}
public void setProjectName(String projectName) {
this.projectName = projectName;
}
public InstanceConfigurationForCreateInstanceInOneStepInput regionId(String regionId) {
this.regionId = regionId;
return this;
}
/**
* Get regionId
* @return regionId
**/
@Schema(description = "")
public String getRegionId() {
return regionId;
}
public void setRegionId(String regionId) {
this.regionId = regionId;
}
public InstanceConfigurationForCreateInstanceInOneStepInput subnet(SubnetForCreateInstanceInOneStepInput subnet) {
this.subnet = subnet;
return this;
}
/**
* Get subnet
* @return subnet
**/
@Valid
@Schema(description = "")
public SubnetForCreateInstanceInOneStepInput getSubnet() {
return subnet;
}
public void setSubnet(SubnetForCreateInstanceInOneStepInput subnet) {
this.subnet = subnet;
}
public InstanceConfigurationForCreateInstanceInOneStepInput VPC(VPCForCreateInstanceInOneStepInput VPC) {
this.VPC = VPC;
return this;
}
/**
* Get VPC
* @return VPC
**/
@Valid
@Schema(description = "")
public VPCForCreateInstanceInOneStepInput getVPC() {
return VPC;
}
public void setVPC(VPCForCreateInstanceInOneStepInput VPC) {
this.VPC = VPC;
}
public InstanceConfigurationForCreateInstanceInOneStepInput version(VersionEnum version) {
this.version = version;
return this;
}
/**
* Get version
* @return version
**/
@Schema(description = "")
public VersionEnum getVersion() {
return version;
}
public void setVersion(VersionEnum version) {
this.version = version;
}
public InstanceConfigurationForCreateInstanceInOneStepInput zoneId(String zoneId) {
this.zoneId = zoneId;
return this;
}
/**
* Get zoneId
* @return zoneId
**/
@Schema(description = "")
public String getZoneId() {
return zoneId;
}
public void setZoneId(String zoneId) {
this.zoneId = zoneId;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
InstanceConfigurationForCreateInstanceInOneStepInput instanceConfigurationForCreateInstanceInOneStepInput = (InstanceConfigurationForCreateInstanceInOneStepInput) o;
return Objects.equals(this.adminPassword, instanceConfigurationForCreateInstanceInOneStepInput.adminPassword) &&
Objects.equals(this.autoRenew, instanceConfigurationForCreateInstanceInOneStepInput.autoRenew) &&
Objects.equals(this.chargeType, instanceConfigurationForCreateInstanceInOneStepInput.chargeType) &&
Objects.equals(this.configurationCode, instanceConfigurationForCreateInstanceInOneStepInput.configurationCode) &&
Objects.equals(this.deletionProtection, instanceConfigurationForCreateInstanceInOneStepInput.deletionProtection) &&
Objects.equals(this.enableCerebro, instanceConfigurationForCreateInstanceInOneStepInput.enableCerebro) &&
Objects.equals(this.enableHttps, instanceConfigurationForCreateInstanceInOneStepInput.enableHttps) &&
Objects.equals(this.enablePureMaster, instanceConfigurationForCreateInstanceInOneStepInput.enablePureMaster) &&
Objects.equals(this.instanceName, instanceConfigurationForCreateInstanceInOneStepInput.instanceName) &&
Objects.equals(this.networkSpecs, instanceConfigurationForCreateInstanceInOneStepInput.networkSpecs) &&
Objects.equals(this.nodeSpecsAssigns, instanceConfigurationForCreateInstanceInOneStepInput.nodeSpecsAssigns) &&
Objects.equals(this.period, instanceConfigurationForCreateInstanceInOneStepInput.period) &&
Objects.equals(this.projectName, instanceConfigurationForCreateInstanceInOneStepInput.projectName) &&
Objects.equals(this.regionId, instanceConfigurationForCreateInstanceInOneStepInput.regionId) &&
Objects.equals(this.subnet, instanceConfigurationForCreateInstanceInOneStepInput.subnet) &&
Objects.equals(this.VPC, instanceConfigurationForCreateInstanceInOneStepInput.VPC) &&
Objects.equals(this.version, instanceConfigurationForCreateInstanceInOneStepInput.version) &&
Objects.equals(this.zoneId, instanceConfigurationForCreateInstanceInOneStepInput.zoneId);
}
@Override
public int hashCode() {
return Objects.hash(adminPassword, autoRenew, chargeType, configurationCode, deletionProtection, enableCerebro, enableHttps, enablePureMaster, instanceName, networkSpecs, nodeSpecsAssigns, period, projectName, regionId, subnet, VPC, version, zoneId);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class InstanceConfigurationForCreateInstanceInOneStepInput {\n");
sb.append(" adminPassword: ").append(toIndentedString(adminPassword)).append("\n");
sb.append(" autoRenew: ").append(toIndentedString(autoRenew)).append("\n");
sb.append(" chargeType: ").append(toIndentedString(chargeType)).append("\n");
sb.append(" configurationCode: ").append(toIndentedString(configurationCode)).append("\n");
sb.append(" deletionProtection: ").append(toIndentedString(deletionProtection)).append("\n");
sb.append(" enableCerebro: ").append(toIndentedString(enableCerebro)).append("\n");
sb.append(" enableHttps: ").append(toIndentedString(enableHttps)).append("\n");
sb.append(" enablePureMaster: ").append(toIndentedString(enablePureMaster)).append("\n");
sb.append(" instanceName: ").append(toIndentedString(instanceName)).append("\n");
sb.append(" networkSpecs: ").append(toIndentedString(networkSpecs)).append("\n");
sb.append(" nodeSpecsAssigns: ").append(toIndentedString(nodeSpecsAssigns)).append("\n");
sb.append(" period: ").append(toIndentedString(period)).append("\n");
sb.append(" projectName: ").append(toIndentedString(projectName)).append("\n");
sb.append(" regionId: ").append(toIndentedString(regionId)).append("\n");
sb.append(" subnet: ").append(toIndentedString(subnet)).append("\n");
sb.append(" VPC: ").append(toIndentedString(VPC)).append("\n");
sb.append(" version: ").append(toIndentedString(version)).append("\n");
sb.append(" zoneId: ").append(toIndentedString(zoneId)).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 ");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy