All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.kafka.model.BrokerCountUpdateInfo 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.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 
 

* Information regarding UpdateBrokerCount. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class BrokerCountUpdateInfo implements Serializable, Cloneable, StructuredPojo { /** *

* Kafka Broker IDs of brokers being created. *

*/ private java.util.List createdBrokerIds; /** *

* Kafka Broker IDs of brokers being deleted. *

*/ private java.util.List deletedBrokerIds; /** *

* Kafka Broker IDs of brokers being created. *

* * @return

* Kafka Broker IDs of brokers being created. *

*/ public java.util.List getCreatedBrokerIds() { return createdBrokerIds; } /** *

* Kafka Broker IDs of brokers being created. *

* * @param createdBrokerIds *

* Kafka Broker IDs of brokers being created. *

*/ public void setCreatedBrokerIds(java.util.Collection createdBrokerIds) { if (createdBrokerIds == null) { this.createdBrokerIds = null; return; } this.createdBrokerIds = new java.util.ArrayList(createdBrokerIds); } /** *

* Kafka Broker IDs of brokers being created. *

* *

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setCreatedBrokerIds(java.util.Collection)} or {@link #withCreatedBrokerIds(java.util.Collection)} if you * want to override the existing values. *

* * @param createdBrokerIds *

* Kafka Broker IDs of brokers being created. *

* @return Returns a reference to this object so that method calls can be chained together. */ public BrokerCountUpdateInfo withCreatedBrokerIds(Double... createdBrokerIds) { if (this.createdBrokerIds == null) { setCreatedBrokerIds(new java.util.ArrayList(createdBrokerIds.length)); } for (Double ele : createdBrokerIds) { this.createdBrokerIds.add(ele); } return this; } /** *

* Kafka Broker IDs of brokers being created. *

* * @param createdBrokerIds *

* Kafka Broker IDs of brokers being created. *

* @return Returns a reference to this object so that method calls can be chained together. */ public BrokerCountUpdateInfo withCreatedBrokerIds(java.util.Collection createdBrokerIds) { setCreatedBrokerIds(createdBrokerIds); return this; } /** *

* Kafka Broker IDs of brokers being deleted. *

* * @return

* Kafka Broker IDs of brokers being deleted. *

*/ public java.util.List getDeletedBrokerIds() { return deletedBrokerIds; } /** *

* Kafka Broker IDs of brokers being deleted. *

* * @param deletedBrokerIds *

* Kafka Broker IDs of brokers being deleted. *

*/ public void setDeletedBrokerIds(java.util.Collection deletedBrokerIds) { if (deletedBrokerIds == null) { this.deletedBrokerIds = null; return; } this.deletedBrokerIds = new java.util.ArrayList(deletedBrokerIds); } /** *

* Kafka Broker IDs of brokers being deleted. *

* *

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setDeletedBrokerIds(java.util.Collection)} or {@link #withDeletedBrokerIds(java.util.Collection)} if you * want to override the existing values. *

* * @param deletedBrokerIds *

* Kafka Broker IDs of brokers being deleted. *

* @return Returns a reference to this object so that method calls can be chained together. */ public BrokerCountUpdateInfo withDeletedBrokerIds(Double... deletedBrokerIds) { if (this.deletedBrokerIds == null) { setDeletedBrokerIds(new java.util.ArrayList(deletedBrokerIds.length)); } for (Double ele : deletedBrokerIds) { this.deletedBrokerIds.add(ele); } return this; } /** *

* Kafka Broker IDs of brokers being deleted. *

* * @param deletedBrokerIds *

* Kafka Broker IDs of brokers being deleted. *

* @return Returns a reference to this object so that method calls can be chained together. */ public BrokerCountUpdateInfo withDeletedBrokerIds(java.util.Collection deletedBrokerIds) { setDeletedBrokerIds(deletedBrokerIds); 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 (getCreatedBrokerIds() != null) sb.append("CreatedBrokerIds: ").append(getCreatedBrokerIds()).append(","); if (getDeletedBrokerIds() != null) sb.append("DeletedBrokerIds: ").append(getDeletedBrokerIds()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof BrokerCountUpdateInfo == false) return false; BrokerCountUpdateInfo other = (BrokerCountUpdateInfo) obj; if (other.getCreatedBrokerIds() == null ^ this.getCreatedBrokerIds() == null) return false; if (other.getCreatedBrokerIds() != null && other.getCreatedBrokerIds().equals(this.getCreatedBrokerIds()) == false) return false; if (other.getDeletedBrokerIds() == null ^ this.getDeletedBrokerIds() == null) return false; if (other.getDeletedBrokerIds() != null && other.getDeletedBrokerIds().equals(this.getDeletedBrokerIds()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getCreatedBrokerIds() == null) ? 0 : getCreatedBrokerIds().hashCode()); hashCode = prime * hashCode + ((getDeletedBrokerIds() == null) ? 0 : getDeletedBrokerIds().hashCode()); return hashCode; } @Override public BrokerCountUpdateInfo clone() { try { return (BrokerCountUpdateInfo) 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.BrokerCountUpdateInfoMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy