/** * 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 GreengrassV2 { namespace Model { /** *

Contains information about a component dependency for a Lambda function * component.

See Also:

AWS * API Reference

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

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline const Aws::String& GetVersionRequirement() const{ return m_versionRequirement; } /** *

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline bool VersionRequirementHasBeenSet() const { return m_versionRequirementHasBeenSet; } /** *

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline void SetVersionRequirement(const Aws::String& value) { m_versionRequirementHasBeenSet = true; m_versionRequirement = value; } /** *

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline void SetVersionRequirement(Aws::String&& value) { m_versionRequirementHasBeenSet = true; m_versionRequirement = std::move(value); } /** *

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline void SetVersionRequirement(const char* value) { m_versionRequirementHasBeenSet = true; m_versionRequirement.assign(value); } /** *

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline ComponentDependencyRequirement& WithVersionRequirement(const Aws::String& value) { SetVersionRequirement(value); return *this;} /** *

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline ComponentDependencyRequirement& WithVersionRequirement(Aws::String&& value) { SetVersionRequirement(std::move(value)); return *this;} /** *

The component version requirement for the component dependency.

IoT * Greengrass V2 uses semantic version constraints. For more information, see Semantic Versioning.

*/ inline ComponentDependencyRequirement& WithVersionRequirement(const char* value) { SetVersionRequirement(value); return *this;} /** *

The type of this dependency. Choose from the following options:

  • *

    SOFT – The component doesn't restart if the dependency changes * state.

  • HARD – The component restarts if the * dependency changes state.

Default: HARD

*/ inline const ComponentDependencyType& GetDependencyType() const{ return m_dependencyType; } /** *

The type of this dependency. Choose from the following options:

  • *

    SOFT – The component doesn't restart if the dependency changes * state.

  • HARD – The component restarts if the * dependency changes state.

Default: HARD

*/ inline bool DependencyTypeHasBeenSet() const { return m_dependencyTypeHasBeenSet; } /** *

The type of this dependency. Choose from the following options:

  • *

    SOFT – The component doesn't restart if the dependency changes * state.

  • HARD – The component restarts if the * dependency changes state.

Default: HARD

*/ inline void SetDependencyType(const ComponentDependencyType& value) { m_dependencyTypeHasBeenSet = true; m_dependencyType = value; } /** *

The type of this dependency. Choose from the following options:

  • *

    SOFT – The component doesn't restart if the dependency changes * state.

  • HARD – The component restarts if the * dependency changes state.

Default: HARD

*/ inline void SetDependencyType(ComponentDependencyType&& value) { m_dependencyTypeHasBeenSet = true; m_dependencyType = std::move(value); } /** *

The type of this dependency. Choose from the following options:

  • *

    SOFT – The component doesn't restart if the dependency changes * state.

  • HARD – The component restarts if the * dependency changes state.

Default: HARD

*/ inline ComponentDependencyRequirement& WithDependencyType(const ComponentDependencyType& value) { SetDependencyType(value); return *this;} /** *

The type of this dependency. Choose from the following options:

  • *

    SOFT – The component doesn't restart if the dependency changes * state.

  • HARD – The component restarts if the * dependency changes state.

Default: HARD

*/ inline ComponentDependencyRequirement& WithDependencyType(ComponentDependencyType&& value) { SetDependencyType(std::move(value)); return *this;} private: Aws::String m_versionRequirement; bool m_versionRequirementHasBeenSet = false; ComponentDependencyType m_dependencyType; bool m_dependencyTypeHasBeenSet = false; }; } // namespace Model } // namespace GreengrassV2 } // namespace Aws