dev.bf2.ffm.ams.client.models.CapabilityReviewRequest Maven / Gradle / Ivy
/*
* Account Management Service API
* Manage user subscriptions and clusters
*
* The version of the OpenAPI document: 0.0.1
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package dev.bf2.ffm.ams.client.models;
import java.util.Objects;
import java.util.Arrays;
import java.util.Map;
import java.util.HashMap;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
/**
* CapabilityReviewRequest
*/
@JsonPropertyOrder({
CapabilityReviewRequest.JSON_PROPERTY_ACCOUNT_USERNAME,
CapabilityReviewRequest.JSON_PROPERTY_CAPABILITY,
CapabilityReviewRequest.JSON_PROPERTY_CLUSTER_ID,
CapabilityReviewRequest.JSON_PROPERTY_ORGANIZATION_ID,
CapabilityReviewRequest.JSON_PROPERTY_SUBSCRIPTION_ID,
CapabilityReviewRequest.JSON_PROPERTY_TYPE
})
@javax.annotation.processing.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class CapabilityReviewRequest {
public static final String JSON_PROPERTY_ACCOUNT_USERNAME = "account_username";
private String accountUsername;
/**
* Gets or Sets capability
*/
public enum CapabilityEnum {
MANAGE_CLUSTER_ADMIN("manage_cluster_admin");
private String value;
CapabilityEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static CapabilityEnum fromValue(String value) {
for (CapabilityEnum b : CapabilityEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}
public static final String JSON_PROPERTY_CAPABILITY = "capability";
private CapabilityEnum capability;
public static final String JSON_PROPERTY_CLUSTER_ID = "cluster_id";
private String clusterId;
public static final String JSON_PROPERTY_ORGANIZATION_ID = "organization_id";
private String organizationId;
public static final String JSON_PROPERTY_SUBSCRIPTION_ID = "subscription_id";
private String subscriptionId;
/**
* Gets or Sets type
*/
public enum TypeEnum {
CLUSTER("Cluster");
private String value;
TypeEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static TypeEnum fromValue(String value) {
for (TypeEnum b : TypeEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
}
}
public static final String JSON_PROPERTY_TYPE = "type";
private TypeEnum type;
public CapabilityReviewRequest() {
}
public CapabilityReviewRequest accountUsername(String accountUsername) {
this.accountUsername = accountUsername;
return this;
}
/**
* Get accountUsername
* @return accountUsername
**/
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
@JsonProperty(JSON_PROPERTY_ACCOUNT_USERNAME)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public String getAccountUsername() {
return accountUsername;
}
@JsonProperty(JSON_PROPERTY_ACCOUNT_USERNAME)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setAccountUsername(String accountUsername) {
this.accountUsername = accountUsername;
}
public CapabilityReviewRequest capability(CapabilityEnum capability) {
this.capability = capability;
return this;
}
/**
* Get capability
* @return capability
**/
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
@JsonProperty(JSON_PROPERTY_CAPABILITY)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public CapabilityEnum getCapability() {
return capability;
}
@JsonProperty(JSON_PROPERTY_CAPABILITY)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setCapability(CapabilityEnum capability) {
this.capability = capability;
}
public CapabilityReviewRequest clusterId(String clusterId) {
this.clusterId = clusterId;
return this;
}
/**
* Get clusterId
* @return clusterId
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@JsonProperty(JSON_PROPERTY_CLUSTER_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getClusterId() {
return clusterId;
}
@JsonProperty(JSON_PROPERTY_CLUSTER_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setClusterId(String clusterId) {
this.clusterId = clusterId;
}
public CapabilityReviewRequest organizationId(String organizationId) {
this.organizationId = organizationId;
return this;
}
/**
* Get organizationId
* @return organizationId
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@JsonProperty(JSON_PROPERTY_ORGANIZATION_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getOrganizationId() {
return organizationId;
}
@JsonProperty(JSON_PROPERTY_ORGANIZATION_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setOrganizationId(String organizationId) {
this.organizationId = organizationId;
}
public CapabilityReviewRequest subscriptionId(String subscriptionId) {
this.subscriptionId = subscriptionId;
return this;
}
/**
* Get subscriptionId
* @return subscriptionId
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@JsonProperty(JSON_PROPERTY_SUBSCRIPTION_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getSubscriptionId() {
return subscriptionId;
}
@JsonProperty(JSON_PROPERTY_SUBSCRIPTION_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setSubscriptionId(String subscriptionId) {
this.subscriptionId = subscriptionId;
}
public CapabilityReviewRequest type(TypeEnum type) {
this.type = type;
return this;
}
/**
* Get type
* @return type
**/
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
@JsonProperty(JSON_PROPERTY_TYPE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public TypeEnum getType() {
return type;
}
@JsonProperty(JSON_PROPERTY_TYPE)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setType(TypeEnum type) {
this.type = type;
}
/**
* Return true if this CapabilityReviewRequest object is equal to o.
*/
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
CapabilityReviewRequest capabilityReviewRequest = (CapabilityReviewRequest) o;
return Objects.equals(this.accountUsername, capabilityReviewRequest.accountUsername) &&
Objects.equals(this.capability, capabilityReviewRequest.capability) &&
Objects.equals(this.clusterId, capabilityReviewRequest.clusterId) &&
Objects.equals(this.organizationId, capabilityReviewRequest.organizationId) &&
Objects.equals(this.subscriptionId, capabilityReviewRequest.subscriptionId) &&
Objects.equals(this.type, capabilityReviewRequest.type);
}
@Override
public int hashCode() {
return Objects.hash(accountUsername, capability, clusterId, organizationId, subscriptionId, type);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class CapabilityReviewRequest {\n");
sb.append(" accountUsername: ").append(toIndentedString(accountUsername)).append("\n");
sb.append(" capability: ").append(toIndentedString(capability)).append("\n");
sb.append(" clusterId: ").append(toIndentedString(clusterId)).append("\n");
sb.append(" organizationId: ").append(toIndentedString(organizationId)).append("\n");
sb.append(" subscriptionId: ").append(toIndentedString(subscriptionId)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).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(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}