com.amazonaws.services.workmail.model.DescribeOrganizationResult Maven / Gradle / Ivy
Show all versions of aws-java-sdk-workmail Show documentation
/*
* 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.workmail.model;
import java.io.Serializable;
import javax.annotation.Generated;
/**
*
* @see AWS API
* Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class DescribeOrganizationResult extends com.amazonaws.AmazonWebServiceResult implements Serializable, Cloneable {
/**
*
* The identifier of an organization.
*
*/
private String organizationId;
/**
*
* The alias for an organization.
*
*/
private String alias;
/**
*
* The state of an organization.
*
*/
private String state;
/**
*
* The identifier for the directory associated with an WorkMail organization.
*
*/
private String directoryId;
/**
*
* The type of directory associated with the WorkMail organization.
*
*/
private String directoryType;
/**
*
* The default mail domain associated with the organization.
*
*/
private String defaultMailDomain;
/**
*
* The date at which the organization became usable in the WorkMail context, in UNIX epoch time format.
*
*/
private java.util.Date completedDate;
/**
*
* (Optional) The error message indicating if unexpected behavior was encountered with regards to the organization.
*
*/
private String errorMessage;
/**
*
* The Amazon Resource Name (ARN) of the organization.
*
*/
private String aRN;
/**
*
* The user ID of the migration admin if migration is enabled for the organization.
*
*/
private String migrationAdmin;
/**
*
* Indicates if interoperability is enabled for this organization.
*
*/
private Boolean interoperabilityEnabled;
/**
*
* The identifier of an organization.
*
*
* @param organizationId
* The identifier of an organization.
*/
public void setOrganizationId(String organizationId) {
this.organizationId = organizationId;
}
/**
*
* The identifier of an organization.
*
*
* @return The identifier of an organization.
*/
public String getOrganizationId() {
return this.organizationId;
}
/**
*
* The identifier of an organization.
*
*
* @param organizationId
* The identifier of an organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withOrganizationId(String organizationId) {
setOrganizationId(organizationId);
return this;
}
/**
*
* The alias for an organization.
*
*
* @param alias
* The alias for an organization.
*/
public void setAlias(String alias) {
this.alias = alias;
}
/**
*
* The alias for an organization.
*
*
* @return The alias for an organization.
*/
public String getAlias() {
return this.alias;
}
/**
*
* The alias for an organization.
*
*
* @param alias
* The alias for an organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withAlias(String alias) {
setAlias(alias);
return this;
}
/**
*
* The state of an organization.
*
*
* @param state
* The state of an organization.
*/
public void setState(String state) {
this.state = state;
}
/**
*
* The state of an organization.
*
*
* @return The state of an organization.
*/
public String getState() {
return this.state;
}
/**
*
* The state of an organization.
*
*
* @param state
* The state of an organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withState(String state) {
setState(state);
return this;
}
/**
*
* The identifier for the directory associated with an WorkMail organization.
*
*
* @param directoryId
* The identifier for the directory associated with an WorkMail organization.
*/
public void setDirectoryId(String directoryId) {
this.directoryId = directoryId;
}
/**
*
* The identifier for the directory associated with an WorkMail organization.
*
*
* @return The identifier for the directory associated with an WorkMail organization.
*/
public String getDirectoryId() {
return this.directoryId;
}
/**
*
* The identifier for the directory associated with an WorkMail organization.
*
*
* @param directoryId
* The identifier for the directory associated with an WorkMail organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withDirectoryId(String directoryId) {
setDirectoryId(directoryId);
return this;
}
/**
*
* The type of directory associated with the WorkMail organization.
*
*
* @param directoryType
* The type of directory associated with the WorkMail organization.
*/
public void setDirectoryType(String directoryType) {
this.directoryType = directoryType;
}
/**
*
* The type of directory associated with the WorkMail organization.
*
*
* @return The type of directory associated with the WorkMail organization.
*/
public String getDirectoryType() {
return this.directoryType;
}
/**
*
* The type of directory associated with the WorkMail organization.
*
*
* @param directoryType
* The type of directory associated with the WorkMail organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withDirectoryType(String directoryType) {
setDirectoryType(directoryType);
return this;
}
/**
*
* The default mail domain associated with the organization.
*
*
* @param defaultMailDomain
* The default mail domain associated with the organization.
*/
public void setDefaultMailDomain(String defaultMailDomain) {
this.defaultMailDomain = defaultMailDomain;
}
/**
*
* The default mail domain associated with the organization.
*
*
* @return The default mail domain associated with the organization.
*/
public String getDefaultMailDomain() {
return this.defaultMailDomain;
}
/**
*
* The default mail domain associated with the organization.
*
*
* @param defaultMailDomain
* The default mail domain associated with the organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withDefaultMailDomain(String defaultMailDomain) {
setDefaultMailDomain(defaultMailDomain);
return this;
}
/**
*
* The date at which the organization became usable in the WorkMail context, in UNIX epoch time format.
*
*
* @param completedDate
* The date at which the organization became usable in the WorkMail context, in UNIX epoch time format.
*/
public void setCompletedDate(java.util.Date completedDate) {
this.completedDate = completedDate;
}
/**
*
* The date at which the organization became usable in the WorkMail context, in UNIX epoch time format.
*
*
* @return The date at which the organization became usable in the WorkMail context, in UNIX epoch time format.
*/
public java.util.Date getCompletedDate() {
return this.completedDate;
}
/**
*
* The date at which the organization became usable in the WorkMail context, in UNIX epoch time format.
*
*
* @param completedDate
* The date at which the organization became usable in the WorkMail context, in UNIX epoch time format.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withCompletedDate(java.util.Date completedDate) {
setCompletedDate(completedDate);
return this;
}
/**
*
* (Optional) The error message indicating if unexpected behavior was encountered with regards to the organization.
*
*
* @param errorMessage
* (Optional) The error message indicating if unexpected behavior was encountered with regards to the
* organization.
*/
public void setErrorMessage(String errorMessage) {
this.errorMessage = errorMessage;
}
/**
*
* (Optional) The error message indicating if unexpected behavior was encountered with regards to the organization.
*
*
* @return (Optional) The error message indicating if unexpected behavior was encountered with regards to the
* organization.
*/
public String getErrorMessage() {
return this.errorMessage;
}
/**
*
* (Optional) The error message indicating if unexpected behavior was encountered with regards to the organization.
*
*
* @param errorMessage
* (Optional) The error message indicating if unexpected behavior was encountered with regards to the
* organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withErrorMessage(String errorMessage) {
setErrorMessage(errorMessage);
return this;
}
/**
*
* The Amazon Resource Name (ARN) of the organization.
*
*
* @param aRN
* The Amazon Resource Name (ARN) of the organization.
*/
public void setARN(String aRN) {
this.aRN = aRN;
}
/**
*
* The Amazon Resource Name (ARN) of the organization.
*
*
* @return The Amazon Resource Name (ARN) of the organization.
*/
public String getARN() {
return this.aRN;
}
/**
*
* The Amazon Resource Name (ARN) of the organization.
*
*
* @param aRN
* The Amazon Resource Name (ARN) of the organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withARN(String aRN) {
setARN(aRN);
return this;
}
/**
*
* The user ID of the migration admin if migration is enabled for the organization.
*
*
* @param migrationAdmin
* The user ID of the migration admin if migration is enabled for the organization.
*/
public void setMigrationAdmin(String migrationAdmin) {
this.migrationAdmin = migrationAdmin;
}
/**
*
* The user ID of the migration admin if migration is enabled for the organization.
*
*
* @return The user ID of the migration admin if migration is enabled for the organization.
*/
public String getMigrationAdmin() {
return this.migrationAdmin;
}
/**
*
* The user ID of the migration admin if migration is enabled for the organization.
*
*
* @param migrationAdmin
* The user ID of the migration admin if migration is enabled for the organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withMigrationAdmin(String migrationAdmin) {
setMigrationAdmin(migrationAdmin);
return this;
}
/**
*
* Indicates if interoperability is enabled for this organization.
*
*
* @param interoperabilityEnabled
* Indicates if interoperability is enabled for this organization.
*/
public void setInteroperabilityEnabled(Boolean interoperabilityEnabled) {
this.interoperabilityEnabled = interoperabilityEnabled;
}
/**
*
* Indicates if interoperability is enabled for this organization.
*
*
* @return Indicates if interoperability is enabled for this organization.
*/
public Boolean getInteroperabilityEnabled() {
return this.interoperabilityEnabled;
}
/**
*
* Indicates if interoperability is enabled for this organization.
*
*
* @param interoperabilityEnabled
* Indicates if interoperability is enabled for this organization.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public DescribeOrganizationResult withInteroperabilityEnabled(Boolean interoperabilityEnabled) {
setInteroperabilityEnabled(interoperabilityEnabled);
return this;
}
/**
*
* Indicates if interoperability is enabled for this organization.
*
*
* @return Indicates if interoperability is enabled for this organization.
*/
public Boolean isInteroperabilityEnabled() {
return this.interoperabilityEnabled;
}
/**
* 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 (getOrganizationId() != null)
sb.append("OrganizationId: ").append(getOrganizationId()).append(",");
if (getAlias() != null)
sb.append("Alias: ").append(getAlias()).append(",");
if (getState() != null)
sb.append("State: ").append(getState()).append(",");
if (getDirectoryId() != null)
sb.append("DirectoryId: ").append(getDirectoryId()).append(",");
if (getDirectoryType() != null)
sb.append("DirectoryType: ").append(getDirectoryType()).append(",");
if (getDefaultMailDomain() != null)
sb.append("DefaultMailDomain: ").append(getDefaultMailDomain()).append(",");
if (getCompletedDate() != null)
sb.append("CompletedDate: ").append(getCompletedDate()).append(",");
if (getErrorMessage() != null)
sb.append("ErrorMessage: ").append(getErrorMessage()).append(",");
if (getARN() != null)
sb.append("ARN: ").append(getARN()).append(",");
if (getMigrationAdmin() != null)
sb.append("MigrationAdmin: ").append(getMigrationAdmin()).append(",");
if (getInteroperabilityEnabled() != null)
sb.append("InteroperabilityEnabled: ").append(getInteroperabilityEnabled());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof DescribeOrganizationResult == false)
return false;
DescribeOrganizationResult other = (DescribeOrganizationResult) obj;
if (other.getOrganizationId() == null ^ this.getOrganizationId() == null)
return false;
if (other.getOrganizationId() != null && other.getOrganizationId().equals(this.getOrganizationId()) == false)
return false;
if (other.getAlias() == null ^ this.getAlias() == null)
return false;
if (other.getAlias() != null && other.getAlias().equals(this.getAlias()) == 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.getDirectoryId() == null ^ this.getDirectoryId() == null)
return false;
if (other.getDirectoryId() != null && other.getDirectoryId().equals(this.getDirectoryId()) == false)
return false;
if (other.getDirectoryType() == null ^ this.getDirectoryType() == null)
return false;
if (other.getDirectoryType() != null && other.getDirectoryType().equals(this.getDirectoryType()) == false)
return false;
if (other.getDefaultMailDomain() == null ^ this.getDefaultMailDomain() == null)
return false;
if (other.getDefaultMailDomain() != null && other.getDefaultMailDomain().equals(this.getDefaultMailDomain()) == false)
return false;
if (other.getCompletedDate() == null ^ this.getCompletedDate() == null)
return false;
if (other.getCompletedDate() != null && other.getCompletedDate().equals(this.getCompletedDate()) == 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.getARN() == null ^ this.getARN() == null)
return false;
if (other.getARN() != null && other.getARN().equals(this.getARN()) == false)
return false;
if (other.getMigrationAdmin() == null ^ this.getMigrationAdmin() == null)
return false;
if (other.getMigrationAdmin() != null && other.getMigrationAdmin().equals(this.getMigrationAdmin()) == false)
return false;
if (other.getInteroperabilityEnabled() == null ^ this.getInteroperabilityEnabled() == null)
return false;
if (other.getInteroperabilityEnabled() != null && other.getInteroperabilityEnabled().equals(this.getInteroperabilityEnabled()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getOrganizationId() == null) ? 0 : getOrganizationId().hashCode());
hashCode = prime * hashCode + ((getAlias() == null) ? 0 : getAlias().hashCode());
hashCode = prime * hashCode + ((getState() == null) ? 0 : getState().hashCode());
hashCode = prime * hashCode + ((getDirectoryId() == null) ? 0 : getDirectoryId().hashCode());
hashCode = prime * hashCode + ((getDirectoryType() == null) ? 0 : getDirectoryType().hashCode());
hashCode = prime * hashCode + ((getDefaultMailDomain() == null) ? 0 : getDefaultMailDomain().hashCode());
hashCode = prime * hashCode + ((getCompletedDate() == null) ? 0 : getCompletedDate().hashCode());
hashCode = prime * hashCode + ((getErrorMessage() == null) ? 0 : getErrorMessage().hashCode());
hashCode = prime * hashCode + ((getARN() == null) ? 0 : getARN().hashCode());
hashCode = prime * hashCode + ((getMigrationAdmin() == null) ? 0 : getMigrationAdmin().hashCode());
hashCode = prime * hashCode + ((getInteroperabilityEnabled() == null) ? 0 : getInteroperabilityEnabled().hashCode());
return hashCode;
}
@Override
public DescribeOrganizationResult clone() {
try {
return (DescribeOrganizationResult) super.clone();
} catch (CloneNotSupportedException e) {
throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
}
}
}