/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include [Snapshot policies only] Describes the retention rule for archived
* snapshots. Once the archive retention threshold is met, the snapshots are
* permanently deleted from the archive tier. The archive retention
* rule must retain snapshots in the archive tier for a minimum of 90 days. For count-based schedules, you must specify Count. For
* age-based schedules, you must specify Interval and
* IntervalUnit. For more information about using snapshot archiving,
* see Considerations
* for snapshot lifecycle policies.See Also:
AWS
* API Reference
The maximum number of snapshots to retain in the archive storage tier for * each volume. The count must ensure that each snapshot remains in the archive * tier for at least 90 days. For example, if the schedule creates snapshots every * 30 days, you must specify a count of 3 or more to ensure that each snapshot is * archived for at least 90 days.
*/ inline int GetCount() const{ return m_count; } /** *The maximum number of snapshots to retain in the archive storage tier for * each volume. The count must ensure that each snapshot remains in the archive * tier for at least 90 days. For example, if the schedule creates snapshots every * 30 days, you must specify a count of 3 or more to ensure that each snapshot is * archived for at least 90 days.
*/ inline bool CountHasBeenSet() const { return m_countHasBeenSet; } /** *The maximum number of snapshots to retain in the archive storage tier for * each volume. The count must ensure that each snapshot remains in the archive * tier for at least 90 days. For example, if the schedule creates snapshots every * 30 days, you must specify a count of 3 or more to ensure that each snapshot is * archived for at least 90 days.
*/ inline void SetCount(int value) { m_countHasBeenSet = true; m_count = value; } /** *The maximum number of snapshots to retain in the archive storage tier for * each volume. The count must ensure that each snapshot remains in the archive * tier for at least 90 days. For example, if the schedule creates snapshots every * 30 days, you must specify a count of 3 or more to ensure that each snapshot is * archived for at least 90 days.
*/ inline RetentionArchiveTier& WithCount(int value) { SetCount(value); return *this;} /** *Specifies the period of time to retain snapshots in the archive tier. After * this period expires, the snapshot is permanently deleted.
*/ inline int GetInterval() const{ return m_interval; } /** *Specifies the period of time to retain snapshots in the archive tier. After * this period expires, the snapshot is permanently deleted.
*/ inline bool IntervalHasBeenSet() const { return m_intervalHasBeenSet; } /** *Specifies the period of time to retain snapshots in the archive tier. After * this period expires, the snapshot is permanently deleted.
*/ inline void SetInterval(int value) { m_intervalHasBeenSet = true; m_interval = value; } /** *Specifies the period of time to retain snapshots in the archive tier. After * this period expires, the snapshot is permanently deleted.
*/ inline RetentionArchiveTier& WithInterval(int value) { SetInterval(value); return *this;} /** *The unit of time in which to measure the Interval. For example, to
* retain a snapshots in the archive tier for 6 months, specify
* Interval=6
and IntervalUnit=MONTHS
.
The unit of time in which to measure the Interval. For example, to
* retain a snapshots in the archive tier for 6 months, specify
* Interval=6
and IntervalUnit=MONTHS
.
The unit of time in which to measure the Interval. For example, to
* retain a snapshots in the archive tier for 6 months, specify
* Interval=6
and IntervalUnit=MONTHS
.
The unit of time in which to measure the Interval. For example, to
* retain a snapshots in the archive tier for 6 months, specify
* Interval=6
and IntervalUnit=MONTHS
.
The unit of time in which to measure the Interval. For example, to
* retain a snapshots in the archive tier for 6 months, specify
* Interval=6
and IntervalUnit=MONTHS
.
The unit of time in which to measure the Interval. For example, to
* retain a snapshots in the archive tier for 6 months, specify
* Interval=6
and IntervalUnit=MONTHS
.