com.amazonaws.services.workspaces.model.Workspace Maven / Gradle / Ivy
Show all versions of aws-java-sdk-workspaces Show documentation
/*
* Copyright 2016-2021 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.workspaces.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* Describes a WorkSpace.
*
*
* @see AWS API
* Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class Workspace implements Serializable, Cloneable, StructuredPojo {
/**
*
* The identifier of the WorkSpace.
*
*/
private String workspaceId;
/**
*
* The identifier of the AWS Directory Service directory for the WorkSpace.
*
*/
private String directoryId;
/**
*
* The user for the WorkSpace.
*
*/
private String userName;
/**
*
* The IP address of the WorkSpace.
*
*/
private String ipAddress;
/**
*
* The operational state of the WorkSpace.
*
*
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the WorkSpace
* directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace is terminated,
* check for the WorkSpace ID by using DescribeWorkSpaces. If
* the WorkSpace ID isn't returned, then the WorkSpace has been successfully terminated.
*
*
*/
private String state;
/**
*
* The identifier of the bundle used to create the WorkSpace.
*
*/
private String bundleId;
/**
*
* The identifier of the subnet for the WorkSpace.
*
*/
private String subnetId;
/**
*
* The text of the error message that is returned if the WorkSpace cannot be created.
*
*/
private String errorMessage;
/**
*
* The error code that is returned if the WorkSpace cannot be created.
*
*/
private String errorCode;
/**
*
* The name of the WorkSpace, as seen by the operating system. The format of this name varies. For more information,
* see Launch a
* WorkSpace.
*
*/
private String computerName;
/**
*
* The symmetric AWS KMS customer master key (CMK) used to encrypt data stored on your WorkSpace. Amazon WorkSpaces
* does not support asymmetric CMKs.
*
*/
private String volumeEncryptionKey;
/**
*
* Indicates whether the data stored on the user volume is encrypted.
*
*/
private Boolean userVolumeEncryptionEnabled;
/**
*
* Indicates whether the data stored on the root volume is encrypted.
*
*/
private Boolean rootVolumeEncryptionEnabled;
/**
*
* The properties of the WorkSpace.
*
*/
private WorkspaceProperties workspaceProperties;
/**
*
* The modification states of the WorkSpace.
*
*/
private com.amazonaws.internal.SdkInternalList modificationStates;
/**
*
* The identifier of the WorkSpace.
*
*
* @param workspaceId
* The identifier of the WorkSpace.
*/
public void setWorkspaceId(String workspaceId) {
this.workspaceId = workspaceId;
}
/**
*
* The identifier of the WorkSpace.
*
*
* @return The identifier of the WorkSpace.
*/
public String getWorkspaceId() {
return this.workspaceId;
}
/**
*
* The identifier of the WorkSpace.
*
*
* @param workspaceId
* The identifier of the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withWorkspaceId(String workspaceId) {
setWorkspaceId(workspaceId);
return this;
}
/**
*
* The identifier of the AWS Directory Service directory for the WorkSpace.
*
*
* @param directoryId
* The identifier of the AWS Directory Service directory for the WorkSpace.
*/
public void setDirectoryId(String directoryId) {
this.directoryId = directoryId;
}
/**
*
* The identifier of the AWS Directory Service directory for the WorkSpace.
*
*
* @return The identifier of the AWS Directory Service directory for the WorkSpace.
*/
public String getDirectoryId() {
return this.directoryId;
}
/**
*
* The identifier of the AWS Directory Service directory for the WorkSpace.
*
*
* @param directoryId
* The identifier of the AWS Directory Service directory for the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withDirectoryId(String directoryId) {
setDirectoryId(directoryId);
return this;
}
/**
*
* The user for the WorkSpace.
*
*
* @param userName
* The user for the WorkSpace.
*/
public void setUserName(String userName) {
this.userName = userName;
}
/**
*
* The user for the WorkSpace.
*
*
* @return The user for the WorkSpace.
*/
public String getUserName() {
return this.userName;
}
/**
*
* The user for the WorkSpace.
*
*
* @param userName
* The user for the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withUserName(String userName) {
setUserName(userName);
return this;
}
/**
*
* The IP address of the WorkSpace.
*
*
* @param ipAddress
* The IP address of the WorkSpace.
*/
public void setIpAddress(String ipAddress) {
this.ipAddress = ipAddress;
}
/**
*
* The IP address of the WorkSpace.
*
*
* @return The IP address of the WorkSpace.
*/
public String getIpAddress() {
return this.ipAddress;
}
/**
*
* The IP address of the WorkSpace.
*
*
* @param ipAddress
* The IP address of the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withIpAddress(String ipAddress) {
setIpAddress(ipAddress);
return this;
}
/**
*
* The operational state of the WorkSpace.
*
*
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the WorkSpace
* directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace is terminated,
* check for the WorkSpace ID by using DescribeWorkSpaces. If
* the WorkSpace ID isn't returned, then the WorkSpace has been successfully terminated.
*
*
*
* @param state
* The operational state of the WorkSpace.
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the
* WorkSpace directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace
* is terminated, check for the WorkSpace ID by using
* DescribeWorkSpaces. If the WorkSpace ID isn't returned, then the WorkSpace has been successfully
* terminated.
*
* @see WorkspaceState
*/
public void setState(String state) {
this.state = state;
}
/**
*
* The operational state of the WorkSpace.
*
*
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the WorkSpace
* directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace is terminated,
* check for the WorkSpace ID by using DescribeWorkSpaces. If
* the WorkSpace ID isn't returned, then the WorkSpace has been successfully terminated.
*
*
*
* @return The operational state of the WorkSpace.
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the
* WorkSpace directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace
* is terminated, check for the WorkSpace ID by using
* DescribeWorkSpaces. If the WorkSpace ID isn't returned, then the WorkSpace has been successfully
* terminated.
*
* @see WorkspaceState
*/
public String getState() {
return this.state;
}
/**
*
* The operational state of the WorkSpace.
*
*
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the WorkSpace
* directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace is terminated,
* check for the WorkSpace ID by using DescribeWorkSpaces. If
* the WorkSpace ID isn't returned, then the WorkSpace has been successfully terminated.
*
*
*
* @param state
* The operational state of the WorkSpace.
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the
* WorkSpace directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace
* is terminated, check for the WorkSpace ID by using
* DescribeWorkSpaces. If the WorkSpace ID isn't returned, then the WorkSpace has been successfully
* terminated.
*
* @return Returns a reference to this object so that method calls can be chained together.
* @see WorkspaceState
*/
public Workspace withState(String state) {
setState(state);
return this;
}
/**
*
* The operational state of the WorkSpace.
*
*
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the WorkSpace
* directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace is terminated,
* check for the WorkSpace ID by using DescribeWorkSpaces. If
* the WorkSpace ID isn't returned, then the WorkSpace has been successfully terminated.
*
*
*
* @param state
* The operational state of the WorkSpace.
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the
* WorkSpace directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace
* is terminated, check for the WorkSpace ID by using
* DescribeWorkSpaces. If the WorkSpace ID isn't returned, then the WorkSpace has been successfully
* terminated.
*
* @see WorkspaceState
*/
public void setState(WorkspaceState state) {
withState(state);
}
/**
*
* The operational state of the WorkSpace.
*
*
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the WorkSpace
* directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace is terminated,
* check for the WorkSpace ID by using DescribeWorkSpaces. If
* the WorkSpace ID isn't returned, then the WorkSpace has been successfully terminated.
*
*
*
* @param state
* The operational state of the WorkSpace.
*
* After a WorkSpace is terminated, the TERMINATED
state is returned only briefly before the
* WorkSpace directory metadata is cleaned up, so this state is rarely returned. To confirm that a WorkSpace
* is terminated, check for the WorkSpace ID by using
* DescribeWorkSpaces. If the WorkSpace ID isn't returned, then the WorkSpace has been successfully
* terminated.
*
* @return Returns a reference to this object so that method calls can be chained together.
* @see WorkspaceState
*/
public Workspace withState(WorkspaceState state) {
this.state = state.toString();
return this;
}
/**
*
* The identifier of the bundle used to create the WorkSpace.
*
*
* @param bundleId
* The identifier of the bundle used to create the WorkSpace.
*/
public void setBundleId(String bundleId) {
this.bundleId = bundleId;
}
/**
*
* The identifier of the bundle used to create the WorkSpace.
*
*
* @return The identifier of the bundle used to create the WorkSpace.
*/
public String getBundleId() {
return this.bundleId;
}
/**
*
* The identifier of the bundle used to create the WorkSpace.
*
*
* @param bundleId
* The identifier of the bundle used to create the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withBundleId(String bundleId) {
setBundleId(bundleId);
return this;
}
/**
*
* The identifier of the subnet for the WorkSpace.
*
*
* @param subnetId
* The identifier of the subnet for the WorkSpace.
*/
public void setSubnetId(String subnetId) {
this.subnetId = subnetId;
}
/**
*
* The identifier of the subnet for the WorkSpace.
*
*
* @return The identifier of the subnet for the WorkSpace.
*/
public String getSubnetId() {
return this.subnetId;
}
/**
*
* The identifier of the subnet for the WorkSpace.
*
*
* @param subnetId
* The identifier of the subnet for the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withSubnetId(String subnetId) {
setSubnetId(subnetId);
return this;
}
/**
*
* The text of the error message that is returned if the WorkSpace cannot be created.
*
*
* @param errorMessage
* The text of the error message that is returned if the WorkSpace cannot be created.
*/
public void setErrorMessage(String errorMessage) {
this.errorMessage = errorMessage;
}
/**
*
* The text of the error message that is returned if the WorkSpace cannot be created.
*
*
* @return The text of the error message that is returned if the WorkSpace cannot be created.
*/
public String getErrorMessage() {
return this.errorMessage;
}
/**
*
* The text of the error message that is returned if the WorkSpace cannot be created.
*
*
* @param errorMessage
* The text of the error message that is returned if the WorkSpace cannot be created.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withErrorMessage(String errorMessage) {
setErrorMessage(errorMessage);
return this;
}
/**
*
* The error code that is returned if the WorkSpace cannot be created.
*
*
* @param errorCode
* The error code that is returned if the WorkSpace cannot be created.
*/
public void setErrorCode(String errorCode) {
this.errorCode = errorCode;
}
/**
*
* The error code that is returned if the WorkSpace cannot be created.
*
*
* @return The error code that is returned if the WorkSpace cannot be created.
*/
public String getErrorCode() {
return this.errorCode;
}
/**
*
* The error code that is returned if the WorkSpace cannot be created.
*
*
* @param errorCode
* The error code that is returned if the WorkSpace cannot be created.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withErrorCode(String errorCode) {
setErrorCode(errorCode);
return this;
}
/**
*
* The name of the WorkSpace, as seen by the operating system. The format of this name varies. For more information,
* see Launch a
* WorkSpace.
*
*
* @param computerName
* The name of the WorkSpace, as seen by the operating system. The format of this name varies. For more
* information, see Launch a
* WorkSpace.
*/
public void setComputerName(String computerName) {
this.computerName = computerName;
}
/**
*
* The name of the WorkSpace, as seen by the operating system. The format of this name varies. For more information,
* see Launch a
* WorkSpace.
*
*
* @return The name of the WorkSpace, as seen by the operating system. The format of this name varies. For more
* information, see Launch
* a WorkSpace.
*/
public String getComputerName() {
return this.computerName;
}
/**
*
* The name of the WorkSpace, as seen by the operating system. The format of this name varies. For more information,
* see Launch a
* WorkSpace.
*
*
* @param computerName
* The name of the WorkSpace, as seen by the operating system. The format of this name varies. For more
* information, see Launch a
* WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withComputerName(String computerName) {
setComputerName(computerName);
return this;
}
/**
*
* The symmetric AWS KMS customer master key (CMK) used to encrypt data stored on your WorkSpace. Amazon WorkSpaces
* does not support asymmetric CMKs.
*
*
* @param volumeEncryptionKey
* The symmetric AWS KMS customer master key (CMK) used to encrypt data stored on your WorkSpace. Amazon
* WorkSpaces does not support asymmetric CMKs.
*/
public void setVolumeEncryptionKey(String volumeEncryptionKey) {
this.volumeEncryptionKey = volumeEncryptionKey;
}
/**
*
* The symmetric AWS KMS customer master key (CMK) used to encrypt data stored on your WorkSpace. Amazon WorkSpaces
* does not support asymmetric CMKs.
*
*
* @return The symmetric AWS KMS customer master key (CMK) used to encrypt data stored on your WorkSpace. Amazon
* WorkSpaces does not support asymmetric CMKs.
*/
public String getVolumeEncryptionKey() {
return this.volumeEncryptionKey;
}
/**
*
* The symmetric AWS KMS customer master key (CMK) used to encrypt data stored on your WorkSpace. Amazon WorkSpaces
* does not support asymmetric CMKs.
*
*
* @param volumeEncryptionKey
* The symmetric AWS KMS customer master key (CMK) used to encrypt data stored on your WorkSpace. Amazon
* WorkSpaces does not support asymmetric CMKs.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withVolumeEncryptionKey(String volumeEncryptionKey) {
setVolumeEncryptionKey(volumeEncryptionKey);
return this;
}
/**
*
* Indicates whether the data stored on the user volume is encrypted.
*
*
* @param userVolumeEncryptionEnabled
* Indicates whether the data stored on the user volume is encrypted.
*/
public void setUserVolumeEncryptionEnabled(Boolean userVolumeEncryptionEnabled) {
this.userVolumeEncryptionEnabled = userVolumeEncryptionEnabled;
}
/**
*
* Indicates whether the data stored on the user volume is encrypted.
*
*
* @return Indicates whether the data stored on the user volume is encrypted.
*/
public Boolean getUserVolumeEncryptionEnabled() {
return this.userVolumeEncryptionEnabled;
}
/**
*
* Indicates whether the data stored on the user volume is encrypted.
*
*
* @param userVolumeEncryptionEnabled
* Indicates whether the data stored on the user volume is encrypted.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withUserVolumeEncryptionEnabled(Boolean userVolumeEncryptionEnabled) {
setUserVolumeEncryptionEnabled(userVolumeEncryptionEnabled);
return this;
}
/**
*
* Indicates whether the data stored on the user volume is encrypted.
*
*
* @return Indicates whether the data stored on the user volume is encrypted.
*/
public Boolean isUserVolumeEncryptionEnabled() {
return this.userVolumeEncryptionEnabled;
}
/**
*
* Indicates whether the data stored on the root volume is encrypted.
*
*
* @param rootVolumeEncryptionEnabled
* Indicates whether the data stored on the root volume is encrypted.
*/
public void setRootVolumeEncryptionEnabled(Boolean rootVolumeEncryptionEnabled) {
this.rootVolumeEncryptionEnabled = rootVolumeEncryptionEnabled;
}
/**
*
* Indicates whether the data stored on the root volume is encrypted.
*
*
* @return Indicates whether the data stored on the root volume is encrypted.
*/
public Boolean getRootVolumeEncryptionEnabled() {
return this.rootVolumeEncryptionEnabled;
}
/**
*
* Indicates whether the data stored on the root volume is encrypted.
*
*
* @param rootVolumeEncryptionEnabled
* Indicates whether the data stored on the root volume is encrypted.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withRootVolumeEncryptionEnabled(Boolean rootVolumeEncryptionEnabled) {
setRootVolumeEncryptionEnabled(rootVolumeEncryptionEnabled);
return this;
}
/**
*
* Indicates whether the data stored on the root volume is encrypted.
*
*
* @return Indicates whether the data stored on the root volume is encrypted.
*/
public Boolean isRootVolumeEncryptionEnabled() {
return this.rootVolumeEncryptionEnabled;
}
/**
*
* The properties of the WorkSpace.
*
*
* @param workspaceProperties
* The properties of the WorkSpace.
*/
public void setWorkspaceProperties(WorkspaceProperties workspaceProperties) {
this.workspaceProperties = workspaceProperties;
}
/**
*
* The properties of the WorkSpace.
*
*
* @return The properties of the WorkSpace.
*/
public WorkspaceProperties getWorkspaceProperties() {
return this.workspaceProperties;
}
/**
*
* The properties of the WorkSpace.
*
*
* @param workspaceProperties
* The properties of the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withWorkspaceProperties(WorkspaceProperties workspaceProperties) {
setWorkspaceProperties(workspaceProperties);
return this;
}
/**
*
* The modification states of the WorkSpace.
*
*
* @return The modification states of the WorkSpace.
*/
public java.util.List getModificationStates() {
if (modificationStates == null) {
modificationStates = new com.amazonaws.internal.SdkInternalList();
}
return modificationStates;
}
/**
*
* The modification states of the WorkSpace.
*
*
* @param modificationStates
* The modification states of the WorkSpace.
*/
public void setModificationStates(java.util.Collection modificationStates) {
if (modificationStates == null) {
this.modificationStates = null;
return;
}
this.modificationStates = new com.amazonaws.internal.SdkInternalList(modificationStates);
}
/**
*
* The modification states of the WorkSpace.
*
*
* NOTE: This method appends the values to the existing list (if any). Use
* {@link #setModificationStates(java.util.Collection)} or {@link #withModificationStates(java.util.Collection)} if
* you want to override the existing values.
*
*
* @param modificationStates
* The modification states of the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withModificationStates(ModificationState... modificationStates) {
if (this.modificationStates == null) {
setModificationStates(new com.amazonaws.internal.SdkInternalList(modificationStates.length));
}
for (ModificationState ele : modificationStates) {
this.modificationStates.add(ele);
}
return this;
}
/**
*
* The modification states of the WorkSpace.
*
*
* @param modificationStates
* The modification states of the WorkSpace.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public Workspace withModificationStates(java.util.Collection modificationStates) {
setModificationStates(modificationStates);
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 (getWorkspaceId() != null)
sb.append("WorkspaceId: ").append(getWorkspaceId()).append(",");
if (getDirectoryId() != null)
sb.append("DirectoryId: ").append(getDirectoryId()).append(",");
if (getUserName() != null)
sb.append("UserName: ").append(getUserName()).append(",");
if (getIpAddress() != null)
sb.append("IpAddress: ").append(getIpAddress()).append(",");
if (getState() != null)
sb.append("State: ").append(getState()).append(",");
if (getBundleId() != null)
sb.append("BundleId: ").append(getBundleId()).append(",");
if (getSubnetId() != null)
sb.append("SubnetId: ").append(getSubnetId()).append(",");
if (getErrorMessage() != null)
sb.append("ErrorMessage: ").append(getErrorMessage()).append(",");
if (getErrorCode() != null)
sb.append("ErrorCode: ").append(getErrorCode()).append(",");
if (getComputerName() != null)
sb.append("ComputerName: ").append(getComputerName()).append(",");
if (getVolumeEncryptionKey() != null)
sb.append("VolumeEncryptionKey: ").append(getVolumeEncryptionKey()).append(",");
if (getUserVolumeEncryptionEnabled() != null)
sb.append("UserVolumeEncryptionEnabled: ").append(getUserVolumeEncryptionEnabled()).append(",");
if (getRootVolumeEncryptionEnabled() != null)
sb.append("RootVolumeEncryptionEnabled: ").append(getRootVolumeEncryptionEnabled()).append(",");
if (getWorkspaceProperties() != null)
sb.append("WorkspaceProperties: ").append(getWorkspaceProperties()).append(",");
if (getModificationStates() != null)
sb.append("ModificationStates: ").append(getModificationStates());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof Workspace == false)
return false;
Workspace other = (Workspace) obj;
if (other.getWorkspaceId() == null ^ this.getWorkspaceId() == null)
return false;
if (other.getWorkspaceId() != null && other.getWorkspaceId().equals(this.getWorkspaceId()) == false)
return false;
if (other.getDirectoryId() == null ^ this.getDirectoryId() == null)
return false;
if (other.getDirectoryId() != null && other.getDirectoryId().equals(this.getDirectoryId()) == false)
return false;
if (other.getUserName() == null ^ this.getUserName() == null)
return false;
if (other.getUserName() != null && other.getUserName().equals(this.getUserName()) == false)
return false;
if (other.getIpAddress() == null ^ this.getIpAddress() == null)
return false;
if (other.getIpAddress() != null && other.getIpAddress().equals(this.getIpAddress()) == false)
return false;
if (other.getState() == null ^ this.getState() == null)
return false;
if (other.getState() != null && other.getState().equals(this.getState()) == false)
return false;
if (other.getBundleId() == null ^ this.getBundleId() == null)
return false;
if (other.getBundleId() != null && other.getBundleId().equals(this.getBundleId()) == false)
return false;
if (other.getSubnetId() == null ^ this.getSubnetId() == null)
return false;
if (other.getSubnetId() != null && other.getSubnetId().equals(this.getSubnetId()) == false)
return false;
if (other.getErrorMessage() == null ^ this.getErrorMessage() == null)
return false;
if (other.getErrorMessage() != null && other.getErrorMessage().equals(this.getErrorMessage()) == false)
return false;
if (other.getErrorCode() == null ^ this.getErrorCode() == null)
return false;
if (other.getErrorCode() != null && other.getErrorCode().equals(this.getErrorCode()) == false)
return false;
if (other.getComputerName() == null ^ this.getComputerName() == null)
return false;
if (other.getComputerName() != null && other.getComputerName().equals(this.getComputerName()) == false)
return false;
if (other.getVolumeEncryptionKey() == null ^ this.getVolumeEncryptionKey() == null)
return false;
if (other.getVolumeEncryptionKey() != null && other.getVolumeEncryptionKey().equals(this.getVolumeEncryptionKey()) == false)
return false;
if (other.getUserVolumeEncryptionEnabled() == null ^ this.getUserVolumeEncryptionEnabled() == null)
return false;
if (other.getUserVolumeEncryptionEnabled() != null && other.getUserVolumeEncryptionEnabled().equals(this.getUserVolumeEncryptionEnabled()) == false)
return false;
if (other.getRootVolumeEncryptionEnabled() == null ^ this.getRootVolumeEncryptionEnabled() == null)
return false;
if (other.getRootVolumeEncryptionEnabled() != null && other.getRootVolumeEncryptionEnabled().equals(this.getRootVolumeEncryptionEnabled()) == false)
return false;
if (other.getWorkspaceProperties() == null ^ this.getWorkspaceProperties() == null)
return false;
if (other.getWorkspaceProperties() != null && other.getWorkspaceProperties().equals(this.getWorkspaceProperties()) == false)
return false;
if (other.getModificationStates() == null ^ this.getModificationStates() == null)
return false;
if (other.getModificationStates() != null && other.getModificationStates().equals(this.getModificationStates()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getWorkspaceId() == null) ? 0 : getWorkspaceId().hashCode());
hashCode = prime * hashCode + ((getDirectoryId() == null) ? 0 : getDirectoryId().hashCode());
hashCode = prime * hashCode + ((getUserName() == null) ? 0 : getUserName().hashCode());
hashCode = prime * hashCode + ((getIpAddress() == null) ? 0 : getIpAddress().hashCode());
hashCode = prime * hashCode + ((getState() == null) ? 0 : getState().hashCode());
hashCode = prime * hashCode + ((getBundleId() == null) ? 0 : getBundleId().hashCode());
hashCode = prime * hashCode + ((getSubnetId() == null) ? 0 : getSubnetId().hashCode());
hashCode = prime * hashCode + ((getErrorMessage() == null) ? 0 : getErrorMessage().hashCode());
hashCode = prime * hashCode + ((getErrorCode() == null) ? 0 : getErrorCode().hashCode());
hashCode = prime * hashCode + ((getComputerName() == null) ? 0 : getComputerName().hashCode());
hashCode = prime * hashCode + ((getVolumeEncryptionKey() == null) ? 0 : getVolumeEncryptionKey().hashCode());
hashCode = prime * hashCode + ((getUserVolumeEncryptionEnabled() == null) ? 0 : getUserVolumeEncryptionEnabled().hashCode());
hashCode = prime * hashCode + ((getRootVolumeEncryptionEnabled() == null) ? 0 : getRootVolumeEncryptionEnabled().hashCode());
hashCode = prime * hashCode + ((getWorkspaceProperties() == null) ? 0 : getWorkspaceProperties().hashCode());
hashCode = prime * hashCode + ((getModificationStates() == null) ? 0 : getModificationStates().hashCode());
return hashCode;
}
@Override
public Workspace clone() {
try {
return (Workspace) 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.workspaces.model.transform.WorkspaceMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}