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,154 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/migrationhub-config/MigrationHubConfigRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/migrationhub-config/model/Target.h>
#include <utility>
namespace Aws
{
namespace MigrationHubConfig
{
namespace Model
{
/**
*/
class AWS_MIGRATIONHUBCONFIG_API CreateHomeRegionControlRequest : public MigrationHubConfigRequest
{
public:
CreateHomeRegionControlRequest();
// 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 "CreateHomeRegionControl"; }
Aws::String SerializePayload() const override;
Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
/**
* <p>The name of the home region of the calling account.</p>
*/
inline const Aws::String& GetHomeRegion() const{ return m_homeRegion; }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline bool HomeRegionHasBeenSet() const { return m_homeRegionHasBeenSet; }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline void SetHomeRegion(const Aws::String& value) { m_homeRegionHasBeenSet = true; m_homeRegion = value; }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline void SetHomeRegion(Aws::String&& value) { m_homeRegionHasBeenSet = true; m_homeRegion = std::move(value); }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline void SetHomeRegion(const char* value) { m_homeRegionHasBeenSet = true; m_homeRegion.assign(value); }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline CreateHomeRegionControlRequest& WithHomeRegion(const Aws::String& value) { SetHomeRegion(value); return *this;}
/**
* <p>The name of the home region of the calling account.</p>
*/
inline CreateHomeRegionControlRequest& WithHomeRegion(Aws::String&& value) { SetHomeRegion(std::move(value)); return *this;}
/**
* <p>The name of the home region of the calling account.</p>
*/
inline CreateHomeRegionControlRequest& WithHomeRegion(const char* value) { SetHomeRegion(value); return *this;}
/**
* <p>The account for which this command sets up a home region control. The
* <code>Target</code> is always of type <code>ACCOUNT</code>.</p>
*/
inline const Target& GetTarget() const{ return m_target; }
/**
* <p>The account for which this command sets up a home region control. The
* <code>Target</code> is always of type <code>ACCOUNT</code>.</p>
*/
inline bool TargetHasBeenSet() const { return m_targetHasBeenSet; }
/**
* <p>The account for which this command sets up a home region control. The
* <code>Target</code> is always of type <code>ACCOUNT</code>.</p>
*/
inline void SetTarget(const Target& value) { m_targetHasBeenSet = true; m_target = value; }
/**
* <p>The account for which this command sets up a home region control. The
* <code>Target</code> is always of type <code>ACCOUNT</code>.</p>
*/
inline void SetTarget(Target&& value) { m_targetHasBeenSet = true; m_target = std::move(value); }
/**
* <p>The account for which this command sets up a home region control. The
* <code>Target</code> is always of type <code>ACCOUNT</code>.</p>
*/
inline CreateHomeRegionControlRequest& WithTarget(const Target& value) { SetTarget(value); return *this;}
/**
* <p>The account for which this command sets up a home region control. The
* <code>Target</code> is always of type <code>ACCOUNT</code>.</p>
*/
inline CreateHomeRegionControlRequest& WithTarget(Target&& value) { SetTarget(std::move(value)); return *this;}
/**
* <p>Optional Boolean flag to indicate whether any effect should take place. It
* tests whether the caller has permission to make the call.</p>
*/
inline bool GetDryRun() const{ return m_dryRun; }
/**
* <p>Optional Boolean flag to indicate whether any effect should take place. It
* tests whether the caller has permission to make the call.</p>
*/
inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
/**
* <p>Optional Boolean flag to indicate whether any effect should take place. It
* tests whether the caller has permission to make the call.</p>
*/
inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; }
/**
* <p>Optional Boolean flag to indicate whether any effect should take place. It
* tests whether the caller has permission to make the call.</p>
*/
inline CreateHomeRegionControlRequest& WithDryRun(bool value) { SetDryRun(value); return *this;}
private:
Aws::String m_homeRegion;
bool m_homeRegionHasBeenSet;
Target m_target;
bool m_targetHasBeenSet;
bool m_dryRun;
bool m_dryRunHasBeenSet;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,72 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/migrationhub-config/model/HomeRegionControl.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace MigrationHubConfig
{
namespace Model
{
class AWS_MIGRATIONHUBCONFIG_API CreateHomeRegionControlResult
{
public:
CreateHomeRegionControlResult();
CreateHomeRegionControlResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
CreateHomeRegionControlResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>This object is the <code>HomeRegionControl</code> object that's returned by a
* successful call to <code>CreateHomeRegionControl</code>.</p>
*/
inline const HomeRegionControl& GetHomeRegionControl() const{ return m_homeRegionControl; }
/**
* <p>This object is the <code>HomeRegionControl</code> object that's returned by a
* successful call to <code>CreateHomeRegionControl</code>.</p>
*/
inline void SetHomeRegionControl(const HomeRegionControl& value) { m_homeRegionControl = value; }
/**
* <p>This object is the <code>HomeRegionControl</code> object that's returned by a
* successful call to <code>CreateHomeRegionControl</code>.</p>
*/
inline void SetHomeRegionControl(HomeRegionControl&& value) { m_homeRegionControl = std::move(value); }
/**
* <p>This object is the <code>HomeRegionControl</code> object that's returned by a
* successful call to <code>CreateHomeRegionControl</code>.</p>
*/
inline CreateHomeRegionControlResult& WithHomeRegionControl(const HomeRegionControl& value) { SetHomeRegionControl(value); return *this;}
/**
* <p>This object is the <code>HomeRegionControl</code> object that's returned by a
* successful call to <code>CreateHomeRegionControl</code>.</p>
*/
inline CreateHomeRegionControlResult& WithHomeRegionControl(HomeRegionControl&& value) { SetHomeRegionControl(std::move(value)); return *this;}
private:
HomeRegionControl m_homeRegionControl;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,268 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/migrationhub-config/MigrationHubConfigRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/migrationhub-config/model/Target.h>
#include <utility>
namespace Aws
{
namespace MigrationHubConfig
{
namespace Model
{
/**
*/
class AWS_MIGRATIONHUBCONFIG_API DescribeHomeRegionControlsRequest : public MigrationHubConfigRequest
{
public:
DescribeHomeRegionControlsRequest();
// 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 "DescribeHomeRegionControls"; }
Aws::String SerializePayload() const override;
Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline const Aws::String& GetControlId() const{ return m_controlId; }
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline bool ControlIdHasBeenSet() const { return m_controlIdHasBeenSet; }
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline void SetControlId(const Aws::String& value) { m_controlIdHasBeenSet = true; m_controlId = value; }
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline void SetControlId(Aws::String&& value) { m_controlIdHasBeenSet = true; m_controlId = std::move(value); }
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline void SetControlId(const char* value) { m_controlIdHasBeenSet = true; m_controlId.assign(value); }
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline DescribeHomeRegionControlsRequest& WithControlId(const Aws::String& value) { SetControlId(value); return *this;}
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline DescribeHomeRegionControlsRequest& WithControlId(Aws::String&& value) { SetControlId(std::move(value)); return *this;}
/**
* <p>The <code>ControlID</code> is a unique identifier string of your
* <code>HomeRegionControl</code> object.</p>
*/
inline DescribeHomeRegionControlsRequest& WithControlId(const char* value) { SetControlId(value); return *this;}
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline const Aws::String& GetHomeRegion() const{ return m_homeRegion; }
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline bool HomeRegionHasBeenSet() const { return m_homeRegionHasBeenSet; }
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline void SetHomeRegion(const Aws::String& value) { m_homeRegionHasBeenSet = true; m_homeRegion = value; }
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline void SetHomeRegion(Aws::String&& value) { m_homeRegionHasBeenSet = true; m_homeRegion = std::move(value); }
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline void SetHomeRegion(const char* value) { m_homeRegionHasBeenSet = true; m_homeRegion.assign(value); }
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline DescribeHomeRegionControlsRequest& WithHomeRegion(const Aws::String& value) { SetHomeRegion(value); return *this;}
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline DescribeHomeRegionControlsRequest& WithHomeRegion(Aws::String&& value) { SetHomeRegion(std::move(value)); return *this;}
/**
* <p>The name of the home region you'd like to view.</p>
*/
inline DescribeHomeRegionControlsRequest& WithHomeRegion(const char* value) { SetHomeRegion(value); return *this;}
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always of type <code>ACCOUNT</code>. It applies the home
* region to the current <code>ACCOUNT</code>.</p>
*/
inline const Target& GetTarget() const{ return m_target; }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always of type <code>ACCOUNT</code>. It applies the home
* region to the current <code>ACCOUNT</code>.</p>
*/
inline bool TargetHasBeenSet() const { return m_targetHasBeenSet; }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always of type <code>ACCOUNT</code>. It applies the home
* region to the current <code>ACCOUNT</code>.</p>
*/
inline void SetTarget(const Target& value) { m_targetHasBeenSet = true; m_target = value; }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always of type <code>ACCOUNT</code>. It applies the home
* region to the current <code>ACCOUNT</code>.</p>
*/
inline void SetTarget(Target&& value) { m_targetHasBeenSet = true; m_target = std::move(value); }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always of type <code>ACCOUNT</code>. It applies the home
* region to the current <code>ACCOUNT</code>.</p>
*/
inline DescribeHomeRegionControlsRequest& WithTarget(const Target& value) { SetTarget(value); return *this;}
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always of type <code>ACCOUNT</code>. It applies the home
* region to the current <code>ACCOUNT</code>.</p>
*/
inline DescribeHomeRegionControlsRequest& WithTarget(Target&& value) { SetTarget(std::move(value)); return *this;}
/**
* <p>The maximum number of filtering results to display per page. </p>
*/
inline int GetMaxResults() const{ return m_maxResults; }
/**
* <p>The maximum number of filtering results to display per page. </p>
*/
inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; }
/**
* <p>The maximum number of filtering results to display per page. </p>
*/
inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; }
/**
* <p>The maximum number of filtering results to display per page. </p>
*/
inline DescribeHomeRegionControlsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;}
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline DescribeHomeRegionControlsRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline DescribeHomeRegionControlsRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline DescribeHomeRegionControlsRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;}
private:
Aws::String m_controlId;
bool m_controlIdHasBeenSet;
Aws::String m_homeRegion;
bool m_homeRegionHasBeenSet;
Target m_target;
bool m_targetHasBeenSet;
int m_maxResults;
bool m_maxResultsHasBeenSet;
Aws::String m_nextToken;
bool m_nextTokenHasBeenSet;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,131 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/migrationhub-config/model/HomeRegionControl.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace MigrationHubConfig
{
namespace Model
{
class AWS_MIGRATIONHUBCONFIG_API DescribeHomeRegionControlsResult
{
public:
DescribeHomeRegionControlsResult();
DescribeHomeRegionControlsResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
DescribeHomeRegionControlsResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>An array that contains your <code>HomeRegionControl</code> objects.</p>
*/
inline const Aws::Vector<HomeRegionControl>& GetHomeRegionControls() const{ return m_homeRegionControls; }
/**
* <p>An array that contains your <code>HomeRegionControl</code> objects.</p>
*/
inline void SetHomeRegionControls(const Aws::Vector<HomeRegionControl>& value) { m_homeRegionControls = value; }
/**
* <p>An array that contains your <code>HomeRegionControl</code> objects.</p>
*/
inline void SetHomeRegionControls(Aws::Vector<HomeRegionControl>&& value) { m_homeRegionControls = std::move(value); }
/**
* <p>An array that contains your <code>HomeRegionControl</code> objects.</p>
*/
inline DescribeHomeRegionControlsResult& WithHomeRegionControls(const Aws::Vector<HomeRegionControl>& value) { SetHomeRegionControls(value); return *this;}
/**
* <p>An array that contains your <code>HomeRegionControl</code> objects.</p>
*/
inline DescribeHomeRegionControlsResult& WithHomeRegionControls(Aws::Vector<HomeRegionControl>&& value) { SetHomeRegionControls(std::move(value)); return *this;}
/**
* <p>An array that contains your <code>HomeRegionControl</code> objects.</p>
*/
inline DescribeHomeRegionControlsResult& AddHomeRegionControls(const HomeRegionControl& value) { m_homeRegionControls.push_back(value); return *this; }
/**
* <p>An array that contains your <code>HomeRegionControl</code> objects.</p>
*/
inline DescribeHomeRegionControlsResult& AddHomeRegionControls(HomeRegionControl&& value) { m_homeRegionControls.push_back(std::move(value)); return *this; }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextToken = value; }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextToken = std::move(value); }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline void SetNextToken(const char* value) { m_nextToken.assign(value); }
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline DescribeHomeRegionControlsResult& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline DescribeHomeRegionControlsResult& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>If a <code>NextToken</code> was returned by a previous call, more results are
* available. To retrieve the next page of results, make the call again using the
* returned token in <code>NextToken</code>.</p>
*/
inline DescribeHomeRegionControlsResult& WithNextToken(const char* value) { SetNextToken(value); return *this;}
private:
Aws::Vector<HomeRegionControl> m_homeRegionControls;
Aws::String m_nextToken;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,38 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/migrationhub-config/MigrationHubConfigRequest.h>
namespace Aws
{
namespace MigrationHubConfig
{
namespace Model
{
/**
*/
class AWS_MIGRATIONHUBCONFIG_API GetHomeRegionRequest : public MigrationHubConfigRequest
{
public:
GetHomeRegionRequest();
// 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 "GetHomeRegion"; }
Aws::String SerializePayload() const override;
Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,77 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace MigrationHubConfig
{
namespace Model
{
class AWS_MIGRATIONHUBCONFIG_API GetHomeRegionResult
{
public:
GetHomeRegionResult();
GetHomeRegionResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
GetHomeRegionResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The name of the home region of the calling account.</p>
*/
inline const Aws::String& GetHomeRegion() const{ return m_homeRegion; }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline void SetHomeRegion(const Aws::String& value) { m_homeRegion = value; }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline void SetHomeRegion(Aws::String&& value) { m_homeRegion = std::move(value); }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline void SetHomeRegion(const char* value) { m_homeRegion.assign(value); }
/**
* <p>The name of the home region of the calling account.</p>
*/
inline GetHomeRegionResult& WithHomeRegion(const Aws::String& value) { SetHomeRegion(value); return *this;}
/**
* <p>The name of the home region of the calling account.</p>
*/
inline GetHomeRegionResult& WithHomeRegion(Aws::String&& value) { SetHomeRegion(std::move(value)); return *this;}
/**
* <p>The name of the home region of the calling account.</p>
*/
inline GetHomeRegionResult& WithHomeRegion(const char* value) { SetHomeRegion(value); return *this;}
private:
Aws::String m_homeRegion;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,253 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/migrationhub-config/model/Target.h>
#include <aws/core/utils/DateTime.h>
#include <utility>
namespace Aws
{
namespace Utils
{
namespace Json
{
class JsonValue;
class JsonView;
} // namespace Json
} // namespace Utils
namespace MigrationHubConfig
{
namespace Model
{
/**
* <p>A home region control is an object that specifies the home region for an
* account, with some additional information. It contains a target (always of type
* <code>ACCOUNT</code>), an ID, and a time at which the home region was
* set.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/migrationhub-config-2019-06-30/HomeRegionControl">AWS
* API Reference</a></p>
*/
class AWS_MIGRATIONHUBCONFIG_API HomeRegionControl
{
public:
HomeRegionControl();
HomeRegionControl(Aws::Utils::Json::JsonView jsonValue);
HomeRegionControl& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline const Aws::String& GetControlId() const{ return m_controlId; }
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline bool ControlIdHasBeenSet() const { return m_controlIdHasBeenSet; }
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline void SetControlId(const Aws::String& value) { m_controlIdHasBeenSet = true; m_controlId = value; }
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline void SetControlId(Aws::String&& value) { m_controlIdHasBeenSet = true; m_controlId = std::move(value); }
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline void SetControlId(const char* value) { m_controlIdHasBeenSet = true; m_controlId.assign(value); }
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline HomeRegionControl& WithControlId(const Aws::String& value) { SetControlId(value); return *this;}
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline HomeRegionControl& WithControlId(Aws::String&& value) { SetControlId(std::move(value)); return *this;}
/**
* <p>A unique identifier that's generated for each home region control. It's
* always a string that begins with "hrc-" followed by 12 lowercase letters and
* numbers.</p>
*/
inline HomeRegionControl& WithControlId(const char* value) { SetControlId(value); return *this;}
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline const Aws::String& GetHomeRegion() const{ return m_homeRegion; }
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline bool HomeRegionHasBeenSet() const { return m_homeRegionHasBeenSet; }
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline void SetHomeRegion(const Aws::String& value) { m_homeRegionHasBeenSet = true; m_homeRegion = value; }
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline void SetHomeRegion(Aws::String&& value) { m_homeRegionHasBeenSet = true; m_homeRegion = std::move(value); }
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline void SetHomeRegion(const char* value) { m_homeRegionHasBeenSet = true; m_homeRegion.assign(value); }
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline HomeRegionControl& WithHomeRegion(const Aws::String& value) { SetHomeRegion(value); return *this;}
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline HomeRegionControl& WithHomeRegion(Aws::String&& value) { SetHomeRegion(std::move(value)); return *this;}
/**
* <p>The AWS Region that's been set as home region. For example, "us-west-2" or
* "eu-central-1" are valid home regions.</p>
*/
inline HomeRegionControl& WithHomeRegion(const char* value) { SetHomeRegion(value); return *this;}
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always an <code>ACCOUNT</code>. It applies the home region to
* the current <code>ACCOUNT</code>.</p>
*/
inline const Target& GetTarget() const{ return m_target; }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always an <code>ACCOUNT</code>. It applies the home region to
* the current <code>ACCOUNT</code>.</p>
*/
inline bool TargetHasBeenSet() const { return m_targetHasBeenSet; }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always an <code>ACCOUNT</code>. It applies the home region to
* the current <code>ACCOUNT</code>.</p>
*/
inline void SetTarget(const Target& value) { m_targetHasBeenSet = true; m_target = value; }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always an <code>ACCOUNT</code>. It applies the home region to
* the current <code>ACCOUNT</code>.</p>
*/
inline void SetTarget(Target&& value) { m_targetHasBeenSet = true; m_target = std::move(value); }
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always an <code>ACCOUNT</code>. It applies the home region to
* the current <code>ACCOUNT</code>.</p>
*/
inline HomeRegionControl& WithTarget(const Target& value) { SetTarget(value); return *this;}
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always an <code>ACCOUNT</code>. It applies the home region to
* the current <code>ACCOUNT</code>.</p>
*/
inline HomeRegionControl& WithTarget(Target&& value) { SetTarget(std::move(value)); return *this;}
/**
* <p>A timestamp representing the time when the customer called
* <code>CreateHomeregionControl</code> and set the home region for the
* account.</p>
*/
inline const Aws::Utils::DateTime& GetRequestedTime() const{ return m_requestedTime; }
/**
* <p>A timestamp representing the time when the customer called
* <code>CreateHomeregionControl</code> and set the home region for the
* account.</p>
*/
inline bool RequestedTimeHasBeenSet() const { return m_requestedTimeHasBeenSet; }
/**
* <p>A timestamp representing the time when the customer called
* <code>CreateHomeregionControl</code> and set the home region for the
* account.</p>
*/
inline void SetRequestedTime(const Aws::Utils::DateTime& value) { m_requestedTimeHasBeenSet = true; m_requestedTime = value; }
/**
* <p>A timestamp representing the time when the customer called
* <code>CreateHomeregionControl</code> and set the home region for the
* account.</p>
*/
inline void SetRequestedTime(Aws::Utils::DateTime&& value) { m_requestedTimeHasBeenSet = true; m_requestedTime = std::move(value); }
/**
* <p>A timestamp representing the time when the customer called
* <code>CreateHomeregionControl</code> and set the home region for the
* account.</p>
*/
inline HomeRegionControl& WithRequestedTime(const Aws::Utils::DateTime& value) { SetRequestedTime(value); return *this;}
/**
* <p>A timestamp representing the time when the customer called
* <code>CreateHomeregionControl</code> and set the home region for the
* account.</p>
*/
inline HomeRegionControl& WithRequestedTime(Aws::Utils::DateTime&& value) { SetRequestedTime(std::move(value)); return *this;}
private:
Aws::String m_controlId;
bool m_controlIdHasBeenSet;
Aws::String m_homeRegion;
bool m_homeRegionHasBeenSet;
Target m_target;
bool m_targetHasBeenSet;
Aws::Utils::DateTime m_requestedTime;
bool m_requestedTimeHasBeenSet;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,141 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/migrationhub-config/model/TargetType.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Utils
{
namespace Json
{
class JsonValue;
class JsonView;
} // namespace Json
} // namespace Utils
namespace MigrationHubConfig
{
namespace Model
{
/**
* <p>The target parameter specifies the identifier to which the home region is
* applied, which is always an <code>ACCOUNT</code>. It applies the home region to
* the current <code>ACCOUNT</code>.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/migrationhub-config-2019-06-30/Target">AWS
* API Reference</a></p>
*/
class AWS_MIGRATIONHUBCONFIG_API Target
{
public:
Target();
Target(Aws::Utils::Json::JsonView jsonValue);
Target& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
/**
* <p>The target type is always an <code>ACCOUNT</code>.</p>
*/
inline const TargetType& GetType() const{ return m_type; }
/**
* <p>The target type is always an <code>ACCOUNT</code>.</p>
*/
inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
/**
* <p>The target type is always an <code>ACCOUNT</code>.</p>
*/
inline void SetType(const TargetType& value) { m_typeHasBeenSet = true; m_type = value; }
/**
* <p>The target type is always an <code>ACCOUNT</code>.</p>
*/
inline void SetType(TargetType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); }
/**
* <p>The target type is always an <code>ACCOUNT</code>.</p>
*/
inline Target& WithType(const TargetType& value) { SetType(value); return *this;}
/**
* <p>The target type is always an <code>ACCOUNT</code>.</p>
*/
inline Target& WithType(TargetType&& value) { SetType(std::move(value)); return *this;}
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline const Aws::String& GetId() const{ return m_id; }
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline bool IdHasBeenSet() const { return m_idHasBeenSet; }
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline void SetId(const Aws::String& value) { m_idHasBeenSet = true; m_id = value; }
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline void SetId(Aws::String&& value) { m_idHasBeenSet = true; m_id = std::move(value); }
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline void SetId(const char* value) { m_idHasBeenSet = true; m_id.assign(value); }
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline Target& WithId(const Aws::String& value) { SetId(value); return *this;}
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline Target& WithId(Aws::String&& value) { SetId(std::move(value)); return *this;}
/**
* <p>The <code>TargetID</code> is a 12-character identifier of the
* <code>ACCOUNT</code> for which the control was created. (This must be the
* current account.) </p>
*/
inline Target& WithId(const char* value) { SetId(value); return *this;}
private:
TargetType m_type;
bool m_typeHasBeenSet;
Aws::String m_id;
bool m_idHasBeenSet;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,30 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
namespace Aws
{
namespace MigrationHubConfig
{
namespace Model
{
enum class TargetType
{
NOT_SET,
ACCOUNT
};
namespace TargetTypeMapper
{
AWS_MIGRATIONHUBCONFIG_API TargetType GetTargetTypeForName(const Aws::String& name);
AWS_MIGRATIONHUBCONFIG_API Aws::String GetNameForTargetType(TargetType value);
} // namespace TargetTypeMapper
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws

View File

@@ -0,0 +1,97 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/migrationhub-config/MigrationHubConfig_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Utils
{
namespace Json
{
class JsonValue;
class JsonView;
} // namespace Json
} // namespace Utils
namespace MigrationHubConfig
{
namespace Model
{
/**
* <p>The request was denied due to request throttling.</p><p><h3>See Also:</h3>
* <a
* href="http://docs.aws.amazon.com/goto/WebAPI/migrationhub-config-2019-06-30/ThrottlingException">AWS
* API Reference</a></p>
*/
class AWS_MIGRATIONHUBCONFIG_API ThrottlingException
{
public:
ThrottlingException();
ThrottlingException(Aws::Utils::Json::JsonView jsonValue);
ThrottlingException& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
inline const Aws::String& GetMessage() const{ return m_message; }
inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
inline void SetMessage(const Aws::String& value) { m_messageHasBeenSet = true; m_message = value; }
inline void SetMessage(Aws::String&& value) { m_messageHasBeenSet = true; m_message = std::move(value); }
inline void SetMessage(const char* value) { m_messageHasBeenSet = true; m_message.assign(value); }
inline ThrottlingException& WithMessage(const Aws::String& value) { SetMessage(value); return *this;}
inline ThrottlingException& WithMessage(Aws::String&& value) { SetMessage(std::move(value)); return *this;}
inline ThrottlingException& WithMessage(const char* value) { SetMessage(value); return *this;}
/**
* <p>The number of seconds the caller should wait before retrying.</p>
*/
inline int GetRetryAfterSeconds() const{ return m_retryAfterSeconds; }
/**
* <p>The number of seconds the caller should wait before retrying.</p>
*/
inline bool RetryAfterSecondsHasBeenSet() const { return m_retryAfterSecondsHasBeenSet; }
/**
* <p>The number of seconds the caller should wait before retrying.</p>
*/
inline void SetRetryAfterSeconds(int value) { m_retryAfterSecondsHasBeenSet = true; m_retryAfterSeconds = value; }
/**
* <p>The number of seconds the caller should wait before retrying.</p>
*/
inline ThrottlingException& WithRetryAfterSeconds(int value) { SetRetryAfterSeconds(value); return *this;}
private:
Aws::String m_message;
bool m_messageHasBeenSet;
int m_retryAfterSeconds;
bool m_retryAfterSecondsHasBeenSet;
};
} // namespace Model
} // namespace MigrationHubConfig
} // namespace Aws