/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace FSx { namespace Model { /** *

The snapshot configuration to use when creating an OpenZFS volume from a * snapshot.

See Also:

AWS * API Reference

*/ class CreateOpenZFSOriginSnapshotConfiguration { public: AWS_FSX_API CreateOpenZFSOriginSnapshotConfiguration(); AWS_FSX_API CreateOpenZFSOriginSnapshotConfiguration(Aws::Utils::Json::JsonView jsonValue); AWS_FSX_API CreateOpenZFSOriginSnapshotConfiguration& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_FSX_API Aws::Utils::Json::JsonValue Jsonize() const; inline const Aws::String& GetSnapshotARN() const{ return m_snapshotARN; } inline bool SnapshotARNHasBeenSet() const { return m_snapshotARNHasBeenSet; } inline void SetSnapshotARN(const Aws::String& value) { m_snapshotARNHasBeenSet = true; m_snapshotARN = value; } inline void SetSnapshotARN(Aws::String&& value) { m_snapshotARNHasBeenSet = true; m_snapshotARN = std::move(value); } inline void SetSnapshotARN(const char* value) { m_snapshotARNHasBeenSet = true; m_snapshotARN.assign(value); } inline CreateOpenZFSOriginSnapshotConfiguration& WithSnapshotARN(const Aws::String& value) { SetSnapshotARN(value); return *this;} inline CreateOpenZFSOriginSnapshotConfiguration& WithSnapshotARN(Aws::String&& value) { SetSnapshotARN(std::move(value)); return *this;} inline CreateOpenZFSOriginSnapshotConfiguration& WithSnapshotARN(const char* value) { SetSnapshotARN(value); return *this;} /** *

The strategy used when copying data from the snapshot to the new volume.

*
  • CLONE - The new volume references the data in the * origin snapshot. Cloning a snapshot is faster than copying data from the * snapshot to a new volume and doesn't consume disk throughput. However, the * origin snapshot can't be deleted if there is a volume using its copied data. *

  • FULL_COPY - Copies all data from the snapshot * to the new volume.

*/ inline const OpenZFSCopyStrategy& GetCopyStrategy() const{ return m_copyStrategy; } /** *

The strategy used when copying data from the snapshot to the new volume.

*
  • CLONE - The new volume references the data in the * origin snapshot. Cloning a snapshot is faster than copying data from the * snapshot to a new volume and doesn't consume disk throughput. However, the * origin snapshot can't be deleted if there is a volume using its copied data. *

  • FULL_COPY - Copies all data from the snapshot * to the new volume.

*/ inline bool CopyStrategyHasBeenSet() const { return m_copyStrategyHasBeenSet; } /** *

The strategy used when copying data from the snapshot to the new volume.

*
  • CLONE - The new volume references the data in the * origin snapshot. Cloning a snapshot is faster than copying data from the * snapshot to a new volume and doesn't consume disk throughput. However, the * origin snapshot can't be deleted if there is a volume using its copied data. *

  • FULL_COPY - Copies all data from the snapshot * to the new volume.

*/ inline void SetCopyStrategy(const OpenZFSCopyStrategy& value) { m_copyStrategyHasBeenSet = true; m_copyStrategy = value; } /** *

The strategy used when copying data from the snapshot to the new volume.

*
  • CLONE - The new volume references the data in the * origin snapshot. Cloning a snapshot is faster than copying data from the * snapshot to a new volume and doesn't consume disk throughput. However, the * origin snapshot can't be deleted if there is a volume using its copied data. *

  • FULL_COPY - Copies all data from the snapshot * to the new volume.

*/ inline void SetCopyStrategy(OpenZFSCopyStrategy&& value) { m_copyStrategyHasBeenSet = true; m_copyStrategy = std::move(value); } /** *

The strategy used when copying data from the snapshot to the new volume.

*
  • CLONE - The new volume references the data in the * origin snapshot. Cloning a snapshot is faster than copying data from the * snapshot to a new volume and doesn't consume disk throughput. However, the * origin snapshot can't be deleted if there is a volume using its copied data. *

  • FULL_COPY - Copies all data from the snapshot * to the new volume.

*/ inline CreateOpenZFSOriginSnapshotConfiguration& WithCopyStrategy(const OpenZFSCopyStrategy& value) { SetCopyStrategy(value); return *this;} /** *

The strategy used when copying data from the snapshot to the new volume.

*
  • CLONE - The new volume references the data in the * origin snapshot. Cloning a snapshot is faster than copying data from the * snapshot to a new volume and doesn't consume disk throughput. However, the * origin snapshot can't be deleted if there is a volume using its copied data. *

  • FULL_COPY - Copies all data from the snapshot * to the new volume.

*/ inline CreateOpenZFSOriginSnapshotConfiguration& WithCopyStrategy(OpenZFSCopyStrategy&& value) { SetCopyStrategy(std::move(value)); return *this;} private: Aws::String m_snapshotARN; bool m_snapshotARNHasBeenSet = false; OpenZFSCopyStrategy m_copyStrategy; bool m_copyStrategyHasBeenSet = false; }; } // namespace Model } // namespace FSx } // namespace Aws