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

com.amazonaws.services.lightsail.model.AutoSnapshotAddOnRequest Maven / Gradle / Ivy

/*
 * Copyright 2018-2023 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.lightsail.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Describes a request to enable or modify the automatic snapshot add-on for an Amazon Lightsail instance or disk. *

*

* When you modify the automatic snapshot time for a resource, it is typically effective immediately except under the * following conditions: *

*
    *
  • *

    * If an automatic snapshot has been created for the current day, and you change the snapshot time to a later time of * day, then the new snapshot time will be effective the following day. This ensures that two snapshots are not created * for the current day. *

    *
  • *
  • *

    * If an automatic snapshot has not yet been created for the current day, and you change the snapshot time to an earlier * time of day, then the new snapshot time will be effective the following day and a snapshot is automatically created * at the previously set time for the current day. This ensures that a snapshot is created for the current day. *

    *
  • *
  • *

    * If an automatic snapshot has not yet been created for the current day, and you change the snapshot time to a time * that is within 30 minutes from your current time, then the new snapshot time will be effective the following day and * a snapshot is automatically created at the previously set time for the current day. This ensures that a snapshot is * created for the current day, because 30 minutes is required between your current time and the new snapshot time that * you specify. *

    *
  • *
  • *

    * If an automatic snapshot is scheduled to be created within 30 minutes from your current time and you change the * snapshot time, then the new snapshot time will be effective the following day and a snapshot is automatically created * at the previously set time for the current day. This ensures that a snapshot is created for the current day, because * 30 minutes is required between your current time and the new snapshot time that you specify. *

    *
  • *
* * @see AWS * API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class AutoSnapshotAddOnRequest implements Serializable, Cloneable, StructuredPojo { /** *

* The daily time when an automatic snapshot will be created. *

*

* Constraints: *

*
    *
  • *

    * Must be in HH:00 format, and in an hourly increment. *

    *
  • *
  • *

    * Specified in Coordinated Universal Time (UTC). *

    *
  • *
  • *

    * The snapshot will be automatically created between the time specified and up to 45 minutes after. *

    *
  • *
*/ private String snapshotTimeOfDay; /** *

* The daily time when an automatic snapshot will be created. *

*

* Constraints: *

*
    *
  • *

    * Must be in HH:00 format, and in an hourly increment. *

    *
  • *
  • *

    * Specified in Coordinated Universal Time (UTC). *

    *
  • *
  • *

    * The snapshot will be automatically created between the time specified and up to 45 minutes after. *

    *
  • *
* * @param snapshotTimeOfDay * The daily time when an automatic snapshot will be created.

*

* Constraints: *

*
    *
  • *

    * Must be in HH:00 format, and in an hourly increment. *

    *
  • *
  • *

    * Specified in Coordinated Universal Time (UTC). *

    *
  • *
  • *

    * The snapshot will be automatically created between the time specified and up to 45 minutes after. *

    *
  • */ public void setSnapshotTimeOfDay(String snapshotTimeOfDay) { this.snapshotTimeOfDay = snapshotTimeOfDay; } /** *

    * The daily time when an automatic snapshot will be created. *

    *

    * Constraints: *

    *
      *
    • *

      * Must be in HH:00 format, and in an hourly increment. *

      *
    • *
    • *

      * Specified in Coordinated Universal Time (UTC). *

      *
    • *
    • *

      * The snapshot will be automatically created between the time specified and up to 45 minutes after. *

      *
    • *
    * * @return The daily time when an automatic snapshot will be created.

    *

    * Constraints: *

    *
      *
    • *

      * Must be in HH:00 format, and in an hourly increment. *

      *
    • *
    • *

      * Specified in Coordinated Universal Time (UTC). *

      *
    • *
    • *

      * The snapshot will be automatically created between the time specified and up to 45 minutes after. *

      *
    • */ public String getSnapshotTimeOfDay() { return this.snapshotTimeOfDay; } /** *

      * The daily time when an automatic snapshot will be created. *

      *

      * Constraints: *

      *
        *
      • *

        * Must be in HH:00 format, and in an hourly increment. *

        *
      • *
      • *

        * Specified in Coordinated Universal Time (UTC). *

        *
      • *
      • *

        * The snapshot will be automatically created between the time specified and up to 45 minutes after. *

        *
      • *
      * * @param snapshotTimeOfDay * The daily time when an automatic snapshot will be created.

      *

      * Constraints: *

      *
        *
      • *

        * Must be in HH:00 format, and in an hourly increment. *

        *
      • *
      • *

        * Specified in Coordinated Universal Time (UTC). *

        *
      • *
      • *

        * The snapshot will be automatically created between the time specified and up to 45 minutes after. *

        *
      • * @return Returns a reference to this object so that method calls can be chained together. */ public AutoSnapshotAddOnRequest withSnapshotTimeOfDay(String snapshotTimeOfDay) { setSnapshotTimeOfDay(snapshotTimeOfDay); 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 (getSnapshotTimeOfDay() != null) sb.append("SnapshotTimeOfDay: ").append(getSnapshotTimeOfDay()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof AutoSnapshotAddOnRequest == false) return false; AutoSnapshotAddOnRequest other = (AutoSnapshotAddOnRequest) obj; if (other.getSnapshotTimeOfDay() == null ^ this.getSnapshotTimeOfDay() == null) return false; if (other.getSnapshotTimeOfDay() != null && other.getSnapshotTimeOfDay().equals(this.getSnapshotTimeOfDay()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getSnapshotTimeOfDay() == null) ? 0 : getSnapshotTimeOfDay().hashCode()); return hashCode; } @Override public AutoSnapshotAddOnRequest clone() { try { return (AutoSnapshotAddOnRequest) 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.lightsail.model.transform.AutoSnapshotAddOnRequestMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy