/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include #include namespace Aws { namespace Http { class URI; } //namespace Http namespace IoT { namespace Model { /** */ class UpdateSecurityProfileRequest : public IoTRequest { public: AWS_IOT_API UpdateSecurityProfileRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "UpdateSecurityProfile"; } AWS_IOT_API Aws::String SerializePayload() const override; AWS_IOT_API void AddQueryStringParameters(Aws::Http::URI& uri) const override; /** *

The name of the security profile you want to update.

*/ inline const Aws::String& GetSecurityProfileName() const{ return m_securityProfileName; } /** *

The name of the security profile you want to update.

*/ inline bool SecurityProfileNameHasBeenSet() const { return m_securityProfileNameHasBeenSet; } /** *

The name of the security profile you want to update.

*/ inline void SetSecurityProfileName(const Aws::String& value) { m_securityProfileNameHasBeenSet = true; m_securityProfileName = value; } /** *

The name of the security profile you want to update.

*/ inline void SetSecurityProfileName(Aws::String&& value) { m_securityProfileNameHasBeenSet = true; m_securityProfileName = std::move(value); } /** *

The name of the security profile you want to update.

*/ inline void SetSecurityProfileName(const char* value) { m_securityProfileNameHasBeenSet = true; m_securityProfileName.assign(value); } /** *

The name of the security profile you want to update.

*/ inline UpdateSecurityProfileRequest& WithSecurityProfileName(const Aws::String& value) { SetSecurityProfileName(value); return *this;} /** *

The name of the security profile you want to update.

*/ inline UpdateSecurityProfileRequest& WithSecurityProfileName(Aws::String&& value) { SetSecurityProfileName(std::move(value)); return *this;} /** *

The name of the security profile you want to update.

*/ inline UpdateSecurityProfileRequest& WithSecurityProfileName(const char* value) { SetSecurityProfileName(value); return *this;} /** *

A description of the security profile.

*/ inline const Aws::String& GetSecurityProfileDescription() const{ return m_securityProfileDescription; } /** *

A description of the security profile.

*/ inline bool SecurityProfileDescriptionHasBeenSet() const { return m_securityProfileDescriptionHasBeenSet; } /** *

A description of the security profile.

*/ inline void SetSecurityProfileDescription(const Aws::String& value) { m_securityProfileDescriptionHasBeenSet = true; m_securityProfileDescription = value; } /** *

A description of the security profile.

*/ inline void SetSecurityProfileDescription(Aws::String&& value) { m_securityProfileDescriptionHasBeenSet = true; m_securityProfileDescription = std::move(value); } /** *

A description of the security profile.

*/ inline void SetSecurityProfileDescription(const char* value) { m_securityProfileDescriptionHasBeenSet = true; m_securityProfileDescription.assign(value); } /** *

A description of the security profile.

*/ inline UpdateSecurityProfileRequest& WithSecurityProfileDescription(const Aws::String& value) { SetSecurityProfileDescription(value); return *this;} /** *

A description of the security profile.

*/ inline UpdateSecurityProfileRequest& WithSecurityProfileDescription(Aws::String&& value) { SetSecurityProfileDescription(std::move(value)); return *this;} /** *

A description of the security profile.

*/ inline UpdateSecurityProfileRequest& WithSecurityProfileDescription(const char* value) { SetSecurityProfileDescription(value); return *this;} /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline const Aws::Vector& GetBehaviors() const{ return m_behaviors; } /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline bool BehaviorsHasBeenSet() const { return m_behaviorsHasBeenSet; } /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline void SetBehaviors(const Aws::Vector& value) { m_behaviorsHasBeenSet = true; m_behaviors = value; } /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline void SetBehaviors(Aws::Vector&& value) { m_behaviorsHasBeenSet = true; m_behaviors = std::move(value); } /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline UpdateSecurityProfileRequest& WithBehaviors(const Aws::Vector& value) { SetBehaviors(value); return *this;} /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline UpdateSecurityProfileRequest& WithBehaviors(Aws::Vector&& value) { SetBehaviors(std::move(value)); return *this;} /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline UpdateSecurityProfileRequest& AddBehaviors(const Behavior& value) { m_behaviorsHasBeenSet = true; m_behaviors.push_back(value); return *this; } /** *

Specifies the behaviors that, when violated by a device (thing), cause an * alert.

*/ inline UpdateSecurityProfileRequest& AddBehaviors(Behavior&& value) { m_behaviorsHasBeenSet = true; m_behaviors.push_back(std::move(value)); return *this; } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline const Aws::Map& GetAlertTargets() const{ return m_alertTargets; } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline bool AlertTargetsHasBeenSet() const { return m_alertTargetsHasBeenSet; } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline void SetAlertTargets(const Aws::Map& value) { m_alertTargetsHasBeenSet = true; m_alertTargets = value; } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline void SetAlertTargets(Aws::Map&& value) { m_alertTargetsHasBeenSet = true; m_alertTargets = std::move(value); } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline UpdateSecurityProfileRequest& WithAlertTargets(const Aws::Map& value) { SetAlertTargets(value); return *this;} /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline UpdateSecurityProfileRequest& WithAlertTargets(Aws::Map&& value) { SetAlertTargets(std::move(value)); return *this;} /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline UpdateSecurityProfileRequest& AddAlertTargets(const AlertTargetType& key, const AlertTarget& value) { m_alertTargetsHasBeenSet = true; m_alertTargets.emplace(key, value); return *this; } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline UpdateSecurityProfileRequest& AddAlertTargets(AlertTargetType&& key, const AlertTarget& value) { m_alertTargetsHasBeenSet = true; m_alertTargets.emplace(std::move(key), value); return *this; } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline UpdateSecurityProfileRequest& AddAlertTargets(const AlertTargetType& key, AlertTarget&& value) { m_alertTargetsHasBeenSet = true; m_alertTargets.emplace(key, std::move(value)); return *this; } /** *

Where the alerts are sent. (Alerts are always sent to the console.)

*/ inline UpdateSecurityProfileRequest& AddAlertTargets(AlertTargetType&& key, AlertTarget&& value) { m_alertTargetsHasBeenSet = true; m_alertTargets.emplace(std::move(key), std::move(value)); return *this; } /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline const Aws::Vector& GetAdditionalMetricsToRetainV2() const{ return m_additionalMetricsToRetainV2; } /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline bool AdditionalMetricsToRetainV2HasBeenSet() const { return m_additionalMetricsToRetainV2HasBeenSet; } /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline void SetAdditionalMetricsToRetainV2(const Aws::Vector& value) { m_additionalMetricsToRetainV2HasBeenSet = true; m_additionalMetricsToRetainV2 = value; } /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline void SetAdditionalMetricsToRetainV2(Aws::Vector&& value) { m_additionalMetricsToRetainV2HasBeenSet = true; m_additionalMetricsToRetainV2 = std::move(value); } /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline UpdateSecurityProfileRequest& WithAdditionalMetricsToRetainV2(const Aws::Vector& value) { SetAdditionalMetricsToRetainV2(value); return *this;} /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline UpdateSecurityProfileRequest& WithAdditionalMetricsToRetainV2(Aws::Vector&& value) { SetAdditionalMetricsToRetainV2(std::move(value)); return *this;} /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline UpdateSecurityProfileRequest& AddAdditionalMetricsToRetainV2(const MetricToRetain& value) { m_additionalMetricsToRetainV2HasBeenSet = true; m_additionalMetricsToRetainV2.push_back(value); return *this; } /** *

A list of metrics whose data is retained (stored). By default, data is * retained for any metric used in the profile's behaviors, but it is also retained * for any metric specified here. Can be used with custom metrics; cannot be used * with dimensions.

*/ inline UpdateSecurityProfileRequest& AddAdditionalMetricsToRetainV2(MetricToRetain&& value) { m_additionalMetricsToRetainV2HasBeenSet = true; m_additionalMetricsToRetainV2.push_back(std::move(value)); return *this; } /** *

If true, delete all behaviors defined for this security profile. * If any behaviors are defined in the current invocation, an * exception occurs.

*/ inline bool GetDeleteBehaviors() const{ return m_deleteBehaviors; } /** *

If true, delete all behaviors defined for this security profile. * If any behaviors are defined in the current invocation, an * exception occurs.

*/ inline bool DeleteBehaviorsHasBeenSet() const { return m_deleteBehaviorsHasBeenSet; } /** *

If true, delete all behaviors defined for this security profile. * If any behaviors are defined in the current invocation, an * exception occurs.

*/ inline void SetDeleteBehaviors(bool value) { m_deleteBehaviorsHasBeenSet = true; m_deleteBehaviors = value; } /** *

If true, delete all behaviors defined for this security profile. * If any behaviors are defined in the current invocation, an * exception occurs.

*/ inline UpdateSecurityProfileRequest& WithDeleteBehaviors(bool value) { SetDeleteBehaviors(value); return *this;} /** *

If true, delete all alertTargets defined for this security * profile. If any alertTargets are defined in the current invocation, * an exception occurs.

*/ inline bool GetDeleteAlertTargets() const{ return m_deleteAlertTargets; } /** *

If true, delete all alertTargets defined for this security * profile. If any alertTargets are defined in the current invocation, * an exception occurs.

*/ inline bool DeleteAlertTargetsHasBeenSet() const { return m_deleteAlertTargetsHasBeenSet; } /** *

If true, delete all alertTargets defined for this security * profile. If any alertTargets are defined in the current invocation, * an exception occurs.

*/ inline void SetDeleteAlertTargets(bool value) { m_deleteAlertTargetsHasBeenSet = true; m_deleteAlertTargets = value; } /** *

If true, delete all alertTargets defined for this security * profile. If any alertTargets are defined in the current invocation, * an exception occurs.

*/ inline UpdateSecurityProfileRequest& WithDeleteAlertTargets(bool value) { SetDeleteAlertTargets(value); return *this;} /** *

If true, delete all additionalMetricsToRetain defined for this * security profile. If any additionalMetricsToRetain are defined in * the current invocation, an exception occurs.

*/ inline bool GetDeleteAdditionalMetricsToRetain() const{ return m_deleteAdditionalMetricsToRetain; } /** *

If true, delete all additionalMetricsToRetain defined for this * security profile. If any additionalMetricsToRetain are defined in * the current invocation, an exception occurs.

*/ inline bool DeleteAdditionalMetricsToRetainHasBeenSet() const { return m_deleteAdditionalMetricsToRetainHasBeenSet; } /** *

If true, delete all additionalMetricsToRetain defined for this * security profile. If any additionalMetricsToRetain are defined in * the current invocation, an exception occurs.

*/ inline void SetDeleteAdditionalMetricsToRetain(bool value) { m_deleteAdditionalMetricsToRetainHasBeenSet = true; m_deleteAdditionalMetricsToRetain = value; } /** *

If true, delete all additionalMetricsToRetain defined for this * security profile. If any additionalMetricsToRetain are defined in * the current invocation, an exception occurs.

*/ inline UpdateSecurityProfileRequest& WithDeleteAdditionalMetricsToRetain(bool value) { SetDeleteAdditionalMetricsToRetain(value); return *this;} /** *

The expected version of the security profile. A new version is generated * whenever the security profile is updated. If you specify a value that is * different from the actual version, a VersionConflictException is * thrown.

*/ inline long long GetExpectedVersion() const{ return m_expectedVersion; } /** *

The expected version of the security profile. A new version is generated * whenever the security profile is updated. If you specify a value that is * different from the actual version, a VersionConflictException is * thrown.

*/ inline bool ExpectedVersionHasBeenSet() const { return m_expectedVersionHasBeenSet; } /** *

The expected version of the security profile. A new version is generated * whenever the security profile is updated. If you specify a value that is * different from the actual version, a VersionConflictException is * thrown.

*/ inline void SetExpectedVersion(long long value) { m_expectedVersionHasBeenSet = true; m_expectedVersion = value; } /** *

The expected version of the security profile. A new version is generated * whenever the security profile is updated. If you specify a value that is * different from the actual version, a VersionConflictException is * thrown.

*/ inline UpdateSecurityProfileRequest& WithExpectedVersion(long long value) { SetExpectedVersion(value); return *this;} private: Aws::String m_securityProfileName; bool m_securityProfileNameHasBeenSet = false; Aws::String m_securityProfileDescription; bool m_securityProfileDescriptionHasBeenSet = false; Aws::Vector m_behaviors; bool m_behaviorsHasBeenSet = false; Aws::Map m_alertTargets; bool m_alertTargetsHasBeenSet = false; Aws::Vector m_additionalMetricsToRetainV2; bool m_additionalMetricsToRetainV2HasBeenSet = false; bool m_deleteBehaviors; bool m_deleteBehaviorsHasBeenSet = false; bool m_deleteAlertTargets; bool m_deleteAlertTargetsHasBeenSet = false; bool m_deleteAdditionalMetricsToRetain; bool m_deleteAdditionalMetricsToRetainHasBeenSet = false; long long m_expectedVersion; bool m_expectedVersionHasBeenSet = false; }; } // namespace Model } // namespace IoT } // namespace Aws