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

Sets the autocommit period of files in an FSx for ONTAP SnapLock volume, * which determines how long the files must remain unmodified before they're * automatically transitioned to the write once, read many (WORM) state.

*

For more information, see Autocommit. *

See Also:

AWS * API Reference

*/ class AutocommitPeriod { public: AWS_FSX_API AutocommitPeriod(); AWS_FSX_API AutocommitPeriod(Aws::Utils::Json::JsonView jsonValue); AWS_FSX_API AutocommitPeriod& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_FSX_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

Defines the type of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. Setting this value to NONE disables * autocommit. The default value is NONE.

*/ inline const AutocommitPeriodType& GetType() const{ return m_type; } /** *

Defines the type of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. Setting this value to NONE disables * autocommit. The default value is NONE.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

Defines the type of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. Setting this value to NONE disables * autocommit. The default value is NONE.

*/ inline void SetType(const AutocommitPeriodType& value) { m_typeHasBeenSet = true; m_type = value; } /** *

Defines the type of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. Setting this value to NONE disables * autocommit. The default value is NONE.

*/ inline void SetType(AutocommitPeriodType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

Defines the type of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. Setting this value to NONE disables * autocommit. The default value is NONE.

*/ inline AutocommitPeriod& WithType(const AutocommitPeriodType& value) { SetType(value); return *this;} /** *

Defines the type of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. Setting this value to NONE disables * autocommit. The default value is NONE.

*/ inline AutocommitPeriod& WithType(AutocommitPeriodType&& value) { SetType(std::move(value)); return *this;} /** *

Defines the amount of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. The following ranges are valid:

  • * Minutes: 5 - 65,535

  • Hours: 1 - * 65,535

  • Days: 1 - 3,650

  • * Months: 1 - 120

  • Years: 1 - 10

    *
*/ inline int GetValue() const{ return m_value; } /** *

Defines the amount of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. The following ranges are valid:

  • * Minutes: 5 - 65,535

  • Hours: 1 - * 65,535

  • Days: 1 - 3,650

  • * Months: 1 - 120

  • Years: 1 - 10

    *
*/ inline bool ValueHasBeenSet() const { return m_valueHasBeenSet; } /** *

Defines the amount of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. The following ranges are valid:

  • * Minutes: 5 - 65,535

  • Hours: 1 - * 65,535

  • Days: 1 - 3,650

  • * Months: 1 - 120

  • Years: 1 - 10

    *
*/ inline void SetValue(int value) { m_valueHasBeenSet = true; m_value = value; } /** *

Defines the amount of time for the autocommit period of a file in an FSx for * ONTAP SnapLock volume. The following ranges are valid:

  • * Minutes: 5 - 65,535

  • Hours: 1 - * 65,535

  • Days: 1 - 3,650

  • * Months: 1 - 120

  • Years: 1 - 10

    *
*/ inline AutocommitPeriod& WithValue(int value) { SetValue(value); return *this;} private: AutocommitPeriodType m_type; bool m_typeHasBeenSet = false; int m_value; bool m_valueHasBeenSet = false; }; } // namespace Model } // namespace FSx } // namespace Aws