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

com.amazonaws.services.workspacesweb.model.IpAccessSettings Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Amazon WorkSpaces Web module holds the client classes that are used for communicating with Amazon WorkSpaces Web Service

There is a newer version: 1.12.780
Show newest version
/*
 * 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.workspacesweb.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* The IP access settings resource that can be associated with a web portal. *

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

* The additional encryption context of the IP access settings. *

*/ private java.util.Map additionalEncryptionContext; /** *

* A list of web portal ARNs that this IP access settings resource is associated with. *

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

* The creation date timestamp of the IP access settings. *

*/ private java.util.Date creationDate; /** *

* The customer managed key used to encrypt sensitive information in the IP access settings. *

*/ private String customerManagedKey; /** *

* The description of the IP access settings. *

*/ private String description; /** *

* The display name of the IP access settings. *

*/ private String displayName; /** *

* The ARN of the IP access settings resource. *

*/ private String ipAccessSettingsArn; /** *

* The IP rules of the IP access settings. *

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

* The additional encryption context of the IP access settings. *

* * @return The additional encryption context of the IP access settings. */ public java.util.Map getAdditionalEncryptionContext() { return additionalEncryptionContext; } /** *

* The additional encryption context of the IP access settings. *

* * @param additionalEncryptionContext * The additional encryption context of the IP access settings. */ public void setAdditionalEncryptionContext(java.util.Map additionalEncryptionContext) { this.additionalEncryptionContext = additionalEncryptionContext; } /** *

* The additional encryption context of the IP access settings. *

* * @param additionalEncryptionContext * The additional encryption context of the IP access settings. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withAdditionalEncryptionContext(java.util.Map additionalEncryptionContext) { setAdditionalEncryptionContext(additionalEncryptionContext); return this; } /** * Add a single AdditionalEncryptionContext entry * * @see IpAccessSettings#withAdditionalEncryptionContext * @returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings addAdditionalEncryptionContextEntry(String key, String value) { if (null == this.additionalEncryptionContext) { this.additionalEncryptionContext = new java.util.HashMap(); } if (this.additionalEncryptionContext.containsKey(key)) throw new IllegalArgumentException("Duplicated keys (" + key.toString() + ") are provided."); this.additionalEncryptionContext.put(key, value); return this; } /** * Removes all the entries added into AdditionalEncryptionContext. * * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings clearAdditionalEncryptionContextEntries() { this.additionalEncryptionContext = null; return this; } /** *

* A list of web portal ARNs that this IP access settings resource is associated with. *

* * @return A list of web portal ARNs that this IP access settings resource is associated with. */ public java.util.List getAssociatedPortalArns() { return associatedPortalArns; } /** *

* A list of web portal ARNs that this IP access settings resource is associated with. *

* * @param associatedPortalArns * A list of web portal ARNs that this IP access settings resource is associated with. */ public void setAssociatedPortalArns(java.util.Collection associatedPortalArns) { if (associatedPortalArns == null) { this.associatedPortalArns = null; return; } this.associatedPortalArns = new java.util.ArrayList(associatedPortalArns); } /** *

* A list of web portal ARNs that this IP access settings resource is associated with. *

*

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

* * @param associatedPortalArns * A list of web portal ARNs that this IP access settings resource is associated with. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withAssociatedPortalArns(String... associatedPortalArns) { if (this.associatedPortalArns == null) { setAssociatedPortalArns(new java.util.ArrayList(associatedPortalArns.length)); } for (String ele : associatedPortalArns) { this.associatedPortalArns.add(ele); } return this; } /** *

* A list of web portal ARNs that this IP access settings resource is associated with. *

* * @param associatedPortalArns * A list of web portal ARNs that this IP access settings resource is associated with. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withAssociatedPortalArns(java.util.Collection associatedPortalArns) { setAssociatedPortalArns(associatedPortalArns); return this; } /** *

* The creation date timestamp of the IP access settings. *

* * @param creationDate * The creation date timestamp of the IP access settings. */ public void setCreationDate(java.util.Date creationDate) { this.creationDate = creationDate; } /** *

* The creation date timestamp of the IP access settings. *

* * @return The creation date timestamp of the IP access settings. */ public java.util.Date getCreationDate() { return this.creationDate; } /** *

* The creation date timestamp of the IP access settings. *

* * @param creationDate * The creation date timestamp of the IP access settings. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withCreationDate(java.util.Date creationDate) { setCreationDate(creationDate); return this; } /** *

* The customer managed key used to encrypt sensitive information in the IP access settings. *

* * @param customerManagedKey * The customer managed key used to encrypt sensitive information in the IP access settings. */ public void setCustomerManagedKey(String customerManagedKey) { this.customerManagedKey = customerManagedKey; } /** *

* The customer managed key used to encrypt sensitive information in the IP access settings. *

* * @return The customer managed key used to encrypt sensitive information in the IP access settings. */ public String getCustomerManagedKey() { return this.customerManagedKey; } /** *

* The customer managed key used to encrypt sensitive information in the IP access settings. *

* * @param customerManagedKey * The customer managed key used to encrypt sensitive information in the IP access settings. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withCustomerManagedKey(String customerManagedKey) { setCustomerManagedKey(customerManagedKey); return this; } /** *

* The description of the IP access settings. *

* * @param description * The description of the IP access settings. */ public void setDescription(String description) { this.description = description; } /** *

* The description of the IP access settings. *

* * @return The description of the IP access settings. */ public String getDescription() { return this.description; } /** *

* The description of the IP access settings. *

* * @param description * The description of the IP access settings. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withDescription(String description) { setDescription(description); return this; } /** *

* The display name of the IP access settings. *

* * @param displayName * The display name of the IP access settings. */ public void setDisplayName(String displayName) { this.displayName = displayName; } /** *

* The display name of the IP access settings. *

* * @return The display name of the IP access settings. */ public String getDisplayName() { return this.displayName; } /** *

* The display name of the IP access settings. *

* * @param displayName * The display name of the IP access settings. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withDisplayName(String displayName) { setDisplayName(displayName); return this; } /** *

* The ARN of the IP access settings resource. *

* * @param ipAccessSettingsArn * The ARN of the IP access settings resource. */ public void setIpAccessSettingsArn(String ipAccessSettingsArn) { this.ipAccessSettingsArn = ipAccessSettingsArn; } /** *

* The ARN of the IP access settings resource. *

* * @return The ARN of the IP access settings resource. */ public String getIpAccessSettingsArn() { return this.ipAccessSettingsArn; } /** *

* The ARN of the IP access settings resource. *

* * @param ipAccessSettingsArn * The ARN of the IP access settings resource. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withIpAccessSettingsArn(String ipAccessSettingsArn) { setIpAccessSettingsArn(ipAccessSettingsArn); return this; } /** *

* The IP rules of the IP access settings. *

* * @return The IP rules of the IP access settings. */ public java.util.List getIpRules() { return ipRules; } /** *

* The IP rules of the IP access settings. *

* * @param ipRules * The IP rules of the IP access settings. */ public void setIpRules(java.util.Collection ipRules) { if (ipRules == null) { this.ipRules = null; return; } this.ipRules = new java.util.ArrayList(ipRules); } /** *

* The IP rules of the IP access settings. *

*

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

* * @param ipRules * The IP rules of the IP access settings. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withIpRules(IpRule... ipRules) { if (this.ipRules == null) { setIpRules(new java.util.ArrayList(ipRules.length)); } for (IpRule ele : ipRules) { this.ipRules.add(ele); } return this; } /** *

* The IP rules of the IP access settings. *

* * @param ipRules * The IP rules of the IP access settings. * @return Returns a reference to this object so that method calls can be chained together. */ public IpAccessSettings withIpRules(java.util.Collection ipRules) { setIpRules(ipRules); 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 (getAdditionalEncryptionContext() != null) sb.append("AdditionalEncryptionContext: ").append(getAdditionalEncryptionContext()).append(","); if (getAssociatedPortalArns() != null) sb.append("AssociatedPortalArns: ").append(getAssociatedPortalArns()).append(","); if (getCreationDate() != null) sb.append("CreationDate: ").append(getCreationDate()).append(","); if (getCustomerManagedKey() != null) sb.append("CustomerManagedKey: ").append(getCustomerManagedKey()).append(","); if (getDescription() != null) sb.append("Description: ").append("***Sensitive Data Redacted***").append(","); if (getDisplayName() != null) sb.append("DisplayName: ").append("***Sensitive Data Redacted***").append(","); if (getIpAccessSettingsArn() != null) sb.append("IpAccessSettingsArn: ").append(getIpAccessSettingsArn()).append(","); if (getIpRules() != null) sb.append("IpRules: ").append("***Sensitive Data Redacted***"); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof IpAccessSettings == false) return false; IpAccessSettings other = (IpAccessSettings) obj; if (other.getAdditionalEncryptionContext() == null ^ this.getAdditionalEncryptionContext() == null) return false; if (other.getAdditionalEncryptionContext() != null && other.getAdditionalEncryptionContext().equals(this.getAdditionalEncryptionContext()) == false) return false; if (other.getAssociatedPortalArns() == null ^ this.getAssociatedPortalArns() == null) return false; if (other.getAssociatedPortalArns() != null && other.getAssociatedPortalArns().equals(this.getAssociatedPortalArns()) == false) return false; if (other.getCreationDate() == null ^ this.getCreationDate() == null) return false; if (other.getCreationDate() != null && other.getCreationDate().equals(this.getCreationDate()) == false) return false; if (other.getCustomerManagedKey() == null ^ this.getCustomerManagedKey() == null) return false; if (other.getCustomerManagedKey() != null && other.getCustomerManagedKey().equals(this.getCustomerManagedKey()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getDisplayName() == null ^ this.getDisplayName() == null) return false; if (other.getDisplayName() != null && other.getDisplayName().equals(this.getDisplayName()) == false) return false; if (other.getIpAccessSettingsArn() == null ^ this.getIpAccessSettingsArn() == null) return false; if (other.getIpAccessSettingsArn() != null && other.getIpAccessSettingsArn().equals(this.getIpAccessSettingsArn()) == false) return false; if (other.getIpRules() == null ^ this.getIpRules() == null) return false; if (other.getIpRules() != null && other.getIpRules().equals(this.getIpRules()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAdditionalEncryptionContext() == null) ? 0 : getAdditionalEncryptionContext().hashCode()); hashCode = prime * hashCode + ((getAssociatedPortalArns() == null) ? 0 : getAssociatedPortalArns().hashCode()); hashCode = prime * hashCode + ((getCreationDate() == null) ? 0 : getCreationDate().hashCode()); hashCode = prime * hashCode + ((getCustomerManagedKey() == null) ? 0 : getCustomerManagedKey().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getDisplayName() == null) ? 0 : getDisplayName().hashCode()); hashCode = prime * hashCode + ((getIpAccessSettingsArn() == null) ? 0 : getIpAccessSettingsArn().hashCode()); hashCode = prime * hashCode + ((getIpRules() == null) ? 0 : getIpRules().hashCode()); return hashCode; } @Override public IpAccessSettings clone() { try { return (IpAccessSettings) 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.workspacesweb.model.transform.IpAccessSettingsMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy