
com.amazonaws.services.kafka.model.UpdateSecurityRequest Maven / Gradle / Ivy
/*
* Copyright 2019-2024 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.AmazonWebServiceRequest;
/**
*
* @see AWS API
* Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class UpdateSecurityRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable {
/**
*
* Includes all client authentication related information.
*
*/
private ClientAuthentication clientAuthentication;
/**
*
* The Amazon Resource Name (ARN) that uniquely identifies the cluster.
*
*/
private String clusterArn;
/**
*
* The version of the MSK cluster to update. Cluster versions aren't simple numbers. You can describe an MSK cluster
* to find its version. When this update operation is successful, it generates a new cluster version.
*
*/
private String currentVersion;
/**
*
* Includes all encryption-related information.
*
*/
private EncryptionInfo encryptionInfo;
/**
*
* Includes all client authentication related information.
*
*
* @param clientAuthentication
*
* Includes all client authentication related information.
*
*/
public void setClientAuthentication(ClientAuthentication clientAuthentication) {
this.clientAuthentication = clientAuthentication;
}
/**
*
* Includes all client authentication related information.
*
*
* @return
* Includes all client authentication related information.
*
*/
public ClientAuthentication getClientAuthentication() {
return this.clientAuthentication;
}
/**
*
* Includes all client authentication related information.
*
*
* @param clientAuthentication
*
* Includes all client authentication related information.
*
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSecurityRequest withClientAuthentication(ClientAuthentication clientAuthentication) {
setClientAuthentication(clientAuthentication);
return this;
}
/**
*
* The Amazon Resource Name (ARN) that uniquely identifies the cluster.
*
*
* @param clusterArn
*
* The Amazon Resource Name (ARN) that uniquely identifies the cluster.
*
*/
public void setClusterArn(String clusterArn) {
this.clusterArn = clusterArn;
}
/**
*
* The Amazon Resource Name (ARN) that uniquely identifies the cluster.
*
*
* @return
* The Amazon Resource Name (ARN) that uniquely identifies the cluster.
*
*/
public String getClusterArn() {
return this.clusterArn;
}
/**
*
* The Amazon Resource Name (ARN) that uniquely identifies the cluster.
*
*
* @param clusterArn
*
* The Amazon Resource Name (ARN) that uniquely identifies the cluster.
*
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSecurityRequest withClusterArn(String clusterArn) {
setClusterArn(clusterArn);
return this;
}
/**
*
* The version of the MSK cluster to update. Cluster versions aren't simple numbers. You can describe an MSK cluster
* to find its version. When this update operation is successful, it generates a new cluster version.
*
*
* @param currentVersion
*
* The version of the MSK cluster to update. Cluster versions aren't simple numbers. You can describe an MSK
* cluster to find its version. When this update operation is successful, it generates a new cluster version.
*
*/
public void setCurrentVersion(String currentVersion) {
this.currentVersion = currentVersion;
}
/**
*
* The version of the MSK cluster to update. Cluster versions aren't simple numbers. You can describe an MSK cluster
* to find its version. When this update operation is successful, it generates a new cluster version.
*
*
* @return
* The version of the MSK cluster to update. Cluster versions aren't simple numbers. You can describe an MSK
* cluster to find its version. When this update operation is successful, it generates a new cluster
* version.
*
*/
public String getCurrentVersion() {
return this.currentVersion;
}
/**
*
* The version of the MSK cluster to update. Cluster versions aren't simple numbers. You can describe an MSK cluster
* to find its version. When this update operation is successful, it generates a new cluster version.
*
*
* @param currentVersion
*
* The version of the MSK cluster to update. Cluster versions aren't simple numbers. You can describe an MSK
* cluster to find its version. When this update operation is successful, it generates a new cluster version.
*
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSecurityRequest withCurrentVersion(String currentVersion) {
setCurrentVersion(currentVersion);
return this;
}
/**
*
* Includes all encryption-related information.
*
*
* @param encryptionInfo
*
* Includes all encryption-related information.
*
*/
public void setEncryptionInfo(EncryptionInfo encryptionInfo) {
this.encryptionInfo = encryptionInfo;
}
/**
*
* Includes all encryption-related information.
*
*
* @return
* Includes all encryption-related information.
*
*/
public EncryptionInfo getEncryptionInfo() {
return this.encryptionInfo;
}
/**
*
* Includes all encryption-related information.
*
*
* @param encryptionInfo
*
* Includes all encryption-related information.
*
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateSecurityRequest withEncryptionInfo(EncryptionInfo encryptionInfo) {
setEncryptionInfo(encryptionInfo);
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 (getClientAuthentication() != null)
sb.append("ClientAuthentication: ").append(getClientAuthentication()).append(",");
if (getClusterArn() != null)
sb.append("ClusterArn: ").append(getClusterArn()).append(",");
if (getCurrentVersion() != null)
sb.append("CurrentVersion: ").append(getCurrentVersion()).append(",");
if (getEncryptionInfo() != null)
sb.append("EncryptionInfo: ").append(getEncryptionInfo());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof UpdateSecurityRequest == false)
return false;
UpdateSecurityRequest other = (UpdateSecurityRequest) obj;
if (other.getClientAuthentication() == null ^ this.getClientAuthentication() == null)
return false;
if (other.getClientAuthentication() != null && other.getClientAuthentication().equals(this.getClientAuthentication()) == false)
return false;
if (other.getClusterArn() == null ^ this.getClusterArn() == null)
return false;
if (other.getClusterArn() != null && other.getClusterArn().equals(this.getClusterArn()) == false)
return false;
if (other.getCurrentVersion() == null ^ this.getCurrentVersion() == null)
return false;
if (other.getCurrentVersion() != null && other.getCurrentVersion().equals(this.getCurrentVersion()) == false)
return false;
if (other.getEncryptionInfo() == null ^ this.getEncryptionInfo() == null)
return false;
if (other.getEncryptionInfo() != null && other.getEncryptionInfo().equals(this.getEncryptionInfo()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getClientAuthentication() == null) ? 0 : getClientAuthentication().hashCode());
hashCode = prime * hashCode + ((getClusterArn() == null) ? 0 : getClusterArn().hashCode());
hashCode = prime * hashCode + ((getCurrentVersion() == null) ? 0 : getCurrentVersion().hashCode());
hashCode = prime * hashCode + ((getEncryptionInfo() == null) ? 0 : getEncryptionInfo().hashCode());
return hashCode;
}
@Override
public UpdateSecurityRequest clone() {
return (UpdateSecurityRequest) super.clone();
}
}