feat(hos_client_create, hos_client_destory): 多次调用destory不会导致重复释放

This commit is contained in:
彭宣正
2020-12-14 17:24:58 +08:00
parent 505d529c32
commit 10b370e486
55976 changed files with 8544395 additions and 2 deletions

View File

@@ -0,0 +1,227 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/iam/IAM_EXPORTS.h>
#include <aws/iam/IAMRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace IAM
{
namespace Model
{
/**
*/
class AWS_IAM_API CreateGroupRequest : public IAMRequest
{
public:
CreateGroupRequest();
// 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 "CreateGroup"; }
Aws::String SerializePayload() const override;
protected:
void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
public:
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline const Aws::String& GetPath() const{ return m_path; }
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline bool PathHasBeenSet() const { return m_pathHasBeenSet; }
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline void SetPath(const Aws::String& value) { m_pathHasBeenSet = true; m_path = value; }
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline void SetPath(Aws::String&& value) { m_pathHasBeenSet = true; m_path = std::move(value); }
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline void SetPath(const char* value) { m_pathHasBeenSet = true; m_path.assign(value); }
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline CreateGroupRequest& WithPath(const Aws::String& value) { SetPath(value); return *this;}
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline CreateGroupRequest& WithPath(Aws::String&& value) { SetPath(std::move(value)); return *this;}
/**
* <p> The path to the group. For more information about paths, see <a
* href="https://docs.aws.amazon.com/IAM/latest/UserGuide/Using_Identifiers.html">IAM
* Identifiers</a> in the <i>IAM User Guide</i>.</p> <p>This parameter is optional.
* If it is not included, it defaults to a slash (/).</p> <p>This parameter allows
* (through its <a href="http://wikipedia.org/wiki/regex">regex pattern</a>) a
* string of characters consisting of either a forward slash (/) by itself or a
* string that must begin and end with forward slashes. In addition, it can contain
* any ASCII character from the ! (<code>\u0021</code>) through the DEL character
* (<code>\u007F</code>), including most punctuation characters, digits, and upper
* and lowercased letters.</p>
*/
inline CreateGroupRequest& WithPath(const char* value) { SetPath(value); return *this;}
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline const Aws::String& GetGroupName() const{ return m_groupName; }
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline bool GroupNameHasBeenSet() const { return m_groupNameHasBeenSet; }
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline void SetGroupName(const Aws::String& value) { m_groupNameHasBeenSet = true; m_groupName = value; }
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline void SetGroupName(Aws::String&& value) { m_groupNameHasBeenSet = true; m_groupName = std::move(value); }
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline void SetGroupName(const char* value) { m_groupNameHasBeenSet = true; m_groupName.assign(value); }
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline CreateGroupRequest& WithGroupName(const Aws::String& value) { SetGroupName(value); return *this;}
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline CreateGroupRequest& WithGroupName(Aws::String&& value) { SetGroupName(std::move(value)); return *this;}
/**
* <p>The name of the group to create. Do not include the path in this value.</p>
* <p>IAM user, group, role, and policy names must be unique within the account.
* Names are not distinguished by case. For example, you cannot create resources
* named both "MyResource" and "myresource".</p>
*/
inline CreateGroupRequest& WithGroupName(const char* value) { SetGroupName(value); return *this;}
private:
Aws::String m_path;
bool m_pathHasBeenSet;
Aws::String m_groupName;
bool m_groupNameHasBeenSet;
};
} // namespace Model
} // namespace IAM
} // namespace Aws