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

com.amazonaws.services.redshift.model.ModifyClusterSnapshotRequest Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Amazon Redshift module holds the client classes that are used for communicating with Amazon Redshift Service

The newest version!
/*
 * 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.redshift.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 ModifyClusterSnapshotRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable {

    /**
     * 

* The identifier of the snapshot whose setting you want to modify. *

*/ private String snapshotIdentifier; /** *

* The number of days that a manual snapshot is retained. If the value is -1, the manual snapshot is retained * indefinitely. *

*

* If the manual snapshot falls outside of the new retention period, you can specify the force option to immediately * delete the snapshot. *

*

* The value must be either -1 or an integer between 1 and 3,653. *

*/ private Integer manualSnapshotRetentionPeriod; /** *

* A Boolean option to override an exception if the retention period has already passed. *

*/ private Boolean force; /** *

* The identifier of the snapshot whose setting you want to modify. *

* * @param snapshotIdentifier * The identifier of the snapshot whose setting you want to modify. */ public void setSnapshotIdentifier(String snapshotIdentifier) { this.snapshotIdentifier = snapshotIdentifier; } /** *

* The identifier of the snapshot whose setting you want to modify. *

* * @return The identifier of the snapshot whose setting you want to modify. */ public String getSnapshotIdentifier() { return this.snapshotIdentifier; } /** *

* The identifier of the snapshot whose setting you want to modify. *

* * @param snapshotIdentifier * The identifier of the snapshot whose setting you want to modify. * @return Returns a reference to this object so that method calls can be chained together. */ public ModifyClusterSnapshotRequest withSnapshotIdentifier(String snapshotIdentifier) { setSnapshotIdentifier(snapshotIdentifier); return this; } /** *

* The number of days that a manual snapshot is retained. If the value is -1, the manual snapshot is retained * indefinitely. *

*

* If the manual snapshot falls outside of the new retention period, you can specify the force option to immediately * delete the snapshot. *

*

* The value must be either -1 or an integer between 1 and 3,653. *

* * @param manualSnapshotRetentionPeriod * The number of days that a manual snapshot is retained. If the value is -1, the manual snapshot is retained * indefinitely.

*

* If the manual snapshot falls outside of the new retention period, you can specify the force option to * immediately delete the snapshot. *

*

* The value must be either -1 or an integer between 1 and 3,653. */ public void setManualSnapshotRetentionPeriod(Integer manualSnapshotRetentionPeriod) { this.manualSnapshotRetentionPeriod = manualSnapshotRetentionPeriod; } /** *

* The number of days that a manual snapshot is retained. If the value is -1, the manual snapshot is retained * indefinitely. *

*

* If the manual snapshot falls outside of the new retention period, you can specify the force option to immediately * delete the snapshot. *

*

* The value must be either -1 or an integer between 1 and 3,653. *

* * @return The number of days that a manual snapshot is retained. If the value is -1, the manual snapshot is * retained indefinitely.

*

* If the manual snapshot falls outside of the new retention period, you can specify the force option to * immediately delete the snapshot. *

*

* The value must be either -1 or an integer between 1 and 3,653. */ public Integer getManualSnapshotRetentionPeriod() { return this.manualSnapshotRetentionPeriod; } /** *

* The number of days that a manual snapshot is retained. If the value is -1, the manual snapshot is retained * indefinitely. *

*

* If the manual snapshot falls outside of the new retention period, you can specify the force option to immediately * delete the snapshot. *

*

* The value must be either -1 or an integer between 1 and 3,653. *

* * @param manualSnapshotRetentionPeriod * The number of days that a manual snapshot is retained. If the value is -1, the manual snapshot is retained * indefinitely.

*

* If the manual snapshot falls outside of the new retention period, you can specify the force option to * immediately delete the snapshot. *

*

* The value must be either -1 or an integer between 1 and 3,653. * @return Returns a reference to this object so that method calls can be chained together. */ public ModifyClusterSnapshotRequest withManualSnapshotRetentionPeriod(Integer manualSnapshotRetentionPeriod) { setManualSnapshotRetentionPeriod(manualSnapshotRetentionPeriod); return this; } /** *

* A Boolean option to override an exception if the retention period has already passed. *

* * @param force * A Boolean option to override an exception if the retention period has already passed. */ public void setForce(Boolean force) { this.force = force; } /** *

* A Boolean option to override an exception if the retention period has already passed. *

* * @return A Boolean option to override an exception if the retention period has already passed. */ public Boolean getForce() { return this.force; } /** *

* A Boolean option to override an exception if the retention period has already passed. *

* * @param force * A Boolean option to override an exception if the retention period has already passed. * @return Returns a reference to this object so that method calls can be chained together. */ public ModifyClusterSnapshotRequest withForce(Boolean force) { setForce(force); return this; } /** *

* A Boolean option to override an exception if the retention period has already passed. *

* * @return A Boolean option to override an exception if the retention period has already passed. */ public Boolean isForce() { return this.force; } /** * 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 (getSnapshotIdentifier() != null) sb.append("SnapshotIdentifier: ").append(getSnapshotIdentifier()).append(","); if (getManualSnapshotRetentionPeriod() != null) sb.append("ManualSnapshotRetentionPeriod: ").append(getManualSnapshotRetentionPeriod()).append(","); if (getForce() != null) sb.append("Force: ").append(getForce()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof ModifyClusterSnapshotRequest == false) return false; ModifyClusterSnapshotRequest other = (ModifyClusterSnapshotRequest) obj; if (other.getSnapshotIdentifier() == null ^ this.getSnapshotIdentifier() == null) return false; if (other.getSnapshotIdentifier() != null && other.getSnapshotIdentifier().equals(this.getSnapshotIdentifier()) == false) return false; if (other.getManualSnapshotRetentionPeriod() == null ^ this.getManualSnapshotRetentionPeriod() == null) return false; if (other.getManualSnapshotRetentionPeriod() != null && other.getManualSnapshotRetentionPeriod().equals(this.getManualSnapshotRetentionPeriod()) == false) return false; if (other.getForce() == null ^ this.getForce() == null) return false; if (other.getForce() != null && other.getForce().equals(this.getForce()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getSnapshotIdentifier() == null) ? 0 : getSnapshotIdentifier().hashCode()); hashCode = prime * hashCode + ((getManualSnapshotRetentionPeriod() == null) ? 0 : getManualSnapshotRetentionPeriod().hashCode()); hashCode = prime * hashCode + ((getForce() == null) ? 0 : getForce().hashCode()); return hashCode; } @Override public ModifyClusterSnapshotRequest clone() { return (ModifyClusterSnapshotRequest) super.clone(); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy