com.amazonaws.services.redshiftserverless.model.RestoreTableFromSnapshotRequest Maven / Gradle / Ivy
Show all versions of aws-java-sdk-redshiftserverless 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.redshiftserverless.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.AmazonWebServiceRequest;
/**
*
* @see AWS API Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class RestoreTableFromSnapshotRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable {
/**
*
* Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names are
* case sensitive. If false, the names are not case sensitive. The default is false.
*
*/
private Boolean activateCaseSensitiveIdentifier;
/**
*
* The namespace of the snapshot to restore from.
*
*/
private String namespaceName;
/**
*
* The name of the table to create from the restore operation.
*
*/
private String newTableName;
/**
*
* The name of the snapshot to restore the table from.
*
*/
private String snapshotName;
/**
*
* The name of the source database that contains the table being restored.
*
*/
private String sourceDatabaseName;
/**
*
* The name of the source schema that contains the table being restored.
*
*/
private String sourceSchemaName;
/**
*
* The name of the source table being restored.
*
*/
private String sourceTableName;
/**
*
* The name of the database to restore the table to.
*
*/
private String targetDatabaseName;
/**
*
* The name of the schema to restore the table to.
*
*/
private String targetSchemaName;
/**
*
* The workgroup to restore the table to.
*
*/
private String workgroupName;
/**
*
* Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names are
* case sensitive. If false, the names are not case sensitive. The default is false.
*
*
* @param activateCaseSensitiveIdentifier
* Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names
* are case sensitive. If false, the names are not case sensitive. The default is false.
*/
public void setActivateCaseSensitiveIdentifier(Boolean activateCaseSensitiveIdentifier) {
this.activateCaseSensitiveIdentifier = activateCaseSensitiveIdentifier;
}
/**
*
* Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names are
* case sensitive. If false, the names are not case sensitive. The default is false.
*
*
* @return Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names
* are case sensitive. If false, the names are not case sensitive. The default is false.
*/
public Boolean getActivateCaseSensitiveIdentifier() {
return this.activateCaseSensitiveIdentifier;
}
/**
*
* Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names are
* case sensitive. If false, the names are not case sensitive. The default is false.
*
*
* @param activateCaseSensitiveIdentifier
* Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names
* are case sensitive. If false, the names are not case sensitive. The default is false.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withActivateCaseSensitiveIdentifier(Boolean activateCaseSensitiveIdentifier) {
setActivateCaseSensitiveIdentifier(activateCaseSensitiveIdentifier);
return this;
}
/**
*
* Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names are
* case sensitive. If false, the names are not case sensitive. The default is false.
*
*
* @return Indicates whether name identifiers for database, schema, and table are case sensitive. If true, the names
* are case sensitive. If false, the names are not case sensitive. The default is false.
*/
public Boolean isActivateCaseSensitiveIdentifier() {
return this.activateCaseSensitiveIdentifier;
}
/**
*
* The namespace of the snapshot to restore from.
*
*
* @param namespaceName
* The namespace of the snapshot to restore from.
*/
public void setNamespaceName(String namespaceName) {
this.namespaceName = namespaceName;
}
/**
*
* The namespace of the snapshot to restore from.
*
*
* @return The namespace of the snapshot to restore from.
*/
public String getNamespaceName() {
return this.namespaceName;
}
/**
*
* The namespace of the snapshot to restore from.
*
*
* @param namespaceName
* The namespace of the snapshot to restore from.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withNamespaceName(String namespaceName) {
setNamespaceName(namespaceName);
return this;
}
/**
*
* The name of the table to create from the restore operation.
*
*
* @param newTableName
* The name of the table to create from the restore operation.
*/
public void setNewTableName(String newTableName) {
this.newTableName = newTableName;
}
/**
*
* The name of the table to create from the restore operation.
*
*
* @return The name of the table to create from the restore operation.
*/
public String getNewTableName() {
return this.newTableName;
}
/**
*
* The name of the table to create from the restore operation.
*
*
* @param newTableName
* The name of the table to create from the restore operation.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withNewTableName(String newTableName) {
setNewTableName(newTableName);
return this;
}
/**
*
* The name of the snapshot to restore the table from.
*
*
* @param snapshotName
* The name of the snapshot to restore the table from.
*/
public void setSnapshotName(String snapshotName) {
this.snapshotName = snapshotName;
}
/**
*
* The name of the snapshot to restore the table from.
*
*
* @return The name of the snapshot to restore the table from.
*/
public String getSnapshotName() {
return this.snapshotName;
}
/**
*
* The name of the snapshot to restore the table from.
*
*
* @param snapshotName
* The name of the snapshot to restore the table from.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withSnapshotName(String snapshotName) {
setSnapshotName(snapshotName);
return this;
}
/**
*
* The name of the source database that contains the table being restored.
*
*
* @param sourceDatabaseName
* The name of the source database that contains the table being restored.
*/
public void setSourceDatabaseName(String sourceDatabaseName) {
this.sourceDatabaseName = sourceDatabaseName;
}
/**
*
* The name of the source database that contains the table being restored.
*
*
* @return The name of the source database that contains the table being restored.
*/
public String getSourceDatabaseName() {
return this.sourceDatabaseName;
}
/**
*
* The name of the source database that contains the table being restored.
*
*
* @param sourceDatabaseName
* The name of the source database that contains the table being restored.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withSourceDatabaseName(String sourceDatabaseName) {
setSourceDatabaseName(sourceDatabaseName);
return this;
}
/**
*
* The name of the source schema that contains the table being restored.
*
*
* @param sourceSchemaName
* The name of the source schema that contains the table being restored.
*/
public void setSourceSchemaName(String sourceSchemaName) {
this.sourceSchemaName = sourceSchemaName;
}
/**
*
* The name of the source schema that contains the table being restored.
*
*
* @return The name of the source schema that contains the table being restored.
*/
public String getSourceSchemaName() {
return this.sourceSchemaName;
}
/**
*
* The name of the source schema that contains the table being restored.
*
*
* @param sourceSchemaName
* The name of the source schema that contains the table being restored.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withSourceSchemaName(String sourceSchemaName) {
setSourceSchemaName(sourceSchemaName);
return this;
}
/**
*
* The name of the source table being restored.
*
*
* @param sourceTableName
* The name of the source table being restored.
*/
public void setSourceTableName(String sourceTableName) {
this.sourceTableName = sourceTableName;
}
/**
*
* The name of the source table being restored.
*
*
* @return The name of the source table being restored.
*/
public String getSourceTableName() {
return this.sourceTableName;
}
/**
*
* The name of the source table being restored.
*
*
* @param sourceTableName
* The name of the source table being restored.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withSourceTableName(String sourceTableName) {
setSourceTableName(sourceTableName);
return this;
}
/**
*
* The name of the database to restore the table to.
*
*
* @param targetDatabaseName
* The name of the database to restore the table to.
*/
public void setTargetDatabaseName(String targetDatabaseName) {
this.targetDatabaseName = targetDatabaseName;
}
/**
*
* The name of the database to restore the table to.
*
*
* @return The name of the database to restore the table to.
*/
public String getTargetDatabaseName() {
return this.targetDatabaseName;
}
/**
*
* The name of the database to restore the table to.
*
*
* @param targetDatabaseName
* The name of the database to restore the table to.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withTargetDatabaseName(String targetDatabaseName) {
setTargetDatabaseName(targetDatabaseName);
return this;
}
/**
*
* The name of the schema to restore the table to.
*
*
* @param targetSchemaName
* The name of the schema to restore the table to.
*/
public void setTargetSchemaName(String targetSchemaName) {
this.targetSchemaName = targetSchemaName;
}
/**
*
* The name of the schema to restore the table to.
*
*
* @return The name of the schema to restore the table to.
*/
public String getTargetSchemaName() {
return this.targetSchemaName;
}
/**
*
* The name of the schema to restore the table to.
*
*
* @param targetSchemaName
* The name of the schema to restore the table to.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withTargetSchemaName(String targetSchemaName) {
setTargetSchemaName(targetSchemaName);
return this;
}
/**
*
* The workgroup to restore the table to.
*
*
* @param workgroupName
* The workgroup to restore the table to.
*/
public void setWorkgroupName(String workgroupName) {
this.workgroupName = workgroupName;
}
/**
*
* The workgroup to restore the table to.
*
*
* @return The workgroup to restore the table to.
*/
public String getWorkgroupName() {
return this.workgroupName;
}
/**
*
* The workgroup to restore the table to.
*
*
* @param workgroupName
* The workgroup to restore the table to.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public RestoreTableFromSnapshotRequest withWorkgroupName(String workgroupName) {
setWorkgroupName(workgroupName);
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 (getActivateCaseSensitiveIdentifier() != null)
sb.append("ActivateCaseSensitiveIdentifier: ").append(getActivateCaseSensitiveIdentifier()).append(",");
if (getNamespaceName() != null)
sb.append("NamespaceName: ").append(getNamespaceName()).append(",");
if (getNewTableName() != null)
sb.append("NewTableName: ").append(getNewTableName()).append(",");
if (getSnapshotName() != null)
sb.append("SnapshotName: ").append(getSnapshotName()).append(",");
if (getSourceDatabaseName() != null)
sb.append("SourceDatabaseName: ").append(getSourceDatabaseName()).append(",");
if (getSourceSchemaName() != null)
sb.append("SourceSchemaName: ").append(getSourceSchemaName()).append(",");
if (getSourceTableName() != null)
sb.append("SourceTableName: ").append(getSourceTableName()).append(",");
if (getTargetDatabaseName() != null)
sb.append("TargetDatabaseName: ").append(getTargetDatabaseName()).append(",");
if (getTargetSchemaName() != null)
sb.append("TargetSchemaName: ").append(getTargetSchemaName()).append(",");
if (getWorkgroupName() != null)
sb.append("WorkgroupName: ").append(getWorkgroupName());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof RestoreTableFromSnapshotRequest == false)
return false;
RestoreTableFromSnapshotRequest other = (RestoreTableFromSnapshotRequest) obj;
if (other.getActivateCaseSensitiveIdentifier() == null ^ this.getActivateCaseSensitiveIdentifier() == null)
return false;
if (other.getActivateCaseSensitiveIdentifier() != null
&& other.getActivateCaseSensitiveIdentifier().equals(this.getActivateCaseSensitiveIdentifier()) == false)
return false;
if (other.getNamespaceName() == null ^ this.getNamespaceName() == null)
return false;
if (other.getNamespaceName() != null && other.getNamespaceName().equals(this.getNamespaceName()) == false)
return false;
if (other.getNewTableName() == null ^ this.getNewTableName() == null)
return false;
if (other.getNewTableName() != null && other.getNewTableName().equals(this.getNewTableName()) == false)
return false;
if (other.getSnapshotName() == null ^ this.getSnapshotName() == null)
return false;
if (other.getSnapshotName() != null && other.getSnapshotName().equals(this.getSnapshotName()) == false)
return false;
if (other.getSourceDatabaseName() == null ^ this.getSourceDatabaseName() == null)
return false;
if (other.getSourceDatabaseName() != null && other.getSourceDatabaseName().equals(this.getSourceDatabaseName()) == false)
return false;
if (other.getSourceSchemaName() == null ^ this.getSourceSchemaName() == null)
return false;
if (other.getSourceSchemaName() != null && other.getSourceSchemaName().equals(this.getSourceSchemaName()) == false)
return false;
if (other.getSourceTableName() == null ^ this.getSourceTableName() == null)
return false;
if (other.getSourceTableName() != null && other.getSourceTableName().equals(this.getSourceTableName()) == false)
return false;
if (other.getTargetDatabaseName() == null ^ this.getTargetDatabaseName() == null)
return false;
if (other.getTargetDatabaseName() != null && other.getTargetDatabaseName().equals(this.getTargetDatabaseName()) == false)
return false;
if (other.getTargetSchemaName() == null ^ this.getTargetSchemaName() == null)
return false;
if (other.getTargetSchemaName() != null && other.getTargetSchemaName().equals(this.getTargetSchemaName()) == false)
return false;
if (other.getWorkgroupName() == null ^ this.getWorkgroupName() == null)
return false;
if (other.getWorkgroupName() != null && other.getWorkgroupName().equals(this.getWorkgroupName()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getActivateCaseSensitiveIdentifier() == null) ? 0 : getActivateCaseSensitiveIdentifier().hashCode());
hashCode = prime * hashCode + ((getNamespaceName() == null) ? 0 : getNamespaceName().hashCode());
hashCode = prime * hashCode + ((getNewTableName() == null) ? 0 : getNewTableName().hashCode());
hashCode = prime * hashCode + ((getSnapshotName() == null) ? 0 : getSnapshotName().hashCode());
hashCode = prime * hashCode + ((getSourceDatabaseName() == null) ? 0 : getSourceDatabaseName().hashCode());
hashCode = prime * hashCode + ((getSourceSchemaName() == null) ? 0 : getSourceSchemaName().hashCode());
hashCode = prime * hashCode + ((getSourceTableName() == null) ? 0 : getSourceTableName().hashCode());
hashCode = prime * hashCode + ((getTargetDatabaseName() == null) ? 0 : getTargetDatabaseName().hashCode());
hashCode = prime * hashCode + ((getTargetSchemaName() == null) ? 0 : getTargetSchemaName().hashCode());
hashCode = prime * hashCode + ((getWorkgroupName() == null) ? 0 : getWorkgroupName().hashCode());
return hashCode;
}
@Override
public RestoreTableFromSnapshotRequest clone() {
return (RestoreTableFromSnapshotRequest) super.clone();
}
}