/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.kafka.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* Returns information about a provisioned cluster operation. *
* * @see AWS API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class ClusterOperationV2Provisioned implements Serializable, Cloneable, StructuredPojo { /** ** Steps completed during the operation. *
*/ private java.util.List* Information about cluster attributes before a cluster is updated. *
*/ private MutableClusterInfo sourceClusterInfo; /** ** Information about cluster attributes after a cluster is updated. *
*/ private MutableClusterInfo targetClusterInfo; /** ** Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *
*/ private VpcConnectionInfo vpcConnectionInfo; /** ** Steps completed during the operation. *
* * @return* Steps completed during the operation. *
*/ public java.util.List* Steps completed during the operation. *
* * @param operationSteps ** Steps completed during the operation. *
*/ public void setOperationSteps(java.util.Collection* Steps completed during the operation. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setOperationSteps(java.util.Collection)} or {@link #withOperationSteps(java.util.Collection)} if you want * to override the existing values. *
* * @param operationSteps ** Steps completed during the operation. *
* @return Returns a reference to this object so that method calls can be chained together. */ public ClusterOperationV2Provisioned withOperationSteps(ClusterOperationStep... operationSteps) { if (this.operationSteps == null) { setOperationSteps(new java.util.ArrayList* Steps completed during the operation. *
* * @param operationSteps ** Steps completed during the operation. *
* @return Returns a reference to this object so that method calls can be chained together. */ public ClusterOperationV2Provisioned withOperationSteps(java.util.Collection* Information about cluster attributes before a cluster is updated. *
* * @param sourceClusterInfo ** Information about cluster attributes before a cluster is updated. *
*/ public void setSourceClusterInfo(MutableClusterInfo sourceClusterInfo) { this.sourceClusterInfo = sourceClusterInfo; } /** ** Information about cluster attributes before a cluster is updated. *
* * @return* Information about cluster attributes before a cluster is updated. *
*/ public MutableClusterInfo getSourceClusterInfo() { return this.sourceClusterInfo; } /** ** Information about cluster attributes before a cluster is updated. *
* * @param sourceClusterInfo ** Information about cluster attributes before a cluster is updated. *
* @return Returns a reference to this object so that method calls can be chained together. */ public ClusterOperationV2Provisioned withSourceClusterInfo(MutableClusterInfo sourceClusterInfo) { setSourceClusterInfo(sourceClusterInfo); return this; } /** ** Information about cluster attributes after a cluster is updated. *
* * @param targetClusterInfo ** Information about cluster attributes after a cluster is updated. *
*/ public void setTargetClusterInfo(MutableClusterInfo targetClusterInfo) { this.targetClusterInfo = targetClusterInfo; } /** ** Information about cluster attributes after a cluster is updated. *
* * @return* Information about cluster attributes after a cluster is updated. *
*/ public MutableClusterInfo getTargetClusterInfo() { return this.targetClusterInfo; } /** ** Information about cluster attributes after a cluster is updated. *
* * @param targetClusterInfo ** Information about cluster attributes after a cluster is updated. *
* @return Returns a reference to this object so that method calls can be chained together. */ public ClusterOperationV2Provisioned withTargetClusterInfo(MutableClusterInfo targetClusterInfo) { setTargetClusterInfo(targetClusterInfo); return this; } /** ** Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *
* * @param vpcConnectionInfo ** Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *
*/ public void setVpcConnectionInfo(VpcConnectionInfo vpcConnectionInfo) { this.vpcConnectionInfo = vpcConnectionInfo; } /** ** Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *
* * @return* Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *
*/ public VpcConnectionInfo getVpcConnectionInfo() { return this.vpcConnectionInfo; } /** ** Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *
* * @param vpcConnectionInfo ** Description of the VPC connection for CreateVpcConnection and DeleteVpcConnection operations. *
* @return Returns a reference to this object so that method calls can be chained together. */ public ClusterOperationV2Provisioned withVpcConnectionInfo(VpcConnectionInfo vpcConnectionInfo) { setVpcConnectionInfo(vpcConnectionInfo); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getOperationSteps() != null) sb.append("OperationSteps: ").append(getOperationSteps()).append(","); if (getSourceClusterInfo() != null) sb.append("SourceClusterInfo: ").append(getSourceClusterInfo()).append(","); if (getTargetClusterInfo() != null) sb.append("TargetClusterInfo: ").append(getTargetClusterInfo()).append(","); if (getVpcConnectionInfo() != null) sb.append("VpcConnectionInfo: ").append(getVpcConnectionInfo()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof ClusterOperationV2Provisioned == false) return false; ClusterOperationV2Provisioned other = (ClusterOperationV2Provisioned) obj; if (other.getOperationSteps() == null ^ this.getOperationSteps() == null) return false; if (other.getOperationSteps() != null && other.getOperationSteps().equals(this.getOperationSteps()) == false) return false; if (other.getSourceClusterInfo() == null ^ this.getSourceClusterInfo() == null) return false; if (other.getSourceClusterInfo() != null && other.getSourceClusterInfo().equals(this.getSourceClusterInfo()) == false) return false; if (other.getTargetClusterInfo() == null ^ this.getTargetClusterInfo() == null) return false; if (other.getTargetClusterInfo() != null && other.getTargetClusterInfo().equals(this.getTargetClusterInfo()) == false) return false; if (other.getVpcConnectionInfo() == null ^ this.getVpcConnectionInfo() == null) return false; if (other.getVpcConnectionInfo() != null && other.getVpcConnectionInfo().equals(this.getVpcConnectionInfo()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getOperationSteps() == null) ? 0 : getOperationSteps().hashCode()); hashCode = prime * hashCode + ((getSourceClusterInfo() == null) ? 0 : getSourceClusterInfo().hashCode()); hashCode = prime * hashCode + ((getTargetClusterInfo() == null) ? 0 : getTargetClusterInfo().hashCode()); hashCode = prime * hashCode + ((getVpcConnectionInfo() == null) ? 0 : getVpcConnectionInfo().hashCode()); return hashCode; } @Override public ClusterOperationV2Provisioned clone() { try { return (ClusterOperationV2Provisioned) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.kafka.model.transform.ClusterOperationV2ProvisionedMarshaller.getInstance().marshall(this, protocolMarshaller); } }