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

Provides the AWS Config rule owner (AWS or customer), the rule identifier, * and the events that trigger the evaluation of your AWS resources.

See * Also:

AWS API * Reference

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

Indicates whether AWS or the customer owns and manages the AWS Config * rule.

*/ inline const Owner& GetOwner() const{ return m_owner; } /** *

Indicates whether AWS or the customer owns and manages the AWS Config * rule.

*/ inline bool OwnerHasBeenSet() const { return m_ownerHasBeenSet; } /** *

Indicates whether AWS or the customer owns and manages the AWS Config * rule.

*/ inline void SetOwner(const Owner& value) { m_ownerHasBeenSet = true; m_owner = value; } /** *

Indicates whether AWS or the customer owns and manages the AWS Config * rule.

*/ inline void SetOwner(Owner&& value) { m_ownerHasBeenSet = true; m_owner = std::move(value); } /** *

Indicates whether AWS or the customer owns and manages the AWS Config * rule.

*/ inline Source& WithOwner(const Owner& value) { SetOwner(value); return *this;} /** *

Indicates whether AWS or the customer owns and manages the AWS Config * rule.

*/ inline Source& WithOwner(Owner&& value) { SetOwner(std::move(value)); return *this;} /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline const Aws::String& GetSourceIdentifier() const{ return m_sourceIdentifier; } /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline bool SourceIdentifierHasBeenSet() const { return m_sourceIdentifierHasBeenSet; } /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline void SetSourceIdentifier(const Aws::String& value) { m_sourceIdentifierHasBeenSet = true; m_sourceIdentifier = value; } /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline void SetSourceIdentifier(Aws::String&& value) { m_sourceIdentifierHasBeenSet = true; m_sourceIdentifier = std::move(value); } /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline void SetSourceIdentifier(const char* value) { m_sourceIdentifierHasBeenSet = true; m_sourceIdentifier.assign(value); } /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline Source& WithSourceIdentifier(const Aws::String& value) { SetSourceIdentifier(value); return *this;} /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline Source& WithSourceIdentifier(Aws::String&& value) { SetSourceIdentifier(std::move(value)); return *this;} /** *

For AWS Config managed rules, a predefined identifier from a list. For * example, IAM_PASSWORD_POLICY is a managed rule. To reference a * managed rule, see Using * AWS Managed Config Rules.

For custom rules, the identifier is the * Amazon Resource Name (ARN) of the rule's AWS Lambda function, such as * arn:aws:lambda:us-east-2:123456789012:function:custom_rule_name.

*/ inline Source& WithSourceIdentifier(const char* value) { SetSourceIdentifier(value); return *this;} /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline const Aws::Vector& GetSourceDetails() const{ return m_sourceDetails; } /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline bool SourceDetailsHasBeenSet() const { return m_sourceDetailsHasBeenSet; } /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline void SetSourceDetails(const Aws::Vector& value) { m_sourceDetailsHasBeenSet = true; m_sourceDetails = value; } /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline void SetSourceDetails(Aws::Vector&& value) { m_sourceDetailsHasBeenSet = true; m_sourceDetails = std::move(value); } /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline Source& WithSourceDetails(const Aws::Vector& value) { SetSourceDetails(value); return *this;} /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline Source& WithSourceDetails(Aws::Vector&& value) { SetSourceDetails(std::move(value)); return *this;} /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline Source& AddSourceDetails(const SourceDetail& value) { m_sourceDetailsHasBeenSet = true; m_sourceDetails.push_back(value); return *this; } /** *

Provides the source and type of the event that causes AWS Config to evaluate * your AWS resources.

*/ inline Source& AddSourceDetails(SourceDetail&& value) { m_sourceDetailsHasBeenSet = true; m_sourceDetails.push_back(std::move(value)); return *this; } private: Owner m_owner; bool m_ownerHasBeenSet; Aws::String m_sourceIdentifier; bool m_sourceIdentifierHasBeenSet; Aws::Vector m_sourceDetails; bool m_sourceDetailsHasBeenSet; }; } // namespace Model } // namespace ConfigService } // namespace Aws