/* * 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.simplesystemsmanagement.model; import java.io.Serializable; import javax.annotation.Generated; /** * * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class DeleteParametersResult extends com.amazonaws.AmazonWebServiceResult implements Serializable, Cloneable { /** *

* The names of the deleted parameters. *

*/ private com.amazonaws.internal.SdkInternalList deletedParameters; /** *

* The names of parameters that weren't deleted because the parameters aren't valid. *

*/ private com.amazonaws.internal.SdkInternalList invalidParameters; /** *

* The names of the deleted parameters. *

* * @return The names of the deleted parameters. */ public java.util.List getDeletedParameters() { if (deletedParameters == null) { deletedParameters = new com.amazonaws.internal.SdkInternalList(); } return deletedParameters; } /** *

* The names of the deleted parameters. *

* * @param deletedParameters * The names of the deleted parameters. */ public void setDeletedParameters(java.util.Collection deletedParameters) { if (deletedParameters == null) { this.deletedParameters = null; return; } this.deletedParameters = new com.amazonaws.internal.SdkInternalList(deletedParameters); } /** *

* The names of the deleted parameters. *

*

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

* * @param deletedParameters * The names of the deleted parameters. * @return Returns a reference to this object so that method calls can be chained together. */ public DeleteParametersResult withDeletedParameters(String... deletedParameters) { if (this.deletedParameters == null) { setDeletedParameters(new com.amazonaws.internal.SdkInternalList(deletedParameters.length)); } for (String ele : deletedParameters) { this.deletedParameters.add(ele); } return this; } /** *

* The names of the deleted parameters. *

* * @param deletedParameters * The names of the deleted parameters. * @return Returns a reference to this object so that method calls can be chained together. */ public DeleteParametersResult withDeletedParameters(java.util.Collection deletedParameters) { setDeletedParameters(deletedParameters); return this; } /** *

* The names of parameters that weren't deleted because the parameters aren't valid. *

* * @return The names of parameters that weren't deleted because the parameters aren't valid. */ public java.util.List getInvalidParameters() { if (invalidParameters == null) { invalidParameters = new com.amazonaws.internal.SdkInternalList(); } return invalidParameters; } /** *

* The names of parameters that weren't deleted because the parameters aren't valid. *

* * @param invalidParameters * The names of parameters that weren't deleted because the parameters aren't valid. */ public void setInvalidParameters(java.util.Collection invalidParameters) { if (invalidParameters == null) { this.invalidParameters = null; return; } this.invalidParameters = new com.amazonaws.internal.SdkInternalList(invalidParameters); } /** *

* The names of parameters that weren't deleted because the parameters aren't valid. *

*

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

* * @param invalidParameters * The names of parameters that weren't deleted because the parameters aren't valid. * @return Returns a reference to this object so that method calls can be chained together. */ public DeleteParametersResult withInvalidParameters(String... invalidParameters) { if (this.invalidParameters == null) { setInvalidParameters(new com.amazonaws.internal.SdkInternalList(invalidParameters.length)); } for (String ele : invalidParameters) { this.invalidParameters.add(ele); } return this; } /** *

* The names of parameters that weren't deleted because the parameters aren't valid. *

* * @param invalidParameters * The names of parameters that weren't deleted because the parameters aren't valid. * @return Returns a reference to this object so that method calls can be chained together. */ public DeleteParametersResult withInvalidParameters(java.util.Collection invalidParameters) { setInvalidParameters(invalidParameters); 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 (getDeletedParameters() != null) sb.append("DeletedParameters: ").append(getDeletedParameters()).append(","); if (getInvalidParameters() != null) sb.append("InvalidParameters: ").append(getInvalidParameters()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof DeleteParametersResult == false) return false; DeleteParametersResult other = (DeleteParametersResult) obj; if (other.getDeletedParameters() == null ^ this.getDeletedParameters() == null) return false; if (other.getDeletedParameters() != null && other.getDeletedParameters().equals(this.getDeletedParameters()) == false) return false; if (other.getInvalidParameters() == null ^ this.getInvalidParameters() == null) return false; if (other.getInvalidParameters() != null && other.getInvalidParameters().equals(this.getInvalidParameters()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getDeletedParameters() == null) ? 0 : getDeletedParameters().hashCode()); hashCode = prime * hashCode + ((getInvalidParameters() == null) ? 0 : getInvalidParameters().hashCode()); return hashCode; } @Override public DeleteParametersResult clone() { try { return (DeleteParametersResult) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } }