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

A rule for redirecting requests to the website.

See Also:

AWS * API Reference

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

Provides the condition that must be met in order to apply the routing * rule.

*/ inline const AwsS3BucketWebsiteConfigurationRoutingRuleCondition& GetCondition() const{ return m_condition; } /** *

Provides the condition that must be met in order to apply the routing * rule.

*/ inline bool ConditionHasBeenSet() const { return m_conditionHasBeenSet; } /** *

Provides the condition that must be met in order to apply the routing * rule.

*/ inline void SetCondition(const AwsS3BucketWebsiteConfigurationRoutingRuleCondition& value) { m_conditionHasBeenSet = true; m_condition = value; } /** *

Provides the condition that must be met in order to apply the routing * rule.

*/ inline void SetCondition(AwsS3BucketWebsiteConfigurationRoutingRuleCondition&& value) { m_conditionHasBeenSet = true; m_condition = std::move(value); } /** *

Provides the condition that must be met in order to apply the routing * rule.

*/ inline AwsS3BucketWebsiteConfigurationRoutingRule& WithCondition(const AwsS3BucketWebsiteConfigurationRoutingRuleCondition& value) { SetCondition(value); return *this;} /** *

Provides the condition that must be met in order to apply the routing * rule.

*/ inline AwsS3BucketWebsiteConfigurationRoutingRule& WithCondition(AwsS3BucketWebsiteConfigurationRoutingRuleCondition&& value) { SetCondition(std::move(value)); return *this;} /** *

Provides the rules to redirect the request if the condition in * Condition is met.

*/ inline const AwsS3BucketWebsiteConfigurationRoutingRuleRedirect& GetRedirect() const{ return m_redirect; } /** *

Provides the rules to redirect the request if the condition in * Condition is met.

*/ inline bool RedirectHasBeenSet() const { return m_redirectHasBeenSet; } /** *

Provides the rules to redirect the request if the condition in * Condition is met.

*/ inline void SetRedirect(const AwsS3BucketWebsiteConfigurationRoutingRuleRedirect& value) { m_redirectHasBeenSet = true; m_redirect = value; } /** *

Provides the rules to redirect the request if the condition in * Condition is met.

*/ inline void SetRedirect(AwsS3BucketWebsiteConfigurationRoutingRuleRedirect&& value) { m_redirectHasBeenSet = true; m_redirect = std::move(value); } /** *

Provides the rules to redirect the request if the condition in * Condition is met.

*/ inline AwsS3BucketWebsiteConfigurationRoutingRule& WithRedirect(const AwsS3BucketWebsiteConfigurationRoutingRuleRedirect& value) { SetRedirect(value); return *this;} /** *

Provides the rules to redirect the request if the condition in * Condition is met.

*/ inline AwsS3BucketWebsiteConfigurationRoutingRule& WithRedirect(AwsS3BucketWebsiteConfigurationRoutingRuleRedirect&& value) { SetRedirect(std::move(value)); return *this;} private: AwsS3BucketWebsiteConfigurationRoutingRuleCondition m_condition; bool m_conditionHasBeenSet = false; AwsS3BucketWebsiteConfigurationRoutingRuleRedirect m_redirect; bool m_redirectHasBeenSet = false; }; } // namespace Model } // namespace SecurityHub } // namespace Aws