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

com.amazonaws.services.sagemaker.model.UserSettings Maven / Gradle / Ivy

/*
 * Copyright 2015-2020 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.sagemaker.model;

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

/**
 * 

* A collection of settings. *

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

* The execution role for the user. *

*/ private String executionRole; /** *

* The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication. *

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. *

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

* The sharing settings. *

*/ private SharingSettings sharingSettings; /** *

* The Jupyter server's app settings. *

*/ private JupyterServerAppSettings jupyterServerAppSettings; /** *

* The kernel gateway app settings. *

*/ private KernelGatewayAppSettings kernelGatewayAppSettings; /** *

* The TensorBoard app settings. *

*/ private TensorBoardAppSettings tensorBoardAppSettings; /** *

* The execution role for the user. *

* * @param executionRole * The execution role for the user. */ public void setExecutionRole(String executionRole) { this.executionRole = executionRole; } /** *

* The execution role for the user. *

* * @return The execution role for the user. */ public String getExecutionRole() { return this.executionRole; } /** *

* The execution role for the user. *

* * @param executionRole * The execution role for the user. * @return Returns a reference to this object so that method calls can be chained together. */ public UserSettings withExecutionRole(String executionRole) { setExecutionRole(executionRole); return this; } /** *

* The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication. *

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. *

* * @return The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication.

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. */ public java.util.List getSecurityGroups() { return securityGroups; } /** *

* The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication. *

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. *

* * @param securityGroups * The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication.

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. */ public void setSecurityGroups(java.util.Collection securityGroups) { if (securityGroups == null) { this.securityGroups = null; return; } this.securityGroups = new java.util.ArrayList(securityGroups); } /** *

* The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication. *

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. *

*

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

* * @param securityGroups * The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication.

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. * @return Returns a reference to this object so that method calls can be chained together. */ public UserSettings withSecurityGroups(String... securityGroups) { if (this.securityGroups == null) { setSecurityGroups(new java.util.ArrayList(securityGroups.length)); } for (String ele : securityGroups) { this.securityGroups.add(ele); } return this; } /** *

* The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication. *

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. *

* * @param securityGroups * The security groups for the Amazon Virtual Private Cloud (VPC) that Studio uses for communication.

*

* Optional when the CreateDomain.AppNetworkAccessType parameter is set to * PublicInternetOnly. *

*

* Required when the CreateDomain.AppNetworkAccessType parameter is set to VpcOnly. * @return Returns a reference to this object so that method calls can be chained together. */ public UserSettings withSecurityGroups(java.util.Collection securityGroups) { setSecurityGroups(securityGroups); return this; } /** *

* The sharing settings. *

* * @param sharingSettings * The sharing settings. */ public void setSharingSettings(SharingSettings sharingSettings) { this.sharingSettings = sharingSettings; } /** *

* The sharing settings. *

* * @return The sharing settings. */ public SharingSettings getSharingSettings() { return this.sharingSettings; } /** *

* The sharing settings. *

* * @param sharingSettings * The sharing settings. * @return Returns a reference to this object so that method calls can be chained together. */ public UserSettings withSharingSettings(SharingSettings sharingSettings) { setSharingSettings(sharingSettings); return this; } /** *

* The Jupyter server's app settings. *

* * @param jupyterServerAppSettings * The Jupyter server's app settings. */ public void setJupyterServerAppSettings(JupyterServerAppSettings jupyterServerAppSettings) { this.jupyterServerAppSettings = jupyterServerAppSettings; } /** *

* The Jupyter server's app settings. *

* * @return The Jupyter server's app settings. */ public JupyterServerAppSettings getJupyterServerAppSettings() { return this.jupyterServerAppSettings; } /** *

* The Jupyter server's app settings. *

* * @param jupyterServerAppSettings * The Jupyter server's app settings. * @return Returns a reference to this object so that method calls can be chained together. */ public UserSettings withJupyterServerAppSettings(JupyterServerAppSettings jupyterServerAppSettings) { setJupyterServerAppSettings(jupyterServerAppSettings); return this; } /** *

* The kernel gateway app settings. *

* * @param kernelGatewayAppSettings * The kernel gateway app settings. */ public void setKernelGatewayAppSettings(KernelGatewayAppSettings kernelGatewayAppSettings) { this.kernelGatewayAppSettings = kernelGatewayAppSettings; } /** *

* The kernel gateway app settings. *

* * @return The kernel gateway app settings. */ public KernelGatewayAppSettings getKernelGatewayAppSettings() { return this.kernelGatewayAppSettings; } /** *

* The kernel gateway app settings. *

* * @param kernelGatewayAppSettings * The kernel gateway app settings. * @return Returns a reference to this object so that method calls can be chained together. */ public UserSettings withKernelGatewayAppSettings(KernelGatewayAppSettings kernelGatewayAppSettings) { setKernelGatewayAppSettings(kernelGatewayAppSettings); return this; } /** *

* The TensorBoard app settings. *

* * @param tensorBoardAppSettings * The TensorBoard app settings. */ public void setTensorBoardAppSettings(TensorBoardAppSettings tensorBoardAppSettings) { this.tensorBoardAppSettings = tensorBoardAppSettings; } /** *

* The TensorBoard app settings. *

* * @return The TensorBoard app settings. */ public TensorBoardAppSettings getTensorBoardAppSettings() { return this.tensorBoardAppSettings; } /** *

* The TensorBoard app settings. *

* * @param tensorBoardAppSettings * The TensorBoard app settings. * @return Returns a reference to this object so that method calls can be chained together. */ public UserSettings withTensorBoardAppSettings(TensorBoardAppSettings tensorBoardAppSettings) { setTensorBoardAppSettings(tensorBoardAppSettings); 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 (getExecutionRole() != null) sb.append("ExecutionRole: ").append(getExecutionRole()).append(","); if (getSecurityGroups() != null) sb.append("SecurityGroups: ").append(getSecurityGroups()).append(","); if (getSharingSettings() != null) sb.append("SharingSettings: ").append(getSharingSettings()).append(","); if (getJupyterServerAppSettings() != null) sb.append("JupyterServerAppSettings: ").append(getJupyterServerAppSettings()).append(","); if (getKernelGatewayAppSettings() != null) sb.append("KernelGatewayAppSettings: ").append(getKernelGatewayAppSettings()).append(","); if (getTensorBoardAppSettings() != null) sb.append("TensorBoardAppSettings: ").append(getTensorBoardAppSettings()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof UserSettings == false) return false; UserSettings other = (UserSettings) obj; if (other.getExecutionRole() == null ^ this.getExecutionRole() == null) return false; if (other.getExecutionRole() != null && other.getExecutionRole().equals(this.getExecutionRole()) == false) return false; if (other.getSecurityGroups() == null ^ this.getSecurityGroups() == null) return false; if (other.getSecurityGroups() != null && other.getSecurityGroups().equals(this.getSecurityGroups()) == false) return false; if (other.getSharingSettings() == null ^ this.getSharingSettings() == null) return false; if (other.getSharingSettings() != null && other.getSharingSettings().equals(this.getSharingSettings()) == false) return false; if (other.getJupyterServerAppSettings() == null ^ this.getJupyterServerAppSettings() == null) return false; if (other.getJupyterServerAppSettings() != null && other.getJupyterServerAppSettings().equals(this.getJupyterServerAppSettings()) == false) return false; if (other.getKernelGatewayAppSettings() == null ^ this.getKernelGatewayAppSettings() == null) return false; if (other.getKernelGatewayAppSettings() != null && other.getKernelGatewayAppSettings().equals(this.getKernelGatewayAppSettings()) == false) return false; if (other.getTensorBoardAppSettings() == null ^ this.getTensorBoardAppSettings() == null) return false; if (other.getTensorBoardAppSettings() != null && other.getTensorBoardAppSettings().equals(this.getTensorBoardAppSettings()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getExecutionRole() == null) ? 0 : getExecutionRole().hashCode()); hashCode = prime * hashCode + ((getSecurityGroups() == null) ? 0 : getSecurityGroups().hashCode()); hashCode = prime * hashCode + ((getSharingSettings() == null) ? 0 : getSharingSettings().hashCode()); hashCode = prime * hashCode + ((getJupyterServerAppSettings() == null) ? 0 : getJupyterServerAppSettings().hashCode()); hashCode = prime * hashCode + ((getKernelGatewayAppSettings() == null) ? 0 : getKernelGatewayAppSettings().hashCode()); hashCode = prime * hashCode + ((getTensorBoardAppSettings() == null) ? 0 : getTensorBoardAppSettings().hashCode()); return hashCode; } @Override public UserSettings clone() { try { return (UserSettings) 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.sagemaker.model.transform.UserSettingsMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy