/** * 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 Organizations { namespace Model { /** */ class UpdatePolicyRequest : public OrganizationsRequest { public: AWS_ORGANIZATIONS_API UpdatePolicyRequest(); // 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 "UpdatePolicy"; } AWS_ORGANIZATIONS_API Aws::String SerializePayload() const override; AWS_ORGANIZATIONS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline const Aws::String& GetPolicyId() const{ return m_policyId; } /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline bool PolicyIdHasBeenSet() const { return m_policyIdHasBeenSet; } /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline void SetPolicyId(const Aws::String& value) { m_policyIdHasBeenSet = true; m_policyId = value; } /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline void SetPolicyId(Aws::String&& value) { m_policyIdHasBeenSet = true; m_policyId = std::move(value); } /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline void SetPolicyId(const char* value) { m_policyIdHasBeenSet = true; m_policyId.assign(value); } /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline UpdatePolicyRequest& WithPolicyId(const Aws::String& value) { SetPolicyId(value); return *this;} /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline UpdatePolicyRequest& WithPolicyId(Aws::String&& value) { SetPolicyId(std::move(value)); return *this;} /** *

The unique identifier (ID) of the policy that you want to update.

The * regex pattern for a policy ID * string requires "p-" followed by from 8 to 128 lowercase or uppercase letters, * digits, or the underscore character (_).

*/ inline UpdatePolicyRequest& WithPolicyId(const char* value) { SetPolicyId(value); return *this;} /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline UpdatePolicyRequest& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline UpdatePolicyRequest& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

If provided, the new name for the policy.

The regex pattern that is used to * validate this parameter is a string of any of the characters in the ASCII * character range.

*/ inline UpdatePolicyRequest& WithName(const char* value) { SetName(value); return *this;} /** *

If provided, the new description for the policy.

*/ inline const Aws::String& GetDescription() const{ return m_description; } /** *

If provided, the new description for the policy.

*/ inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } /** *

If provided, the new description for the policy.

*/ inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } /** *

If provided, the new description for the policy.

*/ inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } /** *

If provided, the new description for the policy.

*/ inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } /** *

If provided, the new description for the policy.

*/ inline UpdatePolicyRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} /** *

If provided, the new description for the policy.

*/ inline UpdatePolicyRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} /** *

If provided, the new description for the policy.

*/ inline UpdatePolicyRequest& WithDescription(const char* value) { SetDescription(value); return *this;} /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline const Aws::String& GetContent() const{ return m_content; } /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline bool ContentHasBeenSet() const { return m_contentHasBeenSet; } /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline void SetContent(const Aws::String& value) { m_contentHasBeenSet = true; m_content = value; } /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline void SetContent(Aws::String&& value) { m_contentHasBeenSet = true; m_content = std::move(value); } /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline void SetContent(const char* value) { m_contentHasBeenSet = true; m_content.assign(value); } /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline UpdatePolicyRequest& WithContent(const Aws::String& value) { SetContent(value); return *this;} /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline UpdatePolicyRequest& WithContent(Aws::String&& value) { SetContent(std::move(value)); return *this;} /** *

If provided, the new content for the policy. The text must be correctly * formatted JSON that complies with the syntax for the policy's type. For more * information, see Service * Control Policy Syntax in the Organizations User Guide.

*/ inline UpdatePolicyRequest& WithContent(const char* value) { SetContent(value); return *this;} private: Aws::String m_policyId; bool m_policyIdHasBeenSet = false; Aws::String m_name; bool m_nameHasBeenSet = false; Aws::String m_description; bool m_descriptionHasBeenSet = false; Aws::String m_content; bool m_contentHasBeenSet = false; }; } // namespace Model } // namespace Organizations } // namespace Aws