com.amazonaws.services.directory.model.SchemaExtensionInfo Maven / Gradle / Ivy
Show all versions of aws-java-sdk-directory 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.directory.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* Information about a schema extension.
*
*
* @see AWS API
* Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class SchemaExtensionInfo implements Serializable, Cloneable, StructuredPojo {
/**
*
* The identifier of the directory to which the schema extension is applied.
*
*/
private String directoryId;
/**
*
* The identifier of the schema extension.
*
*/
private String schemaExtensionId;
/**
*
* A description of the schema extension.
*
*/
private String description;
/**
*
* The current status of the schema extension.
*
*/
private String schemaExtensionStatus;
/**
*
* The reason for the SchemaExtensionStatus
.
*
*/
private String schemaExtensionStatusReason;
/**
*
* The date and time that the schema extension started being applied to the directory.
*
*/
private java.util.Date startDateTime;
/**
*
* The date and time that the schema extension was completed.
*
*/
private java.util.Date endDateTime;
/**
*
* The identifier of the directory to which the schema extension is applied.
*
*
* @param directoryId
* The identifier of the directory to which the schema extension is applied.
*/
public void setDirectoryId(String directoryId) {
this.directoryId = directoryId;
}
/**
*
* The identifier of the directory to which the schema extension is applied.
*
*
* @return The identifier of the directory to which the schema extension is applied.
*/
public String getDirectoryId() {
return this.directoryId;
}
/**
*
* The identifier of the directory to which the schema extension is applied.
*
*
* @param directoryId
* The identifier of the directory to which the schema extension is applied.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public SchemaExtensionInfo withDirectoryId(String directoryId) {
setDirectoryId(directoryId);
return this;
}
/**
*
* The identifier of the schema extension.
*
*
* @param schemaExtensionId
* The identifier of the schema extension.
*/
public void setSchemaExtensionId(String schemaExtensionId) {
this.schemaExtensionId = schemaExtensionId;
}
/**
*
* The identifier of the schema extension.
*
*
* @return The identifier of the schema extension.
*/
public String getSchemaExtensionId() {
return this.schemaExtensionId;
}
/**
*
* The identifier of the schema extension.
*
*
* @param schemaExtensionId
* The identifier of the schema extension.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public SchemaExtensionInfo withSchemaExtensionId(String schemaExtensionId) {
setSchemaExtensionId(schemaExtensionId);
return this;
}
/**
*
* A description of the schema extension.
*
*
* @param description
* A description of the schema extension.
*/
public void setDescription(String description) {
this.description = description;
}
/**
*
* A description of the schema extension.
*
*
* @return A description of the schema extension.
*/
public String getDescription() {
return this.description;
}
/**
*
* A description of the schema extension.
*
*
* @param description
* A description of the schema extension.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public SchemaExtensionInfo withDescription(String description) {
setDescription(description);
return this;
}
/**
*
* The current status of the schema extension.
*
*
* @param schemaExtensionStatus
* The current status of the schema extension.
* @see SchemaExtensionStatus
*/
public void setSchemaExtensionStatus(String schemaExtensionStatus) {
this.schemaExtensionStatus = schemaExtensionStatus;
}
/**
*
* The current status of the schema extension.
*
*
* @return The current status of the schema extension.
* @see SchemaExtensionStatus
*/
public String getSchemaExtensionStatus() {
return this.schemaExtensionStatus;
}
/**
*
* The current status of the schema extension.
*
*
* @param schemaExtensionStatus
* The current status of the schema extension.
* @return Returns a reference to this object so that method calls can be chained together.
* @see SchemaExtensionStatus
*/
public SchemaExtensionInfo withSchemaExtensionStatus(String schemaExtensionStatus) {
setSchemaExtensionStatus(schemaExtensionStatus);
return this;
}
/**
*
* The current status of the schema extension.
*
*
* @param schemaExtensionStatus
* The current status of the schema extension.
* @see SchemaExtensionStatus
*/
public void setSchemaExtensionStatus(SchemaExtensionStatus schemaExtensionStatus) {
withSchemaExtensionStatus(schemaExtensionStatus);
}
/**
*
* The current status of the schema extension.
*
*
* @param schemaExtensionStatus
* The current status of the schema extension.
* @return Returns a reference to this object so that method calls can be chained together.
* @see SchemaExtensionStatus
*/
public SchemaExtensionInfo withSchemaExtensionStatus(SchemaExtensionStatus schemaExtensionStatus) {
this.schemaExtensionStatus = schemaExtensionStatus.toString();
return this;
}
/**
*
* The reason for the SchemaExtensionStatus
.
*
*
* @param schemaExtensionStatusReason
* The reason for the SchemaExtensionStatus
.
*/
public void setSchemaExtensionStatusReason(String schemaExtensionStatusReason) {
this.schemaExtensionStatusReason = schemaExtensionStatusReason;
}
/**
*
* The reason for the SchemaExtensionStatus
.
*
*
* @return The reason for the SchemaExtensionStatus
.
*/
public String getSchemaExtensionStatusReason() {
return this.schemaExtensionStatusReason;
}
/**
*
* The reason for the SchemaExtensionStatus
.
*
*
* @param schemaExtensionStatusReason
* The reason for the SchemaExtensionStatus
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public SchemaExtensionInfo withSchemaExtensionStatusReason(String schemaExtensionStatusReason) {
setSchemaExtensionStatusReason(schemaExtensionStatusReason);
return this;
}
/**
*
* The date and time that the schema extension started being applied to the directory.
*
*
* @param startDateTime
* The date and time that the schema extension started being applied to the directory.
*/
public void setStartDateTime(java.util.Date startDateTime) {
this.startDateTime = startDateTime;
}
/**
*
* The date and time that the schema extension started being applied to the directory.
*
*
* @return The date and time that the schema extension started being applied to the directory.
*/
public java.util.Date getStartDateTime() {
return this.startDateTime;
}
/**
*
* The date and time that the schema extension started being applied to the directory.
*
*
* @param startDateTime
* The date and time that the schema extension started being applied to the directory.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public SchemaExtensionInfo withStartDateTime(java.util.Date startDateTime) {
setStartDateTime(startDateTime);
return this;
}
/**
*
* The date and time that the schema extension was completed.
*
*
* @param endDateTime
* The date and time that the schema extension was completed.
*/
public void setEndDateTime(java.util.Date endDateTime) {
this.endDateTime = endDateTime;
}
/**
*
* The date and time that the schema extension was completed.
*
*
* @return The date and time that the schema extension was completed.
*/
public java.util.Date getEndDateTime() {
return this.endDateTime;
}
/**
*
* The date and time that the schema extension was completed.
*
*
* @param endDateTime
* The date and time that the schema extension was completed.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public SchemaExtensionInfo withEndDateTime(java.util.Date endDateTime) {
setEndDateTime(endDateTime);
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 (getDirectoryId() != null)
sb.append("DirectoryId: ").append(getDirectoryId()).append(",");
if (getSchemaExtensionId() != null)
sb.append("SchemaExtensionId: ").append(getSchemaExtensionId()).append(",");
if (getDescription() != null)
sb.append("Description: ").append(getDescription()).append(",");
if (getSchemaExtensionStatus() != null)
sb.append("SchemaExtensionStatus: ").append(getSchemaExtensionStatus()).append(",");
if (getSchemaExtensionStatusReason() != null)
sb.append("SchemaExtensionStatusReason: ").append(getSchemaExtensionStatusReason()).append(",");
if (getStartDateTime() != null)
sb.append("StartDateTime: ").append(getStartDateTime()).append(",");
if (getEndDateTime() != null)
sb.append("EndDateTime: ").append(getEndDateTime());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof SchemaExtensionInfo == false)
return false;
SchemaExtensionInfo other = (SchemaExtensionInfo) obj;
if (other.getDirectoryId() == null ^ this.getDirectoryId() == null)
return false;
if (other.getDirectoryId() != null && other.getDirectoryId().equals(this.getDirectoryId()) == false)
return false;
if (other.getSchemaExtensionId() == null ^ this.getSchemaExtensionId() == null)
return false;
if (other.getSchemaExtensionId() != null && other.getSchemaExtensionId().equals(this.getSchemaExtensionId()) == 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.getSchemaExtensionStatus() == null ^ this.getSchemaExtensionStatus() == null)
return false;
if (other.getSchemaExtensionStatus() != null && other.getSchemaExtensionStatus().equals(this.getSchemaExtensionStatus()) == false)
return false;
if (other.getSchemaExtensionStatusReason() == null ^ this.getSchemaExtensionStatusReason() == null)
return false;
if (other.getSchemaExtensionStatusReason() != null && other.getSchemaExtensionStatusReason().equals(this.getSchemaExtensionStatusReason()) == false)
return false;
if (other.getStartDateTime() == null ^ this.getStartDateTime() == null)
return false;
if (other.getStartDateTime() != null && other.getStartDateTime().equals(this.getStartDateTime()) == false)
return false;
if (other.getEndDateTime() == null ^ this.getEndDateTime() == null)
return false;
if (other.getEndDateTime() != null && other.getEndDateTime().equals(this.getEndDateTime()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getDirectoryId() == null) ? 0 : getDirectoryId().hashCode());
hashCode = prime * hashCode + ((getSchemaExtensionId() == null) ? 0 : getSchemaExtensionId().hashCode());
hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode());
hashCode = prime * hashCode + ((getSchemaExtensionStatus() == null) ? 0 : getSchemaExtensionStatus().hashCode());
hashCode = prime * hashCode + ((getSchemaExtensionStatusReason() == null) ? 0 : getSchemaExtensionStatusReason().hashCode());
hashCode = prime * hashCode + ((getStartDateTime() == null) ? 0 : getStartDateTime().hashCode());
hashCode = prime * hashCode + ((getEndDateTime() == null) ? 0 : getEndDateTime().hashCode());
return hashCode;
}
@Override
public SchemaExtensionInfo clone() {
try {
return (SchemaExtensionInfo) 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.directory.model.transform.SchemaExtensionInfoMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}