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,76 @@
add_project(aws-cpp-sdk-detective "C++ SDK for the AWS detective service" aws-cpp-sdk-core)
file(GLOB AWS_DETECTIVE_HEADERS
"include/aws/detective/*.h"
)
file(GLOB AWS_DETECTIVE_MODEL_HEADERS
"include/aws/detective/model/*.h"
)
file(GLOB AWS_DETECTIVE_SOURCE
"source/*.cpp"
)
file(GLOB AWS_DETECTIVE_MODEL_SOURCE
"source/model/*.cpp"
)
file(GLOB DETECTIVE_UNIFIED_HEADERS
${AWS_DETECTIVE_HEADERS}
${AWS_DETECTIVE_MODEL_HEADERS}
)
file(GLOB DETECTIVE_UNITY_SRC
${AWS_DETECTIVE_SOURCE}
${AWS_DETECTIVE_MODEL_SOURCE}
)
if(ENABLE_UNITY_BUILD)
enable_unity_build("DETECTIVE" DETECTIVE_UNITY_SRC)
endif()
file(GLOB DETECTIVE_SRC
${DETECTIVE_UNIFIED_HEADERS}
${DETECTIVE_UNITY_SRC}
)
if(WIN32)
#if we are compiling for visual studio, create a sane directory tree.
if(MSVC)
source_group("Header Files\\aws\\detective" FILES ${AWS_DETECTIVE_HEADERS})
source_group("Header Files\\aws\\detective\\model" FILES ${AWS_DETECTIVE_MODEL_HEADERS})
source_group("Source Files" FILES ${AWS_DETECTIVE_SOURCE})
source_group("Source Files\\model" FILES ${AWS_DETECTIVE_MODEL_SOURCE})
endif(MSVC)
endif()
set(DETECTIVE_INCLUDES
"${CMAKE_CURRENT_SOURCE_DIR}/include/"
)
add_library(${PROJECT_NAME} ${DETECTIVE_SRC})
add_library(AWS::${PROJECT_NAME} ALIAS ${PROJECT_NAME})
set_compiler_flags(${PROJECT_NAME})
set_compiler_warnings(${PROJECT_NAME})
if(USE_WINDOWS_DLL_SEMANTICS AND BUILD_SHARED_LIBS)
target_compile_definitions(${PROJECT_NAME} PRIVATE "AWS_DETECTIVE_EXPORTS")
endif()
target_include_directories(${PROJECT_NAME} PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
$<INSTALL_INTERFACE:include>)
target_link_libraries(${PROJECT_NAME} PRIVATE ${PLATFORM_DEP_LIBS} ${PROJECT_LIBS})
setup_install()
install (FILES ${AWS_DETECTIVE_HEADERS} DESTINATION ${INCLUDE_DIRECTORY}/aws/detective)
install (FILES ${AWS_DETECTIVE_MODEL_HEADERS} DESTINATION ${INCLUDE_DIRECTORY}/aws/detective/model)
do_packaging()

View File

@@ -0,0 +1,657 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveErrors.h>
#include <aws/core/client/AWSError.h>
#include <aws/core/client/ClientConfiguration.h>
#include <aws/core/client/AWSClient.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/detective/model/CreateGraphResult.h>
#include <aws/detective/model/CreateMembersResult.h>
#include <aws/detective/model/DeleteMembersResult.h>
#include <aws/detective/model/GetMembersResult.h>
#include <aws/detective/model/ListGraphsResult.h>
#include <aws/detective/model/ListInvitationsResult.h>
#include <aws/detective/model/ListMembersResult.h>
#include <aws/core/NoResult.h>
#include <aws/core/client/AsyncCallerContext.h>
#include <aws/core/http/HttpTypes.h>
#include <future>
#include <functional>
namespace Aws
{
namespace Http
{
class HttpClient;
class HttpClientFactory;
} // namespace Http
namespace Utils
{
template< typename R, typename E> class Outcome;
namespace Threading
{
class Executor;
} // namespace Threading
} // namespace Utils
namespace Auth
{
class AWSCredentials;
class AWSCredentialsProvider;
} // namespace Auth
namespace Client
{
class RetryStrategy;
} // namespace Client
namespace Detective
{
namespace Model
{
class AcceptInvitationRequest;
class CreateMembersRequest;
class DeleteGraphRequest;
class DeleteMembersRequest;
class DisassociateMembershipRequest;
class GetMembersRequest;
class ListGraphsRequest;
class ListInvitationsRequest;
class ListMembersRequest;
class RejectInvitationRequest;
class StartMonitoringMemberRequest;
typedef Aws::Utils::Outcome<Aws::NoResult, DetectiveError> AcceptInvitationOutcome;
typedef Aws::Utils::Outcome<CreateGraphResult, DetectiveError> CreateGraphOutcome;
typedef Aws::Utils::Outcome<CreateMembersResult, DetectiveError> CreateMembersOutcome;
typedef Aws::Utils::Outcome<Aws::NoResult, DetectiveError> DeleteGraphOutcome;
typedef Aws::Utils::Outcome<DeleteMembersResult, DetectiveError> DeleteMembersOutcome;
typedef Aws::Utils::Outcome<Aws::NoResult, DetectiveError> DisassociateMembershipOutcome;
typedef Aws::Utils::Outcome<GetMembersResult, DetectiveError> GetMembersOutcome;
typedef Aws::Utils::Outcome<ListGraphsResult, DetectiveError> ListGraphsOutcome;
typedef Aws::Utils::Outcome<ListInvitationsResult, DetectiveError> ListInvitationsOutcome;
typedef Aws::Utils::Outcome<ListMembersResult, DetectiveError> ListMembersOutcome;
typedef Aws::Utils::Outcome<Aws::NoResult, DetectiveError> RejectInvitationOutcome;
typedef Aws::Utils::Outcome<Aws::NoResult, DetectiveError> StartMonitoringMemberOutcome;
typedef std::future<AcceptInvitationOutcome> AcceptInvitationOutcomeCallable;
typedef std::future<CreateGraphOutcome> CreateGraphOutcomeCallable;
typedef std::future<CreateMembersOutcome> CreateMembersOutcomeCallable;
typedef std::future<DeleteGraphOutcome> DeleteGraphOutcomeCallable;
typedef std::future<DeleteMembersOutcome> DeleteMembersOutcomeCallable;
typedef std::future<DisassociateMembershipOutcome> DisassociateMembershipOutcomeCallable;
typedef std::future<GetMembersOutcome> GetMembersOutcomeCallable;
typedef std::future<ListGraphsOutcome> ListGraphsOutcomeCallable;
typedef std::future<ListInvitationsOutcome> ListInvitationsOutcomeCallable;
typedef std::future<ListMembersOutcome> ListMembersOutcomeCallable;
typedef std::future<RejectInvitationOutcome> RejectInvitationOutcomeCallable;
typedef std::future<StartMonitoringMemberOutcome> StartMonitoringMemberOutcomeCallable;
} // namespace Model
class DetectiveClient;
typedef std::function<void(const DetectiveClient*, const Model::AcceptInvitationRequest&, const Model::AcceptInvitationOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > AcceptInvitationResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::CreateGraphOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > CreateGraphResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::CreateMembersRequest&, const Model::CreateMembersOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > CreateMembersResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::DeleteGraphRequest&, const Model::DeleteGraphOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > DeleteGraphResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::DeleteMembersRequest&, const Model::DeleteMembersOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > DeleteMembersResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::DisassociateMembershipRequest&, const Model::DisassociateMembershipOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > DisassociateMembershipResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::GetMembersRequest&, const Model::GetMembersOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > GetMembersResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::ListGraphsRequest&, const Model::ListGraphsOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > ListGraphsResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::ListInvitationsRequest&, const Model::ListInvitationsOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > ListInvitationsResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::ListMembersRequest&, const Model::ListMembersOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > ListMembersResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::RejectInvitationRequest&, const Model::RejectInvitationOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > RejectInvitationResponseReceivedHandler;
typedef std::function<void(const DetectiveClient*, const Model::StartMonitoringMemberRequest&, const Model::StartMonitoringMemberOutcome&, const std::shared_ptr<const Aws::Client::AsyncCallerContext>&) > StartMonitoringMemberResponseReceivedHandler;
/**
* <p>Detective uses machine learning and purpose-built visualizations to help you
* analyze and investigate security issues across your Amazon Web Services (AWS)
* workloads. Detective automatically extracts time-based events such as login
* attempts, API calls, and network traffic from AWS CloudTrail and Amazon Virtual
* Private Cloud (Amazon VPC) flow logs. It also extracts findings detected by
* Amazon GuardDuty.</p> <p>The Detective API primarily supports the creation and
* management of behavior graphs. A behavior graph contains the extracted data from
* a set of member accounts, and is created and managed by a master account.</p>
* <p>Every behavior graph is specific to a Region. You can only use the API to
* manage graphs that belong to the Region that is associated with the currently
* selected endpoint.</p> <p>A Detective master account can use the Detective API
* to do the following:</p> <ul> <li> <p>Enable and disable Detective. Enabling
* Detective creates a new behavior graph.</p> </li> <li> <p>View the list of
* member accounts in a behavior graph.</p> </li> <li> <p>Add member accounts to a
* behavior graph.</p> </li> <li> <p>Remove member accounts from a behavior
* graph.</p> </li> </ul> <p>A member account can use the Detective API to do the
* following:</p> <ul> <li> <p>View the list of behavior graphs that they are
* invited to.</p> </li> <li> <p>Accept an invitation to contribute to a behavior
* graph.</p> </li> <li> <p>Decline an invitation to contribute to a behavior
* graph.</p> </li> <li> <p>Remove their account from a behavior graph.</p> </li>
* </ul> <p>All API actions are logged as CloudTrail events. See <a
* href="https://docs.aws.amazon.com/detective/latest/adminguide/logging-using-cloudtrail.html">Logging
* Detective API Calls with CloudTrail</a>.</p>
*/
class AWS_DETECTIVE_API DetectiveClient : public Aws::Client::AWSJsonClient
{
public:
typedef Aws::Client::AWSJsonClient BASECLASS;
/**
* Initializes client to use DefaultCredentialProviderChain, with default http client factory, and optional client config. If client config
* is not specified, it will be initialized to default values.
*/
DetectiveClient(const Aws::Client::ClientConfiguration& clientConfiguration = Aws::Client::ClientConfiguration());
/**
* Initializes client to use SimpleAWSCredentialsProvider, with default http client factory, and optional client config. If client config
* is not specified, it will be initialized to default values.
*/
DetectiveClient(const Aws::Auth::AWSCredentials& credentials, const Aws::Client::ClientConfiguration& clientConfiguration = Aws::Client::ClientConfiguration());
/**
* Initializes client to use specified credentials provider with specified client config. If http client factory is not supplied,
* the default http client factory will be used
*/
DetectiveClient(const std::shared_ptr<Aws::Auth::AWSCredentialsProvider>& credentialsProvider,
const Aws::Client::ClientConfiguration& clientConfiguration = Aws::Client::ClientConfiguration());
virtual ~DetectiveClient();
/**
* <p>Accepts an invitation for the member account to contribute data to a behavior
* graph. This operation can only be called by an invited member account. </p>
* <p>The request provides the ARN of behavior graph.</p> <p>The member account
* status in the graph must be <code>INVITED</code>.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/AcceptInvitation">AWS
* API Reference</a></p>
*/
virtual Model::AcceptInvitationOutcome AcceptInvitation(const Model::AcceptInvitationRequest& request) const;
/**
* <p>Accepts an invitation for the member account to contribute data to a behavior
* graph. This operation can only be called by an invited member account. </p>
* <p>The request provides the ARN of behavior graph.</p> <p>The member account
* status in the graph must be <code>INVITED</code>.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/AcceptInvitation">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::AcceptInvitationOutcomeCallable AcceptInvitationCallable(const Model::AcceptInvitationRequest& request) const;
/**
* <p>Accepts an invitation for the member account to contribute data to a behavior
* graph. This operation can only be called by an invited member account. </p>
* <p>The request provides the ARN of behavior graph.</p> <p>The member account
* status in the graph must be <code>INVITED</code>.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/AcceptInvitation">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void AcceptInvitationAsync(const Model::AcceptInvitationRequest& request, const AcceptInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Creates a new behavior graph for the calling account, and sets that account
* as the master account. This operation is called by the account that is enabling
* Detective.</p> <p>Before you try to enable Detective, make sure that your
* account has been enrolled in Amazon GuardDuty for at least 48 hours. If you do
* not meet this requirement, you cannot enable Detective. If you do meet the
* GuardDuty prerequisite, then when you make the request to enable Detective, it
* checks whether your data volume is within the Detective quota. If it exceeds the
* quota, then you cannot enable Detective. </p> <p>The operation also enables
* Detective for the calling account in the currently selected Region. It returns
* the ARN of the new behavior graph.</p> <p> <code>CreateGraph</code> triggers a
* process to create the corresponding data tables for the new behavior graph.</p>
* <p>An account can only be the master account for one behavior graph within a
* Region. If the same account calls <code>CreateGraph</code> with the same master
* account, it always returns the same behavior graph ARN. It does not create a new
* behavior graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/CreateGraph">AWS
* API Reference</a></p>
*/
virtual Model::CreateGraphOutcome CreateGraph() const;
/**
* <p>Creates a new behavior graph for the calling account, and sets that account
* as the master account. This operation is called by the account that is enabling
* Detective.</p> <p>Before you try to enable Detective, make sure that your
* account has been enrolled in Amazon GuardDuty for at least 48 hours. If you do
* not meet this requirement, you cannot enable Detective. If you do meet the
* GuardDuty prerequisite, then when you make the request to enable Detective, it
* checks whether your data volume is within the Detective quota. If it exceeds the
* quota, then you cannot enable Detective. </p> <p>The operation also enables
* Detective for the calling account in the currently selected Region. It returns
* the ARN of the new behavior graph.</p> <p> <code>CreateGraph</code> triggers a
* process to create the corresponding data tables for the new behavior graph.</p>
* <p>An account can only be the master account for one behavior graph within a
* Region. If the same account calls <code>CreateGraph</code> with the same master
* account, it always returns the same behavior graph ARN. It does not create a new
* behavior graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/CreateGraph">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::CreateGraphOutcomeCallable CreateGraphCallable() const;
/**
* <p>Creates a new behavior graph for the calling account, and sets that account
* as the master account. This operation is called by the account that is enabling
* Detective.</p> <p>Before you try to enable Detective, make sure that your
* account has been enrolled in Amazon GuardDuty for at least 48 hours. If you do
* not meet this requirement, you cannot enable Detective. If you do meet the
* GuardDuty prerequisite, then when you make the request to enable Detective, it
* checks whether your data volume is within the Detective quota. If it exceeds the
* quota, then you cannot enable Detective. </p> <p>The operation also enables
* Detective for the calling account in the currently selected Region. It returns
* the ARN of the new behavior graph.</p> <p> <code>CreateGraph</code> triggers a
* process to create the corresponding data tables for the new behavior graph.</p>
* <p>An account can only be the master account for one behavior graph within a
* Region. If the same account calls <code>CreateGraph</code> with the same master
* account, it always returns the same behavior graph ARN. It does not create a new
* behavior graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/CreateGraph">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void CreateGraphAsync(const CreateGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Sends a request to invite the specified AWS accounts to be member accounts in
* the behavior graph. This operation can only be called by the master account for
* a behavior graph. </p> <p> <code>CreateMembers</code> verifies the accounts and
* then sends invitations to the verified accounts.</p> <p>The request provides the
* behavior graph ARN and the list of accounts to invite.</p> <p>The response
* separates the requested accounts into two lists:</p> <ul> <li> <p>The accounts
* that <code>CreateMembers</code> was able to start the verification for. This
* list includes member accounts that are being verified, that have passed
* verification and are being sent an invitation, and that have failed
* verification.</p> </li> <li> <p>The accounts that <code>CreateMembers</code> was
* unable to process. This list includes accounts that were already invited to be
* member accounts in the behavior graph.</p> </li> </ul><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/CreateMembers">AWS
* API Reference</a></p>
*/
virtual Model::CreateMembersOutcome CreateMembers(const Model::CreateMembersRequest& request) const;
/**
* <p>Sends a request to invite the specified AWS accounts to be member accounts in
* the behavior graph. This operation can only be called by the master account for
* a behavior graph. </p> <p> <code>CreateMembers</code> verifies the accounts and
* then sends invitations to the verified accounts.</p> <p>The request provides the
* behavior graph ARN and the list of accounts to invite.</p> <p>The response
* separates the requested accounts into two lists:</p> <ul> <li> <p>The accounts
* that <code>CreateMembers</code> was able to start the verification for. This
* list includes member accounts that are being verified, that have passed
* verification and are being sent an invitation, and that have failed
* verification.</p> </li> <li> <p>The accounts that <code>CreateMembers</code> was
* unable to process. This list includes accounts that were already invited to be
* member accounts in the behavior graph.</p> </li> </ul><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/CreateMembers">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::CreateMembersOutcomeCallable CreateMembersCallable(const Model::CreateMembersRequest& request) const;
/**
* <p>Sends a request to invite the specified AWS accounts to be member accounts in
* the behavior graph. This operation can only be called by the master account for
* a behavior graph. </p> <p> <code>CreateMembers</code> verifies the accounts and
* then sends invitations to the verified accounts.</p> <p>The request provides the
* behavior graph ARN and the list of accounts to invite.</p> <p>The response
* separates the requested accounts into two lists:</p> <ul> <li> <p>The accounts
* that <code>CreateMembers</code> was able to start the verification for. This
* list includes member accounts that are being verified, that have passed
* verification and are being sent an invitation, and that have failed
* verification.</p> </li> <li> <p>The accounts that <code>CreateMembers</code> was
* unable to process. This list includes accounts that were already invited to be
* member accounts in the behavior graph.</p> </li> </ul><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/CreateMembers">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void CreateMembersAsync(const Model::CreateMembersRequest& request, const CreateMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Disables the specified behavior graph and queues it to be deleted. This
* operation removes the graph from each member account's list of behavior
* graphs.</p> <p> <code>DeleteGraph</code> can only be called by the master
* account for a behavior graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DeleteGraph">AWS
* API Reference</a></p>
*/
virtual Model::DeleteGraphOutcome DeleteGraph(const Model::DeleteGraphRequest& request) const;
/**
* <p>Disables the specified behavior graph and queues it to be deleted. This
* operation removes the graph from each member account's list of behavior
* graphs.</p> <p> <code>DeleteGraph</code> can only be called by the master
* account for a behavior graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DeleteGraph">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::DeleteGraphOutcomeCallable DeleteGraphCallable(const Model::DeleteGraphRequest& request) const;
/**
* <p>Disables the specified behavior graph and queues it to be deleted. This
* operation removes the graph from each member account's list of behavior
* graphs.</p> <p> <code>DeleteGraph</code> can only be called by the master
* account for a behavior graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DeleteGraph">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void DeleteGraphAsync(const Model::DeleteGraphRequest& request, const DeleteGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Deletes one or more member accounts from the master account behavior graph.
* This operation can only be called by a Detective master account. That account
* cannot use <code>DeleteMembers</code> to delete their own account from the
* behavior graph. To disable a behavior graph, the master account uses the
* <code>DeleteGraph</code> API method.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DeleteMembers">AWS
* API Reference</a></p>
*/
virtual Model::DeleteMembersOutcome DeleteMembers(const Model::DeleteMembersRequest& request) const;
/**
* <p>Deletes one or more member accounts from the master account behavior graph.
* This operation can only be called by a Detective master account. That account
* cannot use <code>DeleteMembers</code> to delete their own account from the
* behavior graph. To disable a behavior graph, the master account uses the
* <code>DeleteGraph</code> API method.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DeleteMembers">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::DeleteMembersOutcomeCallable DeleteMembersCallable(const Model::DeleteMembersRequest& request) const;
/**
* <p>Deletes one or more member accounts from the master account behavior graph.
* This operation can only be called by a Detective master account. That account
* cannot use <code>DeleteMembers</code> to delete their own account from the
* behavior graph. To disable a behavior graph, the master account uses the
* <code>DeleteGraph</code> API method.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DeleteMembers">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void DeleteMembersAsync(const Model::DeleteMembersRequest& request, const DeleteMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Removes the member account from the specified behavior graph. This operation
* can only be called by a member account that has the <code>ENABLED</code>
* status.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DisassociateMembership">AWS
* API Reference</a></p>
*/
virtual Model::DisassociateMembershipOutcome DisassociateMembership(const Model::DisassociateMembershipRequest& request) const;
/**
* <p>Removes the member account from the specified behavior graph. This operation
* can only be called by a member account that has the <code>ENABLED</code>
* status.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DisassociateMembership">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::DisassociateMembershipOutcomeCallable DisassociateMembershipCallable(const Model::DisassociateMembershipRequest& request) const;
/**
* <p>Removes the member account from the specified behavior graph. This operation
* can only be called by a member account that has the <code>ENABLED</code>
* status.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/DisassociateMembership">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void DisassociateMembershipAsync(const Model::DisassociateMembershipRequest& request, const DisassociateMembershipResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Returns the membership details for specified member accounts for a behavior
* graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/GetMembers">AWS
* API Reference</a></p>
*/
virtual Model::GetMembersOutcome GetMembers(const Model::GetMembersRequest& request) const;
/**
* <p>Returns the membership details for specified member accounts for a behavior
* graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/GetMembers">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::GetMembersOutcomeCallable GetMembersCallable(const Model::GetMembersRequest& request) const;
/**
* <p>Returns the membership details for specified member accounts for a behavior
* graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/GetMembers">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void GetMembersAsync(const Model::GetMembersRequest& request, const GetMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Returns the list of behavior graphs that the calling account is a master of.
* This operation can only be called by a master account.</p> <p>Because an account
* can currently only be the master of one behavior graph within a Region, the
* results always contain a single graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListGraphs">AWS
* API Reference</a></p>
*/
virtual Model::ListGraphsOutcome ListGraphs(const Model::ListGraphsRequest& request) const;
/**
* <p>Returns the list of behavior graphs that the calling account is a master of.
* This operation can only be called by a master account.</p> <p>Because an account
* can currently only be the master of one behavior graph within a Region, the
* results always contain a single graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListGraphs">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::ListGraphsOutcomeCallable ListGraphsCallable(const Model::ListGraphsRequest& request) const;
/**
* <p>Returns the list of behavior graphs that the calling account is a master of.
* This operation can only be called by a master account.</p> <p>Because an account
* can currently only be the master of one behavior graph within a Region, the
* results always contain a single graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListGraphs">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void ListGraphsAsync(const Model::ListGraphsRequest& request, const ListGraphsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Retrieves the list of open and accepted behavior graph invitations for the
* member account. This operation can only be called by a member account.</p>
* <p>Open invitations are invitations that the member account has not responded
* to.</p> <p>The results do not include behavior graphs for which the member
* account declined the invitation. The results also do not include behavior graphs
* that the member account resigned from or was removed from.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListInvitations">AWS
* API Reference</a></p>
*/
virtual Model::ListInvitationsOutcome ListInvitations(const Model::ListInvitationsRequest& request) const;
/**
* <p>Retrieves the list of open and accepted behavior graph invitations for the
* member account. This operation can only be called by a member account.</p>
* <p>Open invitations are invitations that the member account has not responded
* to.</p> <p>The results do not include behavior graphs for which the member
* account declined the invitation. The results also do not include behavior graphs
* that the member account resigned from or was removed from.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListInvitations">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::ListInvitationsOutcomeCallable ListInvitationsCallable(const Model::ListInvitationsRequest& request) const;
/**
* <p>Retrieves the list of open and accepted behavior graph invitations for the
* member account. This operation can only be called by a member account.</p>
* <p>Open invitations are invitations that the member account has not responded
* to.</p> <p>The results do not include behavior graphs for which the member
* account declined the invitation. The results also do not include behavior graphs
* that the member account resigned from or was removed from.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListInvitations">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void ListInvitationsAsync(const Model::ListInvitationsRequest& request, const ListInvitationsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Retrieves the list of member accounts for a behavior graph. Does not return
* member accounts that were removed from the behavior graph.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListMembers">AWS
* API Reference</a></p>
*/
virtual Model::ListMembersOutcome ListMembers(const Model::ListMembersRequest& request) const;
/**
* <p>Retrieves the list of member accounts for a behavior graph. Does not return
* member accounts that were removed from the behavior graph.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListMembers">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::ListMembersOutcomeCallable ListMembersCallable(const Model::ListMembersRequest& request) const;
/**
* <p>Retrieves the list of member accounts for a behavior graph. Does not return
* member accounts that were removed from the behavior graph.</p><p><h3>See
* Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/ListMembers">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void ListMembersAsync(const Model::ListMembersRequest& request, const ListMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Rejects an invitation to contribute the account data to a behavior graph.
* This operation must be called by a member account that has the
* <code>INVITED</code> status.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/RejectInvitation">AWS
* API Reference</a></p>
*/
virtual Model::RejectInvitationOutcome RejectInvitation(const Model::RejectInvitationRequest& request) const;
/**
* <p>Rejects an invitation to contribute the account data to a behavior graph.
* This operation must be called by a member account that has the
* <code>INVITED</code> status.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/RejectInvitation">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::RejectInvitationOutcomeCallable RejectInvitationCallable(const Model::RejectInvitationRequest& request) const;
/**
* <p>Rejects an invitation to contribute the account data to a behavior graph.
* This operation must be called by a member account that has the
* <code>INVITED</code> status.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/RejectInvitation">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void RejectInvitationAsync(const Model::RejectInvitationRequest& request, const RejectInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
/**
* <p>Sends a request to enable data ingest for a member account that has a status
* of <code>ACCEPTED_BUT_DISABLED</code>.</p> <p>For valid member accounts, the
* status is updated as follows.</p> <ul> <li> <p>If Detective enabled the member
* account, then the new status is <code>ENABLED</code>.</p> </li> <li> <p>If
* Detective cannot enable the member account, the status remains
* <code>ACCEPTED_BUT_DISABLED</code>. </p> </li> </ul><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/StartMonitoringMember">AWS
* API Reference</a></p>
*/
virtual Model::StartMonitoringMemberOutcome StartMonitoringMember(const Model::StartMonitoringMemberRequest& request) const;
/**
* <p>Sends a request to enable data ingest for a member account that has a status
* of <code>ACCEPTED_BUT_DISABLED</code>.</p> <p>For valid member accounts, the
* status is updated as follows.</p> <ul> <li> <p>If Detective enabled the member
* account, then the new status is <code>ENABLED</code>.</p> </li> <li> <p>If
* Detective cannot enable the member account, the status remains
* <code>ACCEPTED_BUT_DISABLED</code>. </p> </li> </ul><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/StartMonitoringMember">AWS
* API Reference</a></p>
*
* returns a future to the operation so that it can be executed in parallel to other requests.
*/
virtual Model::StartMonitoringMemberOutcomeCallable StartMonitoringMemberCallable(const Model::StartMonitoringMemberRequest& request) const;
/**
* <p>Sends a request to enable data ingest for a member account that has a status
* of <code>ACCEPTED_BUT_DISABLED</code>.</p> <p>For valid member accounts, the
* status is updated as follows.</p> <ul> <li> <p>If Detective enabled the member
* account, then the new status is <code>ENABLED</code>.</p> </li> <li> <p>If
* Detective cannot enable the member account, the status remains
* <code>ACCEPTED_BUT_DISABLED</code>. </p> </li> </ul><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/StartMonitoringMember">AWS
* API Reference</a></p>
*
* Queues the request into a thread executor and triggers associated callback when operation has finished.
*/
virtual void StartMonitoringMemberAsync(const Model::StartMonitoringMemberRequest& request, const StartMonitoringMemberResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context = nullptr) const;
void OverrideEndpoint(const Aws::String& endpoint);
private:
void init(const Aws::Client::ClientConfiguration& clientConfiguration);
void AcceptInvitationAsyncHelper(const Model::AcceptInvitationRequest& request, const AcceptInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void CreateGraphAsyncHelper(const CreateGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void CreateMembersAsyncHelper(const Model::CreateMembersRequest& request, const CreateMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void DeleteGraphAsyncHelper(const Model::DeleteGraphRequest& request, const DeleteGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void DeleteMembersAsyncHelper(const Model::DeleteMembersRequest& request, const DeleteMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void DisassociateMembershipAsyncHelper(const Model::DisassociateMembershipRequest& request, const DisassociateMembershipResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void GetMembersAsyncHelper(const Model::GetMembersRequest& request, const GetMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void ListGraphsAsyncHelper(const Model::ListGraphsRequest& request, const ListGraphsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void ListInvitationsAsyncHelper(const Model::ListInvitationsRequest& request, const ListInvitationsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void ListMembersAsyncHelper(const Model::ListMembersRequest& request, const ListMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void RejectInvitationAsyncHelper(const Model::RejectInvitationRequest& request, const RejectInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
void StartMonitoringMemberAsyncHelper(const Model::StartMonitoringMemberRequest& request, const StartMonitoringMemberResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const;
Aws::String m_uri;
Aws::String m_configScheme;
std::shared_ptr<Aws::Utils::Threading::Executor> m_executor;
};
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,21 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/Region.h>
#include <aws/core/utils/memory/stl/AWSString.h>
namespace Aws
{
namespace Detective
{
namespace DetectiveEndpoint
{
AWS_DETECTIVE_API Aws::String ForRegion(const Aws::String& regionName, bool useDualStack = false);
} // namespace DetectiveEndpoint
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,23 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/client/AWSErrorMarshaller.h>
namespace Aws
{
namespace Client
{
class AWS_DETECTIVE_API DetectiveErrorMarshaller : public Aws::Client::JsonErrorMarshaller
{
public:
Aws::Client::AWSError<Aws::Client::CoreErrors> FindErrorByName(const char* exceptionName) const override;
};
} // namespace Client
} // namespace Aws

View File

@@ -0,0 +1,74 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/core/client/AWSError.h>
#include <aws/core/client/CoreErrors.h>
#include <aws/detective/Detective_EXPORTS.h>
namespace Aws
{
namespace Detective
{
enum class DetectiveErrors
{
//From Core//
//////////////////////////////////////////////////////////////////////////////////////////
INCOMPLETE_SIGNATURE = 0,
INTERNAL_FAILURE = 1,
INVALID_ACTION = 2,
INVALID_CLIENT_TOKEN_ID = 3,
INVALID_PARAMETER_COMBINATION = 4,
INVALID_QUERY_PARAMETER = 5,
INVALID_PARAMETER_VALUE = 6,
MISSING_ACTION = 7, // SDK should never allow
MISSING_AUTHENTICATION_TOKEN = 8, // SDK should never allow
MISSING_PARAMETER = 9, // SDK should never allow
OPT_IN_REQUIRED = 10,
REQUEST_EXPIRED = 11,
SERVICE_UNAVAILABLE = 12,
THROTTLING = 13,
VALIDATION = 14,
ACCESS_DENIED = 15,
RESOURCE_NOT_FOUND = 16,
UNRECOGNIZED_CLIENT = 17,
MALFORMED_QUERY_STRING = 18,
SLOW_DOWN = 19,
REQUEST_TIME_TOO_SKEWED = 20,
INVALID_SIGNATURE = 21,
SIGNATURE_DOES_NOT_MATCH = 22,
INVALID_ACCESS_KEY_ID = 23,
REQUEST_TIMEOUT = 24,
NETWORK_CONNECTION = 99,
UNKNOWN = 100,
///////////////////////////////////////////////////////////////////////////////////////////
CONFLICT= static_cast<int>(Aws::Client::CoreErrors::SERVICE_EXTENSION_START_RANGE) + 1,
INTERNAL_SERVER,
SERVICE_QUOTA_EXCEEDED
};
class AWS_DETECTIVE_API DetectiveError : public Aws::Client::AWSError<DetectiveErrors>
{
public:
DetectiveError() {}
DetectiveError(const Aws::Client::AWSError<Aws::Client::CoreErrors>& rhs) : Aws::Client::AWSError<DetectiveErrors>(rhs) {}
DetectiveError(Aws::Client::AWSError<Aws::Client::CoreErrors>&& rhs) : Aws::Client::AWSError<DetectiveErrors>(rhs) {}
DetectiveError(const Aws::Client::AWSError<DetectiveErrors>& rhs) : Aws::Client::AWSError<DetectiveErrors>(rhs) {}
DetectiveError(Aws::Client::AWSError<DetectiveErrors>&& rhs) : Aws::Client::AWSError<DetectiveErrors>(rhs) {}
template <typename T>
T GetModeledError();
};
namespace DetectiveErrorMapper
{
AWS_DETECTIVE_API Aws::Client::AWSError<Aws::Client::CoreErrors> GetErrorForName(const char* errorName);
}
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,42 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/AmazonSerializableWebServiceRequest.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <aws/core/http/HttpRequest.h>
namespace Aws
{
namespace Detective
{
class AWS_DETECTIVE_API DetectiveRequest : public Aws::AmazonSerializableWebServiceRequest
{
public:
virtual ~DetectiveRequest () {}
void AddParametersToRequest(Aws::Http::HttpRequest& httpRequest) const { AWS_UNREFERENCED_PARAM(httpRequest); }
inline Aws::Http::HeaderValueCollection GetHeaders() const override
{
auto headers = GetRequestSpecificHeaders();
if(headers.size() == 0 || (headers.size() > 0 && headers.count(Aws::Http::CONTENT_TYPE_HEADER) == 0))
{
headers.emplace(Aws::Http::HeaderValuePair(Aws::Http::CONTENT_TYPE_HEADER, Aws::AMZN_JSON_CONTENT_TYPE_1_1 ));
}
headers.emplace(Aws::Http::HeaderValuePair(Aws::Http::API_VERSION_HEADER, "2018-10-26"));
return headers;
}
protected:
virtual Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const { return Aws::Http::HeaderValueCollection(); }
};
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,29 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#ifdef _MSC_VER
//disable windows complaining about max template size.
#pragma warning (disable : 4503)
#endif // _MSC_VER
#if defined (USE_WINDOWS_DLL_SEMANTICS) || defined (_WIN32)
#ifdef _MSC_VER
#pragma warning(disable : 4251)
#endif // _MSC_VER
#ifdef USE_IMPORT_EXPORT
#ifdef AWS_DETECTIVE_EXPORTS
#define AWS_DETECTIVE_API __declspec(dllexport)
#else
#define AWS_DETECTIVE_API __declspec(dllimport)
#endif /* AWS_DETECTIVE_EXPORTS */
#else
#define AWS_DETECTIVE_API
#endif // USE_IMPORT_EXPORT
#else // defined (USE_WINDOWS_DLL_SEMANTICS) || defined (WIN32)
#define AWS_DETECTIVE_API
#endif // defined (USE_WINDOWS_DLL_SEMANTICS) || defined (WIN32)

View File

@@ -0,0 +1,99 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API AcceptInvitationRequest : public DetectiveRequest
{
public:
AcceptInvitationRequest();
// 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 "AcceptInvitation"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline AcceptInvitationRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline AcceptInvitationRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph that the member account is accepting the
* invitation for.</p> <p>The member account status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline AcceptInvitationRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,133 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_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 Detective
{
namespace Model
{
/**
* <p>An AWS account that is the master of or a member of a behavior
* graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/Account">AWS
* API Reference</a></p>
*/
class AWS_DETECTIVE_API Account
{
public:
Account();
Account(Aws::Utils::Json::JsonView jsonValue);
Account& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
/**
* <p>The account identifier of the AWS account.</p>
*/
inline const Aws::String& GetAccountId() const{ return m_accountId; }
/**
* <p>The account identifier of the AWS account.</p>
*/
inline bool AccountIdHasBeenSet() const { return m_accountIdHasBeenSet; }
/**
* <p>The account identifier of the AWS account.</p>
*/
inline void SetAccountId(const Aws::String& value) { m_accountIdHasBeenSet = true; m_accountId = value; }
/**
* <p>The account identifier of the AWS account.</p>
*/
inline void SetAccountId(Aws::String&& value) { m_accountIdHasBeenSet = true; m_accountId = std::move(value); }
/**
* <p>The account identifier of the AWS account.</p>
*/
inline void SetAccountId(const char* value) { m_accountIdHasBeenSet = true; m_accountId.assign(value); }
/**
* <p>The account identifier of the AWS account.</p>
*/
inline Account& WithAccountId(const Aws::String& value) { SetAccountId(value); return *this;}
/**
* <p>The account identifier of the AWS account.</p>
*/
inline Account& WithAccountId(Aws::String&& value) { SetAccountId(std::move(value)); return *this;}
/**
* <p>The account identifier of the AWS account.</p>
*/
inline Account& WithAccountId(const char* value) { SetAccountId(value); return *this;}
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline const Aws::String& GetEmailAddress() const{ return m_emailAddress; }
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline bool EmailAddressHasBeenSet() const { return m_emailAddressHasBeenSet; }
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline void SetEmailAddress(const Aws::String& value) { m_emailAddressHasBeenSet = true; m_emailAddress = value; }
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline void SetEmailAddress(Aws::String&& value) { m_emailAddressHasBeenSet = true; m_emailAddress = std::move(value); }
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline void SetEmailAddress(const char* value) { m_emailAddressHasBeenSet = true; m_emailAddress.assign(value); }
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline Account& WithEmailAddress(const Aws::String& value) { SetEmailAddress(value); return *this;}
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline Account& WithEmailAddress(Aws::String&& value) { SetEmailAddress(std::move(value)); return *this;}
/**
* <p>The AWS account root user email address for the AWS account.</p>
*/
inline Account& WithEmailAddress(const char* value) { SetEmailAddress(value); return *this;}
private:
Aws::String m_accountId;
bool m_accountIdHasBeenSet;
Aws::String m_emailAddress;
bool m_emailAddressHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // 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/detective/Detective_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 Detective
{
namespace Model
{
class AWS_DETECTIVE_API CreateGraphResult
{
public:
CreateGraphResult();
CreateGraphResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
CreateGraphResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The ARN of the new behavior graph.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the new behavior graph.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArn = value; }
/**
* <p>The ARN of the new behavior graph.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArn = std::move(value); }
/**
* <p>The ARN of the new behavior graph.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArn.assign(value); }
/**
* <p>The ARN of the new behavior graph.</p>
*/
inline CreateGraphResult& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the new behavior graph.</p>
*/
inline CreateGraphResult& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the new behavior graph.</p>
*/
inline CreateGraphResult& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
private:
Aws::String m_graphArn;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,205 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/detective/model/Account.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API CreateMembersRequest : public DetectiveRequest
{
public:
CreateMembersRequest();
// 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 "CreateMembers"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline CreateMembersRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline CreateMembersRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph to invite the member accounts to contribute
* their data to.</p>
*/
inline CreateMembersRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline const Aws::String& GetMessage() const{ return m_message; }
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; }
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline void SetMessage(const Aws::String& value) { m_messageHasBeenSet = true; m_message = value; }
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline void SetMessage(Aws::String&& value) { m_messageHasBeenSet = true; m_message = std::move(value); }
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline void SetMessage(const char* value) { m_messageHasBeenSet = true; m_message.assign(value); }
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline CreateMembersRequest& WithMessage(const Aws::String& value) { SetMessage(value); return *this;}
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline CreateMembersRequest& WithMessage(Aws::String&& value) { SetMessage(std::move(value)); return *this;}
/**
* <p>Customized message text to include in the invitation email message to the
* invited member accounts.</p>
*/
inline CreateMembersRequest& WithMessage(const char* value) { SetMessage(value); return *this;}
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline const Aws::Vector<Account>& GetAccounts() const{ return m_accounts; }
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline bool AccountsHasBeenSet() const { return m_accountsHasBeenSet; }
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline void SetAccounts(const Aws::Vector<Account>& value) { m_accountsHasBeenSet = true; m_accounts = value; }
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline void SetAccounts(Aws::Vector<Account>&& value) { m_accountsHasBeenSet = true; m_accounts = std::move(value); }
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline CreateMembersRequest& WithAccounts(const Aws::Vector<Account>& value) { SetAccounts(value); return *this;}
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline CreateMembersRequest& WithAccounts(Aws::Vector<Account>&& value) { SetAccounts(std::move(value)); return *this;}
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline CreateMembersRequest& AddAccounts(const Account& value) { m_accountsHasBeenSet = true; m_accounts.push_back(value); return *this; }
/**
* <p>The list of AWS accounts to invite to become member accounts in the behavior
* graph. For each invited account, the account list contains the account
* identifier and the AWS account root user email address.</p>
*/
inline CreateMembersRequest& AddAccounts(Account&& value) { m_accountsHasBeenSet = true; m_accounts.push_back(std::move(value)); return *this; }
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
Aws::String m_message;
bool m_messageHasBeenSet;
Aws::Vector<Account> m_accounts;
bool m_accountsHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,152 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/detective/model/MemberDetail.h>
#include <aws/detective/model/UnprocessedAccount.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
class AWS_DETECTIVE_API CreateMembersResult
{
public:
CreateMembersResult();
CreateMembersResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
CreateMembersResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The set of member account invitation requests that Detective was able to
* process. This includes accounts that are being verified, that failed
* verification, and that passed verification and are being sent an invitation.</p>
*/
inline const Aws::Vector<MemberDetail>& GetMembers() const{ return m_members; }
/**
* <p>The set of member account invitation requests that Detective was able to
* process. This includes accounts that are being verified, that failed
* verification, and that passed verification and are being sent an invitation.</p>
*/
inline void SetMembers(const Aws::Vector<MemberDetail>& value) { m_members = value; }
/**
* <p>The set of member account invitation requests that Detective was able to
* process. This includes accounts that are being verified, that failed
* verification, and that passed verification and are being sent an invitation.</p>
*/
inline void SetMembers(Aws::Vector<MemberDetail>&& value) { m_members = std::move(value); }
/**
* <p>The set of member account invitation requests that Detective was able to
* process. This includes accounts that are being verified, that failed
* verification, and that passed verification and are being sent an invitation.</p>
*/
inline CreateMembersResult& WithMembers(const Aws::Vector<MemberDetail>& value) { SetMembers(value); return *this;}
/**
* <p>The set of member account invitation requests that Detective was able to
* process. This includes accounts that are being verified, that failed
* verification, and that passed verification and are being sent an invitation.</p>
*/
inline CreateMembersResult& WithMembers(Aws::Vector<MemberDetail>&& value) { SetMembers(std::move(value)); return *this;}
/**
* <p>The set of member account invitation requests that Detective was able to
* process. This includes accounts that are being verified, that failed
* verification, and that passed verification and are being sent an invitation.</p>
*/
inline CreateMembersResult& AddMembers(const MemberDetail& value) { m_members.push_back(value); return *this; }
/**
* <p>The set of member account invitation requests that Detective was able to
* process. This includes accounts that are being verified, that failed
* verification, and that passed verification and are being sent an invitation.</p>
*/
inline CreateMembersResult& AddMembers(MemberDetail&& value) { m_members.push_back(std::move(value)); return *this; }
/**
* <p>The list of accounts for which Detective was unable to process the invitation
* request. For each account, the list provides the reason why the request could
* not be processed. The list includes accounts that are already member accounts in
* the behavior graph.</p>
*/
inline const Aws::Vector<UnprocessedAccount>& GetUnprocessedAccounts() const{ return m_unprocessedAccounts; }
/**
* <p>The list of accounts for which Detective was unable to process the invitation
* request. For each account, the list provides the reason why the request could
* not be processed. The list includes accounts that are already member accounts in
* the behavior graph.</p>
*/
inline void SetUnprocessedAccounts(const Aws::Vector<UnprocessedAccount>& value) { m_unprocessedAccounts = value; }
/**
* <p>The list of accounts for which Detective was unable to process the invitation
* request. For each account, the list provides the reason why the request could
* not be processed. The list includes accounts that are already member accounts in
* the behavior graph.</p>
*/
inline void SetUnprocessedAccounts(Aws::Vector<UnprocessedAccount>&& value) { m_unprocessedAccounts = std::move(value); }
/**
* <p>The list of accounts for which Detective was unable to process the invitation
* request. For each account, the list provides the reason why the request could
* not be processed. The list includes accounts that are already member accounts in
* the behavior graph.</p>
*/
inline CreateMembersResult& WithUnprocessedAccounts(const Aws::Vector<UnprocessedAccount>& value) { SetUnprocessedAccounts(value); return *this;}
/**
* <p>The list of accounts for which Detective was unable to process the invitation
* request. For each account, the list provides the reason why the request could
* not be processed. The list includes accounts that are already member accounts in
* the behavior graph.</p>
*/
inline CreateMembersResult& WithUnprocessedAccounts(Aws::Vector<UnprocessedAccount>&& value) { SetUnprocessedAccounts(std::move(value)); return *this;}
/**
* <p>The list of accounts for which Detective was unable to process the invitation
* request. For each account, the list provides the reason why the request could
* not be processed. The list includes accounts that are already member accounts in
* the behavior graph.</p>
*/
inline CreateMembersResult& AddUnprocessedAccounts(const UnprocessedAccount& value) { m_unprocessedAccounts.push_back(value); return *this; }
/**
* <p>The list of accounts for which Detective was unable to process the invitation
* request. For each account, the list provides the reason why the request could
* not be processed. The list includes accounts that are already member accounts in
* the behavior graph.</p>
*/
inline CreateMembersResult& AddUnprocessedAccounts(UnprocessedAccount&& value) { m_unprocessedAccounts.push_back(std::move(value)); return *this; }
private:
Aws::Vector<MemberDetail> m_members;
Aws::Vector<UnprocessedAccount> m_unprocessedAccounts;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,83 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API DeleteGraphRequest : public DetectiveRequest
{
public:
DeleteGraphRequest();
// 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 "DeleteGraph"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline DeleteGraphRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline DeleteGraphRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph to disable.</p>
*/
inline DeleteGraphRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,142 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API DeleteMembersRequest : public DetectiveRequest
{
public:
DeleteMembersRequest();
// 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 "DeleteMembers"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline DeleteMembersRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline DeleteMembersRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph to delete members from.</p>
*/
inline DeleteMembersRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline const Aws::Vector<Aws::String>& GetAccountIds() const{ return m_accountIds; }
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline bool AccountIdsHasBeenSet() const { return m_accountIdsHasBeenSet; }
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline void SetAccountIds(const Aws::Vector<Aws::String>& value) { m_accountIdsHasBeenSet = true; m_accountIds = value; }
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline void SetAccountIds(Aws::Vector<Aws::String>&& value) { m_accountIdsHasBeenSet = true; m_accountIds = std::move(value); }
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline DeleteMembersRequest& WithAccountIds(const Aws::Vector<Aws::String>& value) { SetAccountIds(value); return *this;}
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline DeleteMembersRequest& WithAccountIds(Aws::Vector<Aws::String>&& value) { SetAccountIds(std::move(value)); return *this;}
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline DeleteMembersRequest& AddAccountIds(const Aws::String& value) { m_accountIdsHasBeenSet = true; m_accountIds.push_back(value); return *this; }
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline DeleteMembersRequest& AddAccountIds(Aws::String&& value) { m_accountIdsHasBeenSet = true; m_accountIds.push_back(std::move(value)); return *this; }
/**
* <p>The list of AWS account identifiers for the member accounts to delete from
* the behavior graph.</p>
*/
inline DeleteMembersRequest& AddAccountIds(const char* value) { m_accountIdsHasBeenSet = true; m_accountIds.push_back(value); return *this; }
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
Aws::Vector<Aws::String> m_accountIds;
bool m_accountIdsHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,144 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/detective/model/UnprocessedAccount.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
class AWS_DETECTIVE_API DeleteMembersResult
{
public:
DeleteMembersResult();
DeleteMembersResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
DeleteMembersResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline const Aws::Vector<Aws::String>& GetAccountIds() const{ return m_accountIds; }
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline void SetAccountIds(const Aws::Vector<Aws::String>& value) { m_accountIds = value; }
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline void SetAccountIds(Aws::Vector<Aws::String>&& value) { m_accountIds = std::move(value); }
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline DeleteMembersResult& WithAccountIds(const Aws::Vector<Aws::String>& value) { SetAccountIds(value); return *this;}
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline DeleteMembersResult& WithAccountIds(Aws::Vector<Aws::String>&& value) { SetAccountIds(std::move(value)); return *this;}
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline DeleteMembersResult& AddAccountIds(const Aws::String& value) { m_accountIds.push_back(value); return *this; }
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline DeleteMembersResult& AddAccountIds(Aws::String&& value) { m_accountIds.push_back(std::move(value)); return *this; }
/**
* <p>The list of AWS account identifiers for the member accounts that Detective
* successfully deleted from the behavior graph.</p>
*/
inline DeleteMembersResult& AddAccountIds(const char* value) { m_accountIds.push_back(value); return *this; }
/**
* <p>The list of member accounts that Detective was not able to delete from the
* behavior graph. For each member account, provides the reason that the deletion
* could not be processed.</p>
*/
inline const Aws::Vector<UnprocessedAccount>& GetUnprocessedAccounts() const{ return m_unprocessedAccounts; }
/**
* <p>The list of member accounts that Detective was not able to delete from the
* behavior graph. For each member account, provides the reason that the deletion
* could not be processed.</p>
*/
inline void SetUnprocessedAccounts(const Aws::Vector<UnprocessedAccount>& value) { m_unprocessedAccounts = value; }
/**
* <p>The list of member accounts that Detective was not able to delete from the
* behavior graph. For each member account, provides the reason that the deletion
* could not be processed.</p>
*/
inline void SetUnprocessedAccounts(Aws::Vector<UnprocessedAccount>&& value) { m_unprocessedAccounts = std::move(value); }
/**
* <p>The list of member accounts that Detective was not able to delete from the
* behavior graph. For each member account, provides the reason that the deletion
* could not be processed.</p>
*/
inline DeleteMembersResult& WithUnprocessedAccounts(const Aws::Vector<UnprocessedAccount>& value) { SetUnprocessedAccounts(value); return *this;}
/**
* <p>The list of member accounts that Detective was not able to delete from the
* behavior graph. For each member account, provides the reason that the deletion
* could not be processed.</p>
*/
inline DeleteMembersResult& WithUnprocessedAccounts(Aws::Vector<UnprocessedAccount>&& value) { SetUnprocessedAccounts(std::move(value)); return *this;}
/**
* <p>The list of member accounts that Detective was not able to delete from the
* behavior graph. For each member account, provides the reason that the deletion
* could not be processed.</p>
*/
inline DeleteMembersResult& AddUnprocessedAccounts(const UnprocessedAccount& value) { m_unprocessedAccounts.push_back(value); return *this; }
/**
* <p>The list of member accounts that Detective was not able to delete from the
* behavior graph. For each member account, provides the reason that the deletion
* could not be processed.</p>
*/
inline DeleteMembersResult& AddUnprocessedAccounts(UnprocessedAccount&& value) { m_unprocessedAccounts.push_back(std::move(value)); return *this; }
private:
Aws::Vector<Aws::String> m_accountIds;
Aws::Vector<UnprocessedAccount> m_unprocessedAccounts;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,99 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API DisassociateMembershipRequest : public DetectiveRequest
{
public:
DisassociateMembershipRequest();
// 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 "DisassociateMembership"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline DisassociateMembershipRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline DisassociateMembershipRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph to remove the member account from.</p> <p>The
* member account's member status in the behavior graph must be
* <code>ENABLED</code>.</p>
*/
inline DisassociateMembershipRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,151 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API GetMembersRequest : public DetectiveRequest
{
public:
GetMembersRequest();
// 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 "GetMembers"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline GetMembersRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline GetMembersRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph for which to request the member details.</p>
*/
inline GetMembersRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline const Aws::Vector<Aws::String>& GetAccountIds() const{ return m_accountIds; }
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline bool AccountIdsHasBeenSet() const { return m_accountIdsHasBeenSet; }
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline void SetAccountIds(const Aws::Vector<Aws::String>& value) { m_accountIdsHasBeenSet = true; m_accountIds = value; }
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline void SetAccountIds(Aws::Vector<Aws::String>&& value) { m_accountIdsHasBeenSet = true; m_accountIds = std::move(value); }
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline GetMembersRequest& WithAccountIds(const Aws::Vector<Aws::String>& value) { SetAccountIds(value); return *this;}
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline GetMembersRequest& WithAccountIds(Aws::Vector<Aws::String>&& value) { SetAccountIds(std::move(value)); return *this;}
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline GetMembersRequest& AddAccountIds(const Aws::String& value) { m_accountIdsHasBeenSet = true; m_accountIds.push_back(value); return *this; }
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline GetMembersRequest& AddAccountIds(Aws::String&& value) { m_accountIdsHasBeenSet = true; m_accountIds.push_back(std::move(value)); return *this; }
/**
* <p>The list of AWS account identifiers for the member account for which to
* return member details.</p> <p>You cannot use <code>GetMembers</code> to retrieve
* information about member accounts that were removed from the behavior graph.</p>
*/
inline GetMembersRequest& AddAccountIds(const char* value) { m_accountIdsHasBeenSet = true; m_accountIds.push_back(value); return *this; }
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
Aws::Vector<Aws::String> m_accountIds;
bool m_accountIdsHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,138 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/detective/model/MemberDetail.h>
#include <aws/detective/model/UnprocessedAccount.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
class AWS_DETECTIVE_API GetMembersResult
{
public:
GetMembersResult();
GetMembersResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
GetMembersResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The member account details that Detective is returning in response to the
* request.</p>
*/
inline const Aws::Vector<MemberDetail>& GetMemberDetails() const{ return m_memberDetails; }
/**
* <p>The member account details that Detective is returning in response to the
* request.</p>
*/
inline void SetMemberDetails(const Aws::Vector<MemberDetail>& value) { m_memberDetails = value; }
/**
* <p>The member account details that Detective is returning in response to the
* request.</p>
*/
inline void SetMemberDetails(Aws::Vector<MemberDetail>&& value) { m_memberDetails = std::move(value); }
/**
* <p>The member account details that Detective is returning in response to the
* request.</p>
*/
inline GetMembersResult& WithMemberDetails(const Aws::Vector<MemberDetail>& value) { SetMemberDetails(value); return *this;}
/**
* <p>The member account details that Detective is returning in response to the
* request.</p>
*/
inline GetMembersResult& WithMemberDetails(Aws::Vector<MemberDetail>&& value) { SetMemberDetails(std::move(value)); return *this;}
/**
* <p>The member account details that Detective is returning in response to the
* request.</p>
*/
inline GetMembersResult& AddMemberDetails(const MemberDetail& value) { m_memberDetails.push_back(value); return *this; }
/**
* <p>The member account details that Detective is returning in response to the
* request.</p>
*/
inline GetMembersResult& AddMemberDetails(MemberDetail&& value) { m_memberDetails.push_back(std::move(value)); return *this; }
/**
* <p>The requested member accounts for which Detective was unable to return member
* details.</p> <p>For each account, provides the reason why the request could not
* be processed.</p>
*/
inline const Aws::Vector<UnprocessedAccount>& GetUnprocessedAccounts() const{ return m_unprocessedAccounts; }
/**
* <p>The requested member accounts for which Detective was unable to return member
* details.</p> <p>For each account, provides the reason why the request could not
* be processed.</p>
*/
inline void SetUnprocessedAccounts(const Aws::Vector<UnprocessedAccount>& value) { m_unprocessedAccounts = value; }
/**
* <p>The requested member accounts for which Detective was unable to return member
* details.</p> <p>For each account, provides the reason why the request could not
* be processed.</p>
*/
inline void SetUnprocessedAccounts(Aws::Vector<UnprocessedAccount>&& value) { m_unprocessedAccounts = std::move(value); }
/**
* <p>The requested member accounts for which Detective was unable to return member
* details.</p> <p>For each account, provides the reason why the request could not
* be processed.</p>
*/
inline GetMembersResult& WithUnprocessedAccounts(const Aws::Vector<UnprocessedAccount>& value) { SetUnprocessedAccounts(value); return *this;}
/**
* <p>The requested member accounts for which Detective was unable to return member
* details.</p> <p>For each account, provides the reason why the request could not
* be processed.</p>
*/
inline GetMembersResult& WithUnprocessedAccounts(Aws::Vector<UnprocessedAccount>&& value) { SetUnprocessedAccounts(std::move(value)); return *this;}
/**
* <p>The requested member accounts for which Detective was unable to return member
* details.</p> <p>For each account, provides the reason why the request could not
* be processed.</p>
*/
inline GetMembersResult& AddUnprocessedAccounts(const UnprocessedAccount& value) { m_unprocessedAccounts.push_back(value); return *this; }
/**
* <p>The requested member accounts for which Detective was unable to return member
* details.</p> <p>For each account, provides the reason why the request could not
* be processed.</p>
*/
inline GetMembersResult& AddUnprocessedAccounts(UnprocessedAccount&& value) { m_unprocessedAccounts.push_back(std::move(value)); return *this; }
private:
Aws::Vector<MemberDetail> m_memberDetails;
Aws::Vector<UnprocessedAccount> m_unprocessedAccounts;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,129 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/core/utils/DateTime.h>
#include <utility>
namespace Aws
{
namespace Utils
{
namespace Json
{
class JsonValue;
class JsonView;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
/**
* <p>A behavior graph in Detective.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/Graph">AWS API
* Reference</a></p>
*/
class AWS_DETECTIVE_API Graph
{
public:
Graph();
Graph(Aws::Utils::Json::JsonView jsonValue);
Graph& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
/**
* <p>The ARN of the behavior graph.</p>
*/
inline const Aws::String& GetArn() const{ return m_arn; }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline void SetArn(const Aws::String& value) { m_arnHasBeenSet = true; m_arn = value; }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline void SetArn(Aws::String&& value) { m_arnHasBeenSet = true; m_arn = std::move(value); }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline void SetArn(const char* value) { m_arnHasBeenSet = true; m_arn.assign(value); }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline Graph& WithArn(const Aws::String& value) { SetArn(value); return *this;}
/**
* <p>The ARN of the behavior graph.</p>
*/
inline Graph& WithArn(Aws::String&& value) { SetArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph.</p>
*/
inline Graph& WithArn(const char* value) { SetArn(value); return *this;}
/**
* <p>The date and time that the behavior graph was created. The value is in
* milliseconds since the epoch.</p>
*/
inline const Aws::Utils::DateTime& GetCreatedTime() const{ return m_createdTime; }
/**
* <p>The date and time that the behavior graph was created. The value is in
* milliseconds since the epoch.</p>
*/
inline bool CreatedTimeHasBeenSet() const { return m_createdTimeHasBeenSet; }
/**
* <p>The date and time that the behavior graph was created. The value is in
* milliseconds since the epoch.</p>
*/
inline void SetCreatedTime(const Aws::Utils::DateTime& value) { m_createdTimeHasBeenSet = true; m_createdTime = value; }
/**
* <p>The date and time that the behavior graph was created. The value is in
* milliseconds since the epoch.</p>
*/
inline void SetCreatedTime(Aws::Utils::DateTime&& value) { m_createdTimeHasBeenSet = true; m_createdTime = std::move(value); }
/**
* <p>The date and time that the behavior graph was created. The value is in
* milliseconds since the epoch.</p>
*/
inline Graph& WithCreatedTime(const Aws::Utils::DateTime& value) { SetCreatedTime(value); return *this;}
/**
* <p>The date and time that the behavior graph was created. The value is in
* milliseconds since the epoch.</p>
*/
inline Graph& WithCreatedTime(Aws::Utils::DateTime&& value) { SetCreatedTime(std::move(value)); return *this;}
private:
Aws::String m_arn;
bool m_arnHasBeenSet;
Aws::Utils::DateTime m_createdTime;
bool m_createdTimeHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // 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/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API ListGraphsRequest : public DetectiveRequest
{
public:
ListGraphsRequest();
// 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 "ListGraphs"; }
Aws::String SerializePayload() const override;
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; }
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; }
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); }
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); }
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline ListGraphsRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline ListGraphsRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>For requests to get the next page of results, the pagination token that was
* returned with the previous set of results. The initial request does not include
* a pagination token.</p>
*/
inline ListGraphsRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;}
/**
* <p>The maximum number of graphs to return at a time. The total must be less than
* the overall limit on the number of results to return, which is currently
* 200.</p>
*/
inline int GetMaxResults() const{ return m_maxResults; }
/**
* <p>The maximum number of graphs to return at a time. The total must be less than
* the overall limit on the number of results to return, which is currently
* 200.</p>
*/
inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; }
/**
* <p>The maximum number of graphs to return at a time. The total must be less than
* the overall limit on the number of results to return, which is currently
* 200.</p>
*/
inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; }
/**
* <p>The maximum number of graphs to return at a time. The total must be less than
* the overall limit on the number of results to return, which is currently
* 200.</p>
*/
inline ListGraphsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;}
private:
Aws::String m_nextToken;
bool m_nextTokenHasBeenSet;
int m_maxResults;
bool m_maxResultsHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,124 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/detective/model/Graph.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
class AWS_DETECTIVE_API ListGraphsResult
{
public:
ListGraphsResult();
ListGraphsResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
ListGraphsResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>A list of behavior graphs that the account is a master for.</p>
*/
inline const Aws::Vector<Graph>& GetGraphList() const{ return m_graphList; }
/**
* <p>A list of behavior graphs that the account is a master for.</p>
*/
inline void SetGraphList(const Aws::Vector<Graph>& value) { m_graphList = value; }
/**
* <p>A list of behavior graphs that the account is a master for.</p>
*/
inline void SetGraphList(Aws::Vector<Graph>&& value) { m_graphList = std::move(value); }
/**
* <p>A list of behavior graphs that the account is a master for.</p>
*/
inline ListGraphsResult& WithGraphList(const Aws::Vector<Graph>& value) { SetGraphList(value); return *this;}
/**
* <p>A list of behavior graphs that the account is a master for.</p>
*/
inline ListGraphsResult& WithGraphList(Aws::Vector<Graph>&& value) { SetGraphList(std::move(value)); return *this;}
/**
* <p>A list of behavior graphs that the account is a master for.</p>
*/
inline ListGraphsResult& AddGraphList(const Graph& value) { m_graphList.push_back(value); return *this; }
/**
* <p>A list of behavior graphs that the account is a master for.</p>
*/
inline ListGraphsResult& AddGraphList(Graph&& value) { m_graphList.push_back(std::move(value)); return *this; }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextToken = value; }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextToken = std::move(value); }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline void SetNextToken(const char* value) { m_nextToken.assign(value); }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline ListGraphsResult& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline ListGraphsResult& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline ListGraphsResult& WithNextToken(const char* value) { SetNextToken(value); return *this;}
private:
Aws::Vector<Graph> m_graphList;
Aws::String m_nextToken;
};
} // namespace Model
} // namespace Detective
} // 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/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API ListInvitationsRequest : public DetectiveRequest
{
public:
ListInvitationsRequest();
// 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 "ListInvitations"; }
Aws::String SerializePayload() const override;
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; }
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; }
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); }
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); }
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline ListInvitationsRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline ListInvitationsRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>For requests to retrieve the next page of results, the pagination token that
* was returned with the previous page of results. The initial request does not
* include a pagination token.</p>
*/
inline ListInvitationsRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;}
/**
* <p>The maximum number of behavior graph invitations to return in the response.
* The total must be less than the overall limit on the number of results to
* return, which is currently 200.</p>
*/
inline int GetMaxResults() const{ return m_maxResults; }
/**
* <p>The maximum number of behavior graph invitations to return in the response.
* The total must be less than the overall limit on the number of results to
* return, which is currently 200.</p>
*/
inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; }
/**
* <p>The maximum number of behavior graph invitations to return in the response.
* The total must be less than the overall limit on the number of results to
* return, which is currently 200.</p>
*/
inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; }
/**
* <p>The maximum number of behavior graph invitations to return in the response.
* The total must be less than the overall limit on the number of results to
* return, which is currently 200.</p>
*/
inline ListInvitationsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;}
private:
Aws::String m_nextToken;
bool m_nextTokenHasBeenSet;
int m_maxResults;
bool m_maxResultsHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // 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/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/detective/model/MemberDetail.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
class AWS_DETECTIVE_API ListInvitationsResult
{
public:
ListInvitationsResult();
ListInvitationsResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
ListInvitationsResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The list of behavior graphs for which the member account has open or accepted
* invitations.</p>
*/
inline const Aws::Vector<MemberDetail>& GetInvitations() const{ return m_invitations; }
/**
* <p>The list of behavior graphs for which the member account has open or accepted
* invitations.</p>
*/
inline void SetInvitations(const Aws::Vector<MemberDetail>& value) { m_invitations = value; }
/**
* <p>The list of behavior graphs for which the member account has open or accepted
* invitations.</p>
*/
inline void SetInvitations(Aws::Vector<MemberDetail>&& value) { m_invitations = std::move(value); }
/**
* <p>The list of behavior graphs for which the member account has open or accepted
* invitations.</p>
*/
inline ListInvitationsResult& WithInvitations(const Aws::Vector<MemberDetail>& value) { SetInvitations(value); return *this;}
/**
* <p>The list of behavior graphs for which the member account has open or accepted
* invitations.</p>
*/
inline ListInvitationsResult& WithInvitations(Aws::Vector<MemberDetail>&& value) { SetInvitations(std::move(value)); return *this;}
/**
* <p>The list of behavior graphs for which the member account has open or accepted
* invitations.</p>
*/
inline ListInvitationsResult& AddInvitations(const MemberDetail& value) { m_invitations.push_back(value); return *this; }
/**
* <p>The list of behavior graphs for which the member account has open or accepted
* invitations.</p>
*/
inline ListInvitationsResult& AddInvitations(MemberDetail&& value) { m_invitations.push_back(std::move(value)); return *this; }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextToken = value; }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextToken = std::move(value); }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline void SetNextToken(const char* value) { m_nextToken.assign(value); }
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline ListInvitationsResult& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline ListInvitationsResult& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>If there are more behavior graphs remaining in the results, then this is the
* pagination token to use to request the next page of behavior graphs.</p>
*/
inline ListInvitationsResult& WithNextToken(const char* value) { SetNextToken(value); return *this;}
private:
Aws::Vector<MemberDetail> m_invitations;
Aws::String m_nextToken;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,183 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API ListMembersRequest : public DetectiveRequest
{
public:
ListMembersRequest();
// 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 "ListMembers"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline ListMembersRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline ListMembersRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph for which to retrieve the list of member
* accounts.</p>
*/
inline ListMembersRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; }
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; }
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); }
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); }
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline ListMembersRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline ListMembersRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>For requests to retrieve the next page of member account results, the
* pagination token that was returned with the previous page of results. The
* initial request does not include a pagination token.</p>
*/
inline ListMembersRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;}
/**
* <p>The maximum number of member accounts to include in the response. The total
* must be less than the overall limit on the number of results to return, which is
* currently 200.</p>
*/
inline int GetMaxResults() const{ return m_maxResults; }
/**
* <p>The maximum number of member accounts to include in the response. The total
* must be less than the overall limit on the number of results to return, which is
* currently 200.</p>
*/
inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; }
/**
* <p>The maximum number of member accounts to include in the response. The total
* must be less than the overall limit on the number of results to return, which is
* currently 200.</p>
*/
inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; }
/**
* <p>The maximum number of member accounts to include in the response. The total
* must be less than the overall limit on the number of results to return, which is
* currently 200.</p>
*/
inline ListMembersRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;}
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
Aws::String m_nextToken;
bool m_nextTokenHasBeenSet;
int m_maxResults;
bool m_maxResultsHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,145 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSVector.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/detective/model/MemberDetail.h>
#include <utility>
namespace Aws
{
template<typename RESULT_TYPE>
class AmazonWebServiceResult;
namespace Utils
{
namespace Json
{
class JsonValue;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
class AWS_DETECTIVE_API ListMembersResult
{
public:
ListMembersResult();
ListMembersResult(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
ListMembersResult& operator=(const Aws::AmazonWebServiceResult<Aws::Utils::Json::JsonValue>& result);
/**
* <p>The list of member accounts in the behavior graph.</p> <p>The results include
* member accounts that did not pass verification and member accounts that have not
* yet accepted the invitation to the behavior graph. The results do not include
* member accounts that were removed from the behavior graph.</p>
*/
inline const Aws::Vector<MemberDetail>& GetMemberDetails() const{ return m_memberDetails; }
/**
* <p>The list of member accounts in the behavior graph.</p> <p>The results include
* member accounts that did not pass verification and member accounts that have not
* yet accepted the invitation to the behavior graph. The results do not include
* member accounts that were removed from the behavior graph.</p>
*/
inline void SetMemberDetails(const Aws::Vector<MemberDetail>& value) { m_memberDetails = value; }
/**
* <p>The list of member accounts in the behavior graph.</p> <p>The results include
* member accounts that did not pass verification and member accounts that have not
* yet accepted the invitation to the behavior graph. The results do not include
* member accounts that were removed from the behavior graph.</p>
*/
inline void SetMemberDetails(Aws::Vector<MemberDetail>&& value) { m_memberDetails = std::move(value); }
/**
* <p>The list of member accounts in the behavior graph.</p> <p>The results include
* member accounts that did not pass verification and member accounts that have not
* yet accepted the invitation to the behavior graph. The results do not include
* member accounts that were removed from the behavior graph.</p>
*/
inline ListMembersResult& WithMemberDetails(const Aws::Vector<MemberDetail>& value) { SetMemberDetails(value); return *this;}
/**
* <p>The list of member accounts in the behavior graph.</p> <p>The results include
* member accounts that did not pass verification and member accounts that have not
* yet accepted the invitation to the behavior graph. The results do not include
* member accounts that were removed from the behavior graph.</p>
*/
inline ListMembersResult& WithMemberDetails(Aws::Vector<MemberDetail>&& value) { SetMemberDetails(std::move(value)); return *this;}
/**
* <p>The list of member accounts in the behavior graph.</p> <p>The results include
* member accounts that did not pass verification and member accounts that have not
* yet accepted the invitation to the behavior graph. The results do not include
* member accounts that were removed from the behavior graph.</p>
*/
inline ListMembersResult& AddMemberDetails(const MemberDetail& value) { m_memberDetails.push_back(value); return *this; }
/**
* <p>The list of member accounts in the behavior graph.</p> <p>The results include
* member accounts that did not pass verification and member accounts that have not
* yet accepted the invitation to the behavior graph. The results do not include
* member accounts that were removed from the behavior graph.</p>
*/
inline ListMembersResult& AddMemberDetails(MemberDetail&& value) { m_memberDetails.push_back(std::move(value)); return *this; }
/**
* <p>If there are more member accounts remaining in the results, then this is the
* pagination token to use to request the next page of member accounts.</p>
*/
inline const Aws::String& GetNextToken() const{ return m_nextToken; }
/**
* <p>If there are more member accounts remaining in the results, then this is the
* pagination token to use to request the next page of member accounts.</p>
*/
inline void SetNextToken(const Aws::String& value) { m_nextToken = value; }
/**
* <p>If there are more member accounts remaining in the results, then this is the
* pagination token to use to request the next page of member accounts.</p>
*/
inline void SetNextToken(Aws::String&& value) { m_nextToken = std::move(value); }
/**
* <p>If there are more member accounts remaining in the results, then this is the
* pagination token to use to request the next page of member accounts.</p>
*/
inline void SetNextToken(const char* value) { m_nextToken.assign(value); }
/**
* <p>If there are more member accounts remaining in the results, then this is the
* pagination token to use to request the next page of member accounts.</p>
*/
inline ListMembersResult& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;}
/**
* <p>If there are more member accounts remaining in the results, then this is the
* pagination token to use to request the next page of member accounts.</p>
*/
inline ListMembersResult& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;}
/**
* <p>If there are more member accounts remaining in the results, then this is the
* pagination token to use to request the next page of member accounts.</p>
*/
inline ListMembersResult& WithNextToken(const char* value) { SetNextToken(value); return *this;}
private:
Aws::Vector<MemberDetail> m_memberDetails;
Aws::String m_nextToken;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,592 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <aws/detective/model/MemberStatus.h>
#include <aws/detective/model/MemberDisabledReason.h>
#include <aws/core/utils/DateTime.h>
#include <utility>
namespace Aws
{
namespace Utils
{
namespace Json
{
class JsonValue;
class JsonView;
} // namespace Json
} // namespace Utils
namespace Detective
{
namespace Model
{
/**
* <p>Details about a member account that was invited to contribute to a behavior
* graph.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/MemberDetail">AWS
* API Reference</a></p>
*/
class AWS_DETECTIVE_API MemberDetail
{
public:
MemberDetail();
MemberDetail(Aws::Utils::Json::JsonView jsonValue);
MemberDetail& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline const Aws::String& GetAccountId() const{ return m_accountId; }
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline bool AccountIdHasBeenSet() const { return m_accountIdHasBeenSet; }
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline void SetAccountId(const Aws::String& value) { m_accountIdHasBeenSet = true; m_accountId = value; }
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline void SetAccountId(Aws::String&& value) { m_accountIdHasBeenSet = true; m_accountId = std::move(value); }
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline void SetAccountId(const char* value) { m_accountIdHasBeenSet = true; m_accountId.assign(value); }
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline MemberDetail& WithAccountId(const Aws::String& value) { SetAccountId(value); return *this;}
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline MemberDetail& WithAccountId(Aws::String&& value) { SetAccountId(std::move(value)); return *this;}
/**
* <p>The AWS account identifier for the member account.</p>
*/
inline MemberDetail& WithAccountId(const char* value) { SetAccountId(value); return *this;}
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline const Aws::String& GetEmailAddress() const{ return m_emailAddress; }
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline bool EmailAddressHasBeenSet() const { return m_emailAddressHasBeenSet; }
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline void SetEmailAddress(const Aws::String& value) { m_emailAddressHasBeenSet = true; m_emailAddress = value; }
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline void SetEmailAddress(Aws::String&& value) { m_emailAddressHasBeenSet = true; m_emailAddress = std::move(value); }
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline void SetEmailAddress(const char* value) { m_emailAddressHasBeenSet = true; m_emailAddress.assign(value); }
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline MemberDetail& WithEmailAddress(const Aws::String& value) { SetEmailAddress(value); return *this;}
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline MemberDetail& WithEmailAddress(Aws::String&& value) { SetEmailAddress(std::move(value)); return *this;}
/**
* <p>The AWS account root user email address for the member account.</p>
*/
inline MemberDetail& WithEmailAddress(const char* value) { SetEmailAddress(value); return *this;}
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline MemberDetail& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline MemberDetail& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph that the member account was invited to.</p>
*/
inline MemberDetail& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline const Aws::String& GetMasterId() const{ return m_masterId; }
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline bool MasterIdHasBeenSet() const { return m_masterIdHasBeenSet; }
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline void SetMasterId(const Aws::String& value) { m_masterIdHasBeenSet = true; m_masterId = value; }
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline void SetMasterId(Aws::String&& value) { m_masterIdHasBeenSet = true; m_masterId = std::move(value); }
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline void SetMasterId(const char* value) { m_masterIdHasBeenSet = true; m_masterId.assign(value); }
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline MemberDetail& WithMasterId(const Aws::String& value) { SetMasterId(value); return *this;}
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline MemberDetail& WithMasterId(Aws::String&& value) { SetMasterId(std::move(value)); return *this;}
/**
* <p>The AWS account identifier of the master account for the behavior graph.</p>
*/
inline MemberDetail& WithMasterId(const char* value) { SetMasterId(value); return *this;}
/**
* <p>The current membership status of the member account. The status can have one
* of the following values:</p> <ul> <li> <p> <code>INVITED</code> - Indicates that
* the member was sent an invitation but has not yet responded.</p> </li> <li> <p>
* <code>VERIFICATION_IN_PROGRESS</code> - Indicates that Detective is verifying
* that the account identifier and email address provided for the member account
* match. If they do match, then Detective sends the invitation. If the email
* address and account identifier don't match, then the member cannot be added to
* the behavior graph.</p> </li> <li> <p> <code>VERIFICATION_FAILED</code> -
* Indicates that the account and email address provided for the member account do
* not match, and Detective did not send an invitation to the account.</p> </li>
* <li> <p> <code>ENABLED</code> - Indicates that the member account accepted the
* invitation to contribute to the behavior graph.</p> </li> <li> <p>
* <code>ACCEPTED_BUT_DISABLED</code> - Indicates that the member account accepted
* the invitation but is prevented from contributing data to the behavior graph.
* <code>DisabledReason</code> provides the reason why the member account is not
* enabled.</p> </li> </ul> <p>Member accounts that declined an invitation or that
* were removed from the behavior graph are not included.</p>
*/
inline const MemberStatus& GetStatus() const{ return m_status; }
/**
* <p>The current membership status of the member account. The status can have one
* of the following values:</p> <ul> <li> <p> <code>INVITED</code> - Indicates that
* the member was sent an invitation but has not yet responded.</p> </li> <li> <p>
* <code>VERIFICATION_IN_PROGRESS</code> - Indicates that Detective is verifying
* that the account identifier and email address provided for the member account
* match. If they do match, then Detective sends the invitation. If the email
* address and account identifier don't match, then the member cannot be added to
* the behavior graph.</p> </li> <li> <p> <code>VERIFICATION_FAILED</code> -
* Indicates that the account and email address provided for the member account do
* not match, and Detective did not send an invitation to the account.</p> </li>
* <li> <p> <code>ENABLED</code> - Indicates that the member account accepted the
* invitation to contribute to the behavior graph.</p> </li> <li> <p>
* <code>ACCEPTED_BUT_DISABLED</code> - Indicates that the member account accepted
* the invitation but is prevented from contributing data to the behavior graph.
* <code>DisabledReason</code> provides the reason why the member account is not
* enabled.</p> </li> </ul> <p>Member accounts that declined an invitation or that
* were removed from the behavior graph are not included.</p>
*/
inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
/**
* <p>The current membership status of the member account. The status can have one
* of the following values:</p> <ul> <li> <p> <code>INVITED</code> - Indicates that
* the member was sent an invitation but has not yet responded.</p> </li> <li> <p>
* <code>VERIFICATION_IN_PROGRESS</code> - Indicates that Detective is verifying
* that the account identifier and email address provided for the member account
* match. If they do match, then Detective sends the invitation. If the email
* address and account identifier don't match, then the member cannot be added to
* the behavior graph.</p> </li> <li> <p> <code>VERIFICATION_FAILED</code> -
* Indicates that the account and email address provided for the member account do
* not match, and Detective did not send an invitation to the account.</p> </li>
* <li> <p> <code>ENABLED</code> - Indicates that the member account accepted the
* invitation to contribute to the behavior graph.</p> </li> <li> <p>
* <code>ACCEPTED_BUT_DISABLED</code> - Indicates that the member account accepted
* the invitation but is prevented from contributing data to the behavior graph.
* <code>DisabledReason</code> provides the reason why the member account is not
* enabled.</p> </li> </ul> <p>Member accounts that declined an invitation or that
* were removed from the behavior graph are not included.</p>
*/
inline void SetStatus(const MemberStatus& value) { m_statusHasBeenSet = true; m_status = value; }
/**
* <p>The current membership status of the member account. The status can have one
* of the following values:</p> <ul> <li> <p> <code>INVITED</code> - Indicates that
* the member was sent an invitation but has not yet responded.</p> </li> <li> <p>
* <code>VERIFICATION_IN_PROGRESS</code> - Indicates that Detective is verifying
* that the account identifier and email address provided for the member account
* match. If they do match, then Detective sends the invitation. If the email
* address and account identifier don't match, then the member cannot be added to
* the behavior graph.</p> </li> <li> <p> <code>VERIFICATION_FAILED</code> -
* Indicates that the account and email address provided for the member account do
* not match, and Detective did not send an invitation to the account.</p> </li>
* <li> <p> <code>ENABLED</code> - Indicates that the member account accepted the
* invitation to contribute to the behavior graph.</p> </li> <li> <p>
* <code>ACCEPTED_BUT_DISABLED</code> - Indicates that the member account accepted
* the invitation but is prevented from contributing data to the behavior graph.
* <code>DisabledReason</code> provides the reason why the member account is not
* enabled.</p> </li> </ul> <p>Member accounts that declined an invitation or that
* were removed from the behavior graph are not included.</p>
*/
inline void SetStatus(MemberStatus&& value) { m_statusHasBeenSet = true; m_status = std::move(value); }
/**
* <p>The current membership status of the member account. The status can have one
* of the following values:</p> <ul> <li> <p> <code>INVITED</code> - Indicates that
* the member was sent an invitation but has not yet responded.</p> </li> <li> <p>
* <code>VERIFICATION_IN_PROGRESS</code> - Indicates that Detective is verifying
* that the account identifier and email address provided for the member account
* match. If they do match, then Detective sends the invitation. If the email
* address and account identifier don't match, then the member cannot be added to
* the behavior graph.</p> </li> <li> <p> <code>VERIFICATION_FAILED</code> -
* Indicates that the account and email address provided for the member account do
* not match, and Detective did not send an invitation to the account.</p> </li>
* <li> <p> <code>ENABLED</code> - Indicates that the member account accepted the
* invitation to contribute to the behavior graph.</p> </li> <li> <p>
* <code>ACCEPTED_BUT_DISABLED</code> - Indicates that the member account accepted
* the invitation but is prevented from contributing data to the behavior graph.
* <code>DisabledReason</code> provides the reason why the member account is not
* enabled.</p> </li> </ul> <p>Member accounts that declined an invitation or that
* were removed from the behavior graph are not included.</p>
*/
inline MemberDetail& WithStatus(const MemberStatus& value) { SetStatus(value); return *this;}
/**
* <p>The current membership status of the member account. The status can have one
* of the following values:</p> <ul> <li> <p> <code>INVITED</code> - Indicates that
* the member was sent an invitation but has not yet responded.</p> </li> <li> <p>
* <code>VERIFICATION_IN_PROGRESS</code> - Indicates that Detective is verifying
* that the account identifier and email address provided for the member account
* match. If they do match, then Detective sends the invitation. If the email
* address and account identifier don't match, then the member cannot be added to
* the behavior graph.</p> </li> <li> <p> <code>VERIFICATION_FAILED</code> -
* Indicates that the account and email address provided for the member account do
* not match, and Detective did not send an invitation to the account.</p> </li>
* <li> <p> <code>ENABLED</code> - Indicates that the member account accepted the
* invitation to contribute to the behavior graph.</p> </li> <li> <p>
* <code>ACCEPTED_BUT_DISABLED</code> - Indicates that the member account accepted
* the invitation but is prevented from contributing data to the behavior graph.
* <code>DisabledReason</code> provides the reason why the member account is not
* enabled.</p> </li> </ul> <p>Member accounts that declined an invitation or that
* were removed from the behavior graph are not included.</p>
*/
inline MemberDetail& WithStatus(MemberStatus&& value) { SetStatus(std::move(value)); return *this;}
/**
* <p>For member accounts with a status of <code>ACCEPTED_BUT_DISABLED</code>, the
* reason that the member account is not enabled.</p> <p>The reason can have one of
* the following values:</p> <ul> <li> <p> <code>VOLUME_TOO_HIGH</code> - Indicates
* that adding the member account would cause the data volume for the behavior
* graph to be too high.</p> </li> <li> <p> <code>VOLUME_UNKNOWN</code> - Indicates
* that Detective is unable to verify the data volume for the member account. This
* is usually because the member account is not enrolled in Amazon GuardDuty. </p>
* </li> </ul>
*/
inline const MemberDisabledReason& GetDisabledReason() const{ return m_disabledReason; }
/**
* <p>For member accounts with a status of <code>ACCEPTED_BUT_DISABLED</code>, the
* reason that the member account is not enabled.</p> <p>The reason can have one of
* the following values:</p> <ul> <li> <p> <code>VOLUME_TOO_HIGH</code> - Indicates
* that adding the member account would cause the data volume for the behavior
* graph to be too high.</p> </li> <li> <p> <code>VOLUME_UNKNOWN</code> - Indicates
* that Detective is unable to verify the data volume for the member account. This
* is usually because the member account is not enrolled in Amazon GuardDuty. </p>
* </li> </ul>
*/
inline bool DisabledReasonHasBeenSet() const { return m_disabledReasonHasBeenSet; }
/**
* <p>For member accounts with a status of <code>ACCEPTED_BUT_DISABLED</code>, the
* reason that the member account is not enabled.</p> <p>The reason can have one of
* the following values:</p> <ul> <li> <p> <code>VOLUME_TOO_HIGH</code> - Indicates
* that adding the member account would cause the data volume for the behavior
* graph to be too high.</p> </li> <li> <p> <code>VOLUME_UNKNOWN</code> - Indicates
* that Detective is unable to verify the data volume for the member account. This
* is usually because the member account is not enrolled in Amazon GuardDuty. </p>
* </li> </ul>
*/
inline void SetDisabledReason(const MemberDisabledReason& value) { m_disabledReasonHasBeenSet = true; m_disabledReason = value; }
/**
* <p>For member accounts with a status of <code>ACCEPTED_BUT_DISABLED</code>, the
* reason that the member account is not enabled.</p> <p>The reason can have one of
* the following values:</p> <ul> <li> <p> <code>VOLUME_TOO_HIGH</code> - Indicates
* that adding the member account would cause the data volume for the behavior
* graph to be too high.</p> </li> <li> <p> <code>VOLUME_UNKNOWN</code> - Indicates
* that Detective is unable to verify the data volume for the member account. This
* is usually because the member account is not enrolled in Amazon GuardDuty. </p>
* </li> </ul>
*/
inline void SetDisabledReason(MemberDisabledReason&& value) { m_disabledReasonHasBeenSet = true; m_disabledReason = std::move(value); }
/**
* <p>For member accounts with a status of <code>ACCEPTED_BUT_DISABLED</code>, the
* reason that the member account is not enabled.</p> <p>The reason can have one of
* the following values:</p> <ul> <li> <p> <code>VOLUME_TOO_HIGH</code> - Indicates
* that adding the member account would cause the data volume for the behavior
* graph to be too high.</p> </li> <li> <p> <code>VOLUME_UNKNOWN</code> - Indicates
* that Detective is unable to verify the data volume for the member account. This
* is usually because the member account is not enrolled in Amazon GuardDuty. </p>
* </li> </ul>
*/
inline MemberDetail& WithDisabledReason(const MemberDisabledReason& value) { SetDisabledReason(value); return *this;}
/**
* <p>For member accounts with a status of <code>ACCEPTED_BUT_DISABLED</code>, the
* reason that the member account is not enabled.</p> <p>The reason can have one of
* the following values:</p> <ul> <li> <p> <code>VOLUME_TOO_HIGH</code> - Indicates
* that adding the member account would cause the data volume for the behavior
* graph to be too high.</p> </li> <li> <p> <code>VOLUME_UNKNOWN</code> - Indicates
* that Detective is unable to verify the data volume for the member account. This
* is usually because the member account is not enrolled in Amazon GuardDuty. </p>
* </li> </ul>
*/
inline MemberDetail& WithDisabledReason(MemberDisabledReason&& value) { SetDisabledReason(std::move(value)); return *this;}
/**
* <p>The date and time that Detective sent the invitation to the member account.
* The value is in milliseconds since the epoch.</p>
*/
inline const Aws::Utils::DateTime& GetInvitedTime() const{ return m_invitedTime; }
/**
* <p>The date and time that Detective sent the invitation to the member account.
* The value is in milliseconds since the epoch.</p>
*/
inline bool InvitedTimeHasBeenSet() const { return m_invitedTimeHasBeenSet; }
/**
* <p>The date and time that Detective sent the invitation to the member account.
* The value is in milliseconds since the epoch.</p>
*/
inline void SetInvitedTime(const Aws::Utils::DateTime& value) { m_invitedTimeHasBeenSet = true; m_invitedTime = value; }
/**
* <p>The date and time that Detective sent the invitation to the member account.
* The value is in milliseconds since the epoch.</p>
*/
inline void SetInvitedTime(Aws::Utils::DateTime&& value) { m_invitedTimeHasBeenSet = true; m_invitedTime = std::move(value); }
/**
* <p>The date and time that Detective sent the invitation to the member account.
* The value is in milliseconds since the epoch.</p>
*/
inline MemberDetail& WithInvitedTime(const Aws::Utils::DateTime& value) { SetInvitedTime(value); return *this;}
/**
* <p>The date and time that Detective sent the invitation to the member account.
* The value is in milliseconds since the epoch.</p>
*/
inline MemberDetail& WithInvitedTime(Aws::Utils::DateTime&& value) { SetInvitedTime(std::move(value)); return *this;}
/**
* <p>The date and time that the member account was last updated. The value is in
* milliseconds since the epoch.</p>
*/
inline const Aws::Utils::DateTime& GetUpdatedTime() const{ return m_updatedTime; }
/**
* <p>The date and time that the member account was last updated. The value is in
* milliseconds since the epoch.</p>
*/
inline bool UpdatedTimeHasBeenSet() const { return m_updatedTimeHasBeenSet; }
/**
* <p>The date and time that the member account was last updated. The value is in
* milliseconds since the epoch.</p>
*/
inline void SetUpdatedTime(const Aws::Utils::DateTime& value) { m_updatedTimeHasBeenSet = true; m_updatedTime = value; }
/**
* <p>The date and time that the member account was last updated. The value is in
* milliseconds since the epoch.</p>
*/
inline void SetUpdatedTime(Aws::Utils::DateTime&& value) { m_updatedTimeHasBeenSet = true; m_updatedTime = std::move(value); }
/**
* <p>The date and time that the member account was last updated. The value is in
* milliseconds since the epoch.</p>
*/
inline MemberDetail& WithUpdatedTime(const Aws::Utils::DateTime& value) { SetUpdatedTime(value); return *this;}
/**
* <p>The date and time that the member account was last updated. The value is in
* milliseconds since the epoch.</p>
*/
inline MemberDetail& WithUpdatedTime(Aws::Utils::DateTime&& value) { SetUpdatedTime(std::move(value)); return *this;}
/**
* <p>The member account data volume as a percentage of the maximum allowed data
* volume. 0 indicates 0 percent, and 100 indicates 100 percent.</p> <p>Note that
* this is not the percentage of the behavior graph data volume.</p> <p>For
* example, the data volume for the behavior graph is 80 GB per day. The maximum
* data volume is 160 GB per day. If the data volume for the member account is 40
* GB per day, then <code>PercentOfGraphUtilization</code> is 25. It represents 25%
* of the maximum allowed data volume. </p>
*/
inline double GetPercentOfGraphUtilization() const{ return m_percentOfGraphUtilization; }
/**
* <p>The member account data volume as a percentage of the maximum allowed data
* volume. 0 indicates 0 percent, and 100 indicates 100 percent.</p> <p>Note that
* this is not the percentage of the behavior graph data volume.</p> <p>For
* example, the data volume for the behavior graph is 80 GB per day. The maximum
* data volume is 160 GB per day. If the data volume for the member account is 40
* GB per day, then <code>PercentOfGraphUtilization</code> is 25. It represents 25%
* of the maximum allowed data volume. </p>
*/
inline bool PercentOfGraphUtilizationHasBeenSet() const { return m_percentOfGraphUtilizationHasBeenSet; }
/**
* <p>The member account data volume as a percentage of the maximum allowed data
* volume. 0 indicates 0 percent, and 100 indicates 100 percent.</p> <p>Note that
* this is not the percentage of the behavior graph data volume.</p> <p>For
* example, the data volume for the behavior graph is 80 GB per day. The maximum
* data volume is 160 GB per day. If the data volume for the member account is 40
* GB per day, then <code>PercentOfGraphUtilization</code> is 25. It represents 25%
* of the maximum allowed data volume. </p>
*/
inline void SetPercentOfGraphUtilization(double value) { m_percentOfGraphUtilizationHasBeenSet = true; m_percentOfGraphUtilization = value; }
/**
* <p>The member account data volume as a percentage of the maximum allowed data
* volume. 0 indicates 0 percent, and 100 indicates 100 percent.</p> <p>Note that
* this is not the percentage of the behavior graph data volume.</p> <p>For
* example, the data volume for the behavior graph is 80 GB per day. The maximum
* data volume is 160 GB per day. If the data volume for the member account is 40
* GB per day, then <code>PercentOfGraphUtilization</code> is 25. It represents 25%
* of the maximum allowed data volume. </p>
*/
inline MemberDetail& WithPercentOfGraphUtilization(double value) { SetPercentOfGraphUtilization(value); return *this;}
/**
* <p>The date and time when the graph utilization percentage was last updated.</p>
*/
inline const Aws::Utils::DateTime& GetPercentOfGraphUtilizationUpdatedTime() const{ return m_percentOfGraphUtilizationUpdatedTime; }
/**
* <p>The date and time when the graph utilization percentage was last updated.</p>
*/
inline bool PercentOfGraphUtilizationUpdatedTimeHasBeenSet() const { return m_percentOfGraphUtilizationUpdatedTimeHasBeenSet; }
/**
* <p>The date and time when the graph utilization percentage was last updated.</p>
*/
inline void SetPercentOfGraphUtilizationUpdatedTime(const Aws::Utils::DateTime& value) { m_percentOfGraphUtilizationUpdatedTimeHasBeenSet = true; m_percentOfGraphUtilizationUpdatedTime = value; }
/**
* <p>The date and time when the graph utilization percentage was last updated.</p>
*/
inline void SetPercentOfGraphUtilizationUpdatedTime(Aws::Utils::DateTime&& value) { m_percentOfGraphUtilizationUpdatedTimeHasBeenSet = true; m_percentOfGraphUtilizationUpdatedTime = std::move(value); }
/**
* <p>The date and time when the graph utilization percentage was last updated.</p>
*/
inline MemberDetail& WithPercentOfGraphUtilizationUpdatedTime(const Aws::Utils::DateTime& value) { SetPercentOfGraphUtilizationUpdatedTime(value); return *this;}
/**
* <p>The date and time when the graph utilization percentage was last updated.</p>
*/
inline MemberDetail& WithPercentOfGraphUtilizationUpdatedTime(Aws::Utils::DateTime&& value) { SetPercentOfGraphUtilizationUpdatedTime(std::move(value)); return *this;}
private:
Aws::String m_accountId;
bool m_accountIdHasBeenSet;
Aws::String m_emailAddress;
bool m_emailAddressHasBeenSet;
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
Aws::String m_masterId;
bool m_masterIdHasBeenSet;
MemberStatus m_status;
bool m_statusHasBeenSet;
MemberDisabledReason m_disabledReason;
bool m_disabledReasonHasBeenSet;
Aws::Utils::DateTime m_invitedTime;
bool m_invitedTimeHasBeenSet;
Aws::Utils::DateTime m_updatedTime;
bool m_updatedTimeHasBeenSet;
double m_percentOfGraphUtilization;
bool m_percentOfGraphUtilizationHasBeenSet;
Aws::Utils::DateTime m_percentOfGraphUtilizationUpdatedTime;
bool m_percentOfGraphUtilizationUpdatedTimeHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,31 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
namespace Aws
{
namespace Detective
{
namespace Model
{
enum class MemberDisabledReason
{
NOT_SET,
VOLUME_TOO_HIGH,
VOLUME_UNKNOWN
};
namespace MemberDisabledReasonMapper
{
AWS_DETECTIVE_API MemberDisabledReason GetMemberDisabledReasonForName(const Aws::String& name);
AWS_DETECTIVE_API Aws::String GetNameForMemberDisabledReason(MemberDisabledReason value);
} // namespace MemberDisabledReasonMapper
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,34 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/core/utils/memory/stl/AWSString.h>
namespace Aws
{
namespace Detective
{
namespace Model
{
enum class MemberStatus
{
NOT_SET,
INVITED,
VERIFICATION_IN_PROGRESS,
VERIFICATION_FAILED,
ENABLED,
ACCEPTED_BUT_DISABLED
};
namespace MemberStatusMapper
{
AWS_DETECTIVE_API MemberStatus GetMemberStatusForName(const Aws::String& name);
AWS_DETECTIVE_API Aws::String GetNameForMemberStatus(MemberStatus value);
} // namespace MemberStatusMapper
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,99 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API RejectInvitationRequest : public DetectiveRequest
{
public:
RejectInvitationRequest();
// 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 "RejectInvitation"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline RejectInvitationRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline RejectInvitationRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph to reject the invitation to.</p> <p>The member
* account's current member status in the behavior graph must be
* <code>INVITED</code>.</p>
*/
inline RejectInvitationRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,143 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_EXPORTS.h>
#include <aws/detective/DetectiveRequest.h>
#include <aws/core/utils/memory/stl/AWSString.h>
#include <utility>
namespace Aws
{
namespace Detective
{
namespace Model
{
/**
*/
class AWS_DETECTIVE_API StartMonitoringMemberRequest : public DetectiveRequest
{
public:
StartMonitoringMemberRequest();
// 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 "StartMonitoringMember"; }
Aws::String SerializePayload() const override;
/**
* <p>The ARN of the behavior graph.</p>
*/
inline const Aws::String& GetGraphArn() const{ return m_graphArn; }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline bool GraphArnHasBeenSet() const { return m_graphArnHasBeenSet; }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline void SetGraphArn(const Aws::String& value) { m_graphArnHasBeenSet = true; m_graphArn = value; }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline void SetGraphArn(Aws::String&& value) { m_graphArnHasBeenSet = true; m_graphArn = std::move(value); }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline void SetGraphArn(const char* value) { m_graphArnHasBeenSet = true; m_graphArn.assign(value); }
/**
* <p>The ARN of the behavior graph.</p>
*/
inline StartMonitoringMemberRequest& WithGraphArn(const Aws::String& value) { SetGraphArn(value); return *this;}
/**
* <p>The ARN of the behavior graph.</p>
*/
inline StartMonitoringMemberRequest& WithGraphArn(Aws::String&& value) { SetGraphArn(std::move(value)); return *this;}
/**
* <p>The ARN of the behavior graph.</p>
*/
inline StartMonitoringMemberRequest& WithGraphArn(const char* value) { SetGraphArn(value); return *this;}
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline const Aws::String& GetAccountId() const{ return m_accountId; }
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline bool AccountIdHasBeenSet() const { return m_accountIdHasBeenSet; }
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline void SetAccountId(const Aws::String& value) { m_accountIdHasBeenSet = true; m_accountId = value; }
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline void SetAccountId(Aws::String&& value) { m_accountIdHasBeenSet = true; m_accountId = std::move(value); }
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline void SetAccountId(const char* value) { m_accountIdHasBeenSet = true; m_accountId.assign(value); }
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline StartMonitoringMemberRequest& WithAccountId(const Aws::String& value) { SetAccountId(value); return *this;}
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline StartMonitoringMemberRequest& WithAccountId(Aws::String&& value) { SetAccountId(std::move(value)); return *this;}
/**
* <p>The account ID of the member account to try to enable.</p> <p>The account
* must be an invited member account with a status of
* <code>ACCEPTED_BUT_DISABLED</code>. </p>
*/
inline StartMonitoringMemberRequest& WithAccountId(const char* value) { SetAccountId(value); return *this;}
private:
Aws::String m_graphArn;
bool m_graphArnHasBeenSet;
Aws::String m_accountId;
bool m_accountIdHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,133 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include <aws/detective/Detective_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 Detective
{
namespace Model
{
/**
* <p>A member account that was included in a request but for which the request
* could not be processed.</p><p><h3>See Also:</h3> <a
* href="http://docs.aws.amazon.com/goto/WebAPI/detective-2018-10-26/UnprocessedAccount">AWS
* API Reference</a></p>
*/
class AWS_DETECTIVE_API UnprocessedAccount
{
public:
UnprocessedAccount();
UnprocessedAccount(Aws::Utils::Json::JsonView jsonValue);
UnprocessedAccount& operator=(Aws::Utils::Json::JsonView jsonValue);
Aws::Utils::Json::JsonValue Jsonize() const;
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline const Aws::String& GetAccountId() const{ return m_accountId; }
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline bool AccountIdHasBeenSet() const { return m_accountIdHasBeenSet; }
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline void SetAccountId(const Aws::String& value) { m_accountIdHasBeenSet = true; m_accountId = value; }
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline void SetAccountId(Aws::String&& value) { m_accountIdHasBeenSet = true; m_accountId = std::move(value); }
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline void SetAccountId(const char* value) { m_accountIdHasBeenSet = true; m_accountId.assign(value); }
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline UnprocessedAccount& WithAccountId(const Aws::String& value) { SetAccountId(value); return *this;}
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline UnprocessedAccount& WithAccountId(Aws::String&& value) { SetAccountId(std::move(value)); return *this;}
/**
* <p>The AWS account identifier of the member account that was not processed.</p>
*/
inline UnprocessedAccount& WithAccountId(const char* value) { SetAccountId(value); return *this;}
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline const Aws::String& GetReason() const{ return m_reason; }
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline bool ReasonHasBeenSet() const { return m_reasonHasBeenSet; }
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline void SetReason(const Aws::String& value) { m_reasonHasBeenSet = true; m_reason = value; }
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline void SetReason(Aws::String&& value) { m_reasonHasBeenSet = true; m_reason = std::move(value); }
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline void SetReason(const char* value) { m_reasonHasBeenSet = true; m_reason.assign(value); }
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline UnprocessedAccount& WithReason(const Aws::String& value) { SetReason(value); return *this;}
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline UnprocessedAccount& WithReason(Aws::String&& value) { SetReason(std::move(value)); return *this;}
/**
* <p>The reason that the member account request could not be processed.</p>
*/
inline UnprocessedAccount& WithReason(const char* value) { SetReason(value); return *this;}
private:
Aws::String m_accountId;
bool m_accountIdHasBeenSet;
Aws::String m_reason;
bool m_reasonHasBeenSet;
};
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,429 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/core/utils/Outcome.h>
#include <aws/core/auth/AWSAuthSigner.h>
#include <aws/core/client/CoreErrors.h>
#include <aws/core/client/RetryStrategy.h>
#include <aws/core/http/HttpClient.h>
#include <aws/core/http/HttpResponse.h>
#include <aws/core/http/HttpClientFactory.h>
#include <aws/core/auth/AWSCredentialsProviderChain.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/utils/memory/stl/AWSStringStream.h>
#include <aws/core/utils/threading/Executor.h>
#include <aws/core/utils/DNS.h>
#include <aws/core/utils/logging/LogMacros.h>
#include <aws/detective/DetectiveClient.h>
#include <aws/detective/DetectiveEndpoint.h>
#include <aws/detective/DetectiveErrorMarshaller.h>
#include <aws/detective/model/AcceptInvitationRequest.h>
#include <aws/detective/model/CreateMembersRequest.h>
#include <aws/detective/model/DeleteGraphRequest.h>
#include <aws/detective/model/DeleteMembersRequest.h>
#include <aws/detective/model/DisassociateMembershipRequest.h>
#include <aws/detective/model/GetMembersRequest.h>
#include <aws/detective/model/ListGraphsRequest.h>
#include <aws/detective/model/ListInvitationsRequest.h>
#include <aws/detective/model/ListMembersRequest.h>
#include <aws/detective/model/RejectInvitationRequest.h>
#include <aws/detective/model/StartMonitoringMemberRequest.h>
using namespace Aws;
using namespace Aws::Auth;
using namespace Aws::Client;
using namespace Aws::Detective;
using namespace Aws::Detective::Model;
using namespace Aws::Http;
using namespace Aws::Utils::Json;
static const char* SERVICE_NAME = "detective";
static const char* ALLOCATION_TAG = "DetectiveClient";
DetectiveClient::DetectiveClient(const Client::ClientConfiguration& clientConfiguration) :
BASECLASS(clientConfiguration,
Aws::MakeShared<AWSAuthV4Signer>(ALLOCATION_TAG, Aws::MakeShared<DefaultAWSCredentialsProviderChain>(ALLOCATION_TAG),
SERVICE_NAME, Aws::Region::ComputeSignerRegion(clientConfiguration.region)),
Aws::MakeShared<DetectiveErrorMarshaller>(ALLOCATION_TAG)),
m_executor(clientConfiguration.executor)
{
init(clientConfiguration);
}
DetectiveClient::DetectiveClient(const AWSCredentials& credentials, const Client::ClientConfiguration& clientConfiguration) :
BASECLASS(clientConfiguration,
Aws::MakeShared<AWSAuthV4Signer>(ALLOCATION_TAG, Aws::MakeShared<SimpleAWSCredentialsProvider>(ALLOCATION_TAG, credentials),
SERVICE_NAME, Aws::Region::ComputeSignerRegion(clientConfiguration.region)),
Aws::MakeShared<DetectiveErrorMarshaller>(ALLOCATION_TAG)),
m_executor(clientConfiguration.executor)
{
init(clientConfiguration);
}
DetectiveClient::DetectiveClient(const std::shared_ptr<AWSCredentialsProvider>& credentialsProvider,
const Client::ClientConfiguration& clientConfiguration) :
BASECLASS(clientConfiguration,
Aws::MakeShared<AWSAuthV4Signer>(ALLOCATION_TAG, credentialsProvider,
SERVICE_NAME, Aws::Region::ComputeSignerRegion(clientConfiguration.region)),
Aws::MakeShared<DetectiveErrorMarshaller>(ALLOCATION_TAG)),
m_executor(clientConfiguration.executor)
{
init(clientConfiguration);
}
DetectiveClient::~DetectiveClient()
{
}
void DetectiveClient::init(const ClientConfiguration& config)
{
SetServiceClientName("Detective");
m_configScheme = SchemeMapper::ToString(config.scheme);
if (config.endpointOverride.empty())
{
m_uri = m_configScheme + "://" + DetectiveEndpoint::ForRegion(config.region, config.useDualStack);
}
else
{
OverrideEndpoint(config.endpointOverride);
}
}
void DetectiveClient::OverrideEndpoint(const Aws::String& endpoint)
{
if (endpoint.compare(0, 7, "http://") == 0 || endpoint.compare(0, 8, "https://") == 0)
{
m_uri = endpoint;
}
else
{
m_uri = m_configScheme + "://" + endpoint;
}
}
AcceptInvitationOutcome DetectiveClient::AcceptInvitation(const AcceptInvitationRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/invitation";
uri.SetPath(uri.GetPath() + ss.str());
return AcceptInvitationOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_PUT, Aws::Auth::SIGV4_SIGNER));
}
AcceptInvitationOutcomeCallable DetectiveClient::AcceptInvitationCallable(const AcceptInvitationRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< AcceptInvitationOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->AcceptInvitation(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::AcceptInvitationAsync(const AcceptInvitationRequest& request, const AcceptInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->AcceptInvitationAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::AcceptInvitationAsyncHelper(const AcceptInvitationRequest& request, const AcceptInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, AcceptInvitation(request), context);
}
CreateGraphOutcome DetectiveClient::CreateGraph() const
{
Aws::StringStream ss;
ss << m_uri << "/graph";
return CreateGraphOutcome(MakeRequest(ss.str(), Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER, "CreateGraph"));
}
CreateGraphOutcomeCallable DetectiveClient::CreateGraphCallable() const
{
auto task = Aws::MakeShared< std::packaged_task< CreateGraphOutcome() > >(ALLOCATION_TAG, [this](){ return this->CreateGraph(); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::CreateGraphAsync(const CreateGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, handler, context](){ this->CreateGraphAsyncHelper( handler, context ); } );
}
void DetectiveClient::CreateGraphAsyncHelper(const CreateGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, CreateGraph(), context);
}
CreateMembersOutcome DetectiveClient::CreateMembers(const CreateMembersRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/graph/members";
uri.SetPath(uri.GetPath() + ss.str());
return CreateMembersOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
CreateMembersOutcomeCallable DetectiveClient::CreateMembersCallable(const CreateMembersRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< CreateMembersOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->CreateMembers(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::CreateMembersAsync(const CreateMembersRequest& request, const CreateMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->CreateMembersAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::CreateMembersAsyncHelper(const CreateMembersRequest& request, const CreateMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, CreateMembers(request), context);
}
DeleteGraphOutcome DetectiveClient::DeleteGraph(const DeleteGraphRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/graph/removal";
uri.SetPath(uri.GetPath() + ss.str());
return DeleteGraphOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
DeleteGraphOutcomeCallable DetectiveClient::DeleteGraphCallable(const DeleteGraphRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< DeleteGraphOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->DeleteGraph(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::DeleteGraphAsync(const DeleteGraphRequest& request, const DeleteGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->DeleteGraphAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::DeleteGraphAsyncHelper(const DeleteGraphRequest& request, const DeleteGraphResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, DeleteGraph(request), context);
}
DeleteMembersOutcome DetectiveClient::DeleteMembers(const DeleteMembersRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/graph/members/removal";
uri.SetPath(uri.GetPath() + ss.str());
return DeleteMembersOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
DeleteMembersOutcomeCallable DetectiveClient::DeleteMembersCallable(const DeleteMembersRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< DeleteMembersOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->DeleteMembers(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::DeleteMembersAsync(const DeleteMembersRequest& request, const DeleteMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->DeleteMembersAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::DeleteMembersAsyncHelper(const DeleteMembersRequest& request, const DeleteMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, DeleteMembers(request), context);
}
DisassociateMembershipOutcome DetectiveClient::DisassociateMembership(const DisassociateMembershipRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/membership/removal";
uri.SetPath(uri.GetPath() + ss.str());
return DisassociateMembershipOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
DisassociateMembershipOutcomeCallable DetectiveClient::DisassociateMembershipCallable(const DisassociateMembershipRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< DisassociateMembershipOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->DisassociateMembership(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::DisassociateMembershipAsync(const DisassociateMembershipRequest& request, const DisassociateMembershipResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->DisassociateMembershipAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::DisassociateMembershipAsyncHelper(const DisassociateMembershipRequest& request, const DisassociateMembershipResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, DisassociateMembership(request), context);
}
GetMembersOutcome DetectiveClient::GetMembers(const GetMembersRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/graph/members/get";
uri.SetPath(uri.GetPath() + ss.str());
return GetMembersOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
GetMembersOutcomeCallable DetectiveClient::GetMembersCallable(const GetMembersRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< GetMembersOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->GetMembers(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::GetMembersAsync(const GetMembersRequest& request, const GetMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->GetMembersAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::GetMembersAsyncHelper(const GetMembersRequest& request, const GetMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, GetMembers(request), context);
}
ListGraphsOutcome DetectiveClient::ListGraphs(const ListGraphsRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/graphs/list";
uri.SetPath(uri.GetPath() + ss.str());
return ListGraphsOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
ListGraphsOutcomeCallable DetectiveClient::ListGraphsCallable(const ListGraphsRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< ListGraphsOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->ListGraphs(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::ListGraphsAsync(const ListGraphsRequest& request, const ListGraphsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->ListGraphsAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::ListGraphsAsyncHelper(const ListGraphsRequest& request, const ListGraphsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, ListGraphs(request), context);
}
ListInvitationsOutcome DetectiveClient::ListInvitations(const ListInvitationsRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/invitations/list";
uri.SetPath(uri.GetPath() + ss.str());
return ListInvitationsOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
ListInvitationsOutcomeCallable DetectiveClient::ListInvitationsCallable(const ListInvitationsRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< ListInvitationsOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->ListInvitations(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::ListInvitationsAsync(const ListInvitationsRequest& request, const ListInvitationsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->ListInvitationsAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::ListInvitationsAsyncHelper(const ListInvitationsRequest& request, const ListInvitationsResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, ListInvitations(request), context);
}
ListMembersOutcome DetectiveClient::ListMembers(const ListMembersRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/graph/members/list";
uri.SetPath(uri.GetPath() + ss.str());
return ListMembersOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
ListMembersOutcomeCallable DetectiveClient::ListMembersCallable(const ListMembersRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< ListMembersOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->ListMembers(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::ListMembersAsync(const ListMembersRequest& request, const ListMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->ListMembersAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::ListMembersAsyncHelper(const ListMembersRequest& request, const ListMembersResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, ListMembers(request), context);
}
RejectInvitationOutcome DetectiveClient::RejectInvitation(const RejectInvitationRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/invitation/removal";
uri.SetPath(uri.GetPath() + ss.str());
return RejectInvitationOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
RejectInvitationOutcomeCallable DetectiveClient::RejectInvitationCallable(const RejectInvitationRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< RejectInvitationOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->RejectInvitation(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::RejectInvitationAsync(const RejectInvitationRequest& request, const RejectInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->RejectInvitationAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::RejectInvitationAsyncHelper(const RejectInvitationRequest& request, const RejectInvitationResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, RejectInvitation(request), context);
}
StartMonitoringMemberOutcome DetectiveClient::StartMonitoringMember(const StartMonitoringMemberRequest& request) const
{
Aws::Http::URI uri = m_uri;
Aws::StringStream ss;
ss << "/graph/member/monitoringstate";
uri.SetPath(uri.GetPath() + ss.str());
return StartMonitoringMemberOutcome(MakeRequest(uri, request, Aws::Http::HttpMethod::HTTP_POST, Aws::Auth::SIGV4_SIGNER));
}
StartMonitoringMemberOutcomeCallable DetectiveClient::StartMonitoringMemberCallable(const StartMonitoringMemberRequest& request) const
{
auto task = Aws::MakeShared< std::packaged_task< StartMonitoringMemberOutcome() > >(ALLOCATION_TAG, [this, request](){ return this->StartMonitoringMember(request); } );
auto packagedFunction = [task]() { (*task)(); };
m_executor->Submit(packagedFunction);
return task->get_future();
}
void DetectiveClient::StartMonitoringMemberAsync(const StartMonitoringMemberRequest& request, const StartMonitoringMemberResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
m_executor->Submit( [this, request, handler, context](){ this->StartMonitoringMemberAsyncHelper( request, handler, context ); } );
}
void DetectiveClient::StartMonitoringMemberAsyncHelper(const StartMonitoringMemberRequest& request, const StartMonitoringMemberResponseReceivedHandler& handler, const std::shared_ptr<const Aws::Client::AsyncCallerContext>& context) const
{
handler(this, request, StartMonitoringMember(request), context);
}

View File

@@ -0,0 +1,64 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/DetectiveEndpoint.h>
#include <aws/core/utils/memory/stl/AWSStringStream.h>
#include <aws/core/utils/HashingUtils.h>
using namespace Aws;
using namespace Aws::Detective;
namespace Aws
{
namespace Detective
{
namespace DetectiveEndpoint
{
static const int CN_NORTH_1_HASH = Aws::Utils::HashingUtils::HashString("cn-north-1");
static const int CN_NORTHWEST_1_HASH = Aws::Utils::HashingUtils::HashString("cn-northwest-1");
static const int US_ISO_EAST_1_HASH = Aws::Utils::HashingUtils::HashString("us-iso-east-1");
static const int US_ISOB_EAST_1_HASH = Aws::Utils::HashingUtils::HashString("us-isob-east-1");
Aws::String ForRegion(const Aws::String& regionName, bool useDualStack)
{
// Fallback to us-east-1 if global endpoint does not exists.
Aws::String region = regionName == Aws::Region::AWS_GLOBAL ? Aws::Region::US_EAST_1 : regionName;
auto hash = Aws::Utils::HashingUtils::HashString(region.c_str());
Aws::StringStream ss;
ss << "api.detective" << ".";
if(useDualStack)
{
ss << "dualstack.";
}
ss << region;
if (hash == CN_NORTH_1_HASH || hash == CN_NORTHWEST_1_HASH)
{
ss << ".amazonaws.com.cn";
}
else if (hash == US_ISO_EAST_1_HASH)
{
ss << ".c2s.ic.gov";
}
else if (hash == US_ISOB_EAST_1_HASH)
{
ss << ".sc2s.sgov.gov";
}
else
{
ss << ".amazonaws.com";
}
return ss.str();
}
} // namespace DetectiveEndpoint
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,22 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/core/client/AWSError.h>
#include <aws/detective/DetectiveErrorMarshaller.h>
#include <aws/detective/DetectiveErrors.h>
using namespace Aws::Client;
using namespace Aws::Detective;
AWSError<CoreErrors> DetectiveErrorMarshaller::FindErrorByName(const char* errorName) const
{
AWSError<CoreErrors> error = DetectiveErrorMapper::GetErrorForName(errorName);
if(error.GetErrorType() != CoreErrors::UNKNOWN)
{
return error;
}
return AWSErrorMarshaller::FindErrorByName(errorName);
}

View File

@@ -0,0 +1,47 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/core/client/AWSError.h>
#include <aws/core/utils/HashingUtils.h>
#include <aws/detective/DetectiveErrors.h>
using namespace Aws::Client;
using namespace Aws::Utils;
using namespace Aws::Detective;
namespace Aws
{
namespace Detective
{
namespace DetectiveErrorMapper
{
static const int CONFLICT_HASH = HashingUtils::HashString("ConflictException");
static const int SERVICE_QUOTA_EXCEEDED_HASH = HashingUtils::HashString("ServiceQuotaExceededException");
static const int INTERNAL_SERVER_HASH = HashingUtils::HashString("InternalServerException");
AWSError<CoreErrors> GetErrorForName(const char* errorName)
{
int hashCode = HashingUtils::HashString(errorName);
if (hashCode == CONFLICT_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(DetectiveErrors::CONFLICT), false);
}
else if (hashCode == SERVICE_QUOTA_EXCEEDED_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(DetectiveErrors::SERVICE_QUOTA_EXCEEDED), false);
}
else if (hashCode == INTERNAL_SERVER_HASH)
{
return AWSError<CoreErrors>(static_cast<CoreErrors>(DetectiveErrors::INTERNAL_SERVER), false);
}
return AWSError<CoreErrors>(CoreErrors::UNKNOWN, false);
}
} // namespace DetectiveErrorMapper
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,35 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/AcceptInvitationRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
AcceptInvitationRequest::AcceptInvitationRequest() :
m_graphArnHasBeenSet(false)
{
}
Aws::String AcceptInvitationRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,74 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/Account.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
namespace Aws
{
namespace Detective
{
namespace Model
{
Account::Account() :
m_accountIdHasBeenSet(false),
m_emailAddressHasBeenSet(false)
{
}
Account::Account(JsonView jsonValue) :
m_accountIdHasBeenSet(false),
m_emailAddressHasBeenSet(false)
{
*this = jsonValue;
}
Account& Account::operator =(JsonView jsonValue)
{
if(jsonValue.ValueExists("AccountId"))
{
m_accountId = jsonValue.GetString("AccountId");
m_accountIdHasBeenSet = true;
}
if(jsonValue.ValueExists("EmailAddress"))
{
m_emailAddress = jsonValue.GetString("EmailAddress");
m_emailAddressHasBeenSet = true;
}
return *this;
}
JsonValue Account::Jsonize() const
{
JsonValue payload;
if(m_accountIdHasBeenSet)
{
payload.WithString("AccountId", m_accountId);
}
if(m_emailAddressHasBeenSet)
{
payload.WithString("EmailAddress", m_emailAddress);
}
return payload;
}
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,40 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/CreateGraphResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
CreateGraphResult::CreateGraphResult()
{
}
CreateGraphResult::CreateGraphResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
CreateGraphResult& CreateGraphResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("GraphArn"))
{
m_graphArn = jsonValue.GetString("GraphArn");
}
return *this;
}

View File

@@ -0,0 +1,54 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/CreateMembersRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
CreateMembersRequest::CreateMembersRequest() :
m_graphArnHasBeenSet(false),
m_messageHasBeenSet(false),
m_accountsHasBeenSet(false)
{
}
Aws::String CreateMembersRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
if(m_messageHasBeenSet)
{
payload.WithString("Message", m_message);
}
if(m_accountsHasBeenSet)
{
Array<JsonValue> accountsJsonList(m_accounts.size());
for(unsigned accountsIndex = 0; accountsIndex < accountsJsonList.GetLength(); ++accountsIndex)
{
accountsJsonList[accountsIndex].AsObject(m_accounts[accountsIndex].Jsonize());
}
payload.WithArray("Accounts", std::move(accountsJsonList));
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,52 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/CreateMembersResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
CreateMembersResult::CreateMembersResult()
{
}
CreateMembersResult::CreateMembersResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
CreateMembersResult& CreateMembersResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("Members"))
{
Array<JsonView> membersJsonList = jsonValue.GetArray("Members");
for(unsigned membersIndex = 0; membersIndex < membersJsonList.GetLength(); ++membersIndex)
{
m_members.push_back(membersJsonList[membersIndex].AsObject());
}
}
if(jsonValue.ValueExists("UnprocessedAccounts"))
{
Array<JsonView> unprocessedAccountsJsonList = jsonValue.GetArray("UnprocessedAccounts");
for(unsigned unprocessedAccountsIndex = 0; unprocessedAccountsIndex < unprocessedAccountsJsonList.GetLength(); ++unprocessedAccountsIndex)
{
m_unprocessedAccounts.push_back(unprocessedAccountsJsonList[unprocessedAccountsIndex].AsObject());
}
}
return *this;
}

View File

@@ -0,0 +1,35 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/DeleteGraphRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
DeleteGraphRequest::DeleteGraphRequest() :
m_graphArnHasBeenSet(false)
{
}
Aws::String DeleteGraphRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,47 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/DeleteMembersRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
DeleteMembersRequest::DeleteMembersRequest() :
m_graphArnHasBeenSet(false),
m_accountIdsHasBeenSet(false)
{
}
Aws::String DeleteMembersRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
if(m_accountIdsHasBeenSet)
{
Array<JsonValue> accountIdsJsonList(m_accountIds.size());
for(unsigned accountIdsIndex = 0; accountIdsIndex < accountIdsJsonList.GetLength(); ++accountIdsIndex)
{
accountIdsJsonList[accountIdsIndex].AsString(m_accountIds[accountIdsIndex]);
}
payload.WithArray("AccountIds", std::move(accountIdsJsonList));
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,52 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/DeleteMembersResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
DeleteMembersResult::DeleteMembersResult()
{
}
DeleteMembersResult::DeleteMembersResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
DeleteMembersResult& DeleteMembersResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("AccountIds"))
{
Array<JsonView> accountIdsJsonList = jsonValue.GetArray("AccountIds");
for(unsigned accountIdsIndex = 0; accountIdsIndex < accountIdsJsonList.GetLength(); ++accountIdsIndex)
{
m_accountIds.push_back(accountIdsJsonList[accountIdsIndex].AsString());
}
}
if(jsonValue.ValueExists("UnprocessedAccounts"))
{
Array<JsonView> unprocessedAccountsJsonList = jsonValue.GetArray("UnprocessedAccounts");
for(unsigned unprocessedAccountsIndex = 0; unprocessedAccountsIndex < unprocessedAccountsJsonList.GetLength(); ++unprocessedAccountsIndex)
{
m_unprocessedAccounts.push_back(unprocessedAccountsJsonList[unprocessedAccountsIndex].AsObject());
}
}
return *this;
}

View File

@@ -0,0 +1,35 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/DisassociateMembershipRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
DisassociateMembershipRequest::DisassociateMembershipRequest() :
m_graphArnHasBeenSet(false)
{
}
Aws::String DisassociateMembershipRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,47 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/GetMembersRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
GetMembersRequest::GetMembersRequest() :
m_graphArnHasBeenSet(false),
m_accountIdsHasBeenSet(false)
{
}
Aws::String GetMembersRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
if(m_accountIdsHasBeenSet)
{
Array<JsonValue> accountIdsJsonList(m_accountIds.size());
for(unsigned accountIdsIndex = 0; accountIdsIndex < accountIdsJsonList.GetLength(); ++accountIdsIndex)
{
accountIdsJsonList[accountIdsIndex].AsString(m_accountIds[accountIdsIndex]);
}
payload.WithArray("AccountIds", std::move(accountIdsJsonList));
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,52 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/GetMembersResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
GetMembersResult::GetMembersResult()
{
}
GetMembersResult::GetMembersResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
GetMembersResult& GetMembersResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("MemberDetails"))
{
Array<JsonView> memberDetailsJsonList = jsonValue.GetArray("MemberDetails");
for(unsigned memberDetailsIndex = 0; memberDetailsIndex < memberDetailsJsonList.GetLength(); ++memberDetailsIndex)
{
m_memberDetails.push_back(memberDetailsJsonList[memberDetailsIndex].AsObject());
}
}
if(jsonValue.ValueExists("UnprocessedAccounts"))
{
Array<JsonView> unprocessedAccountsJsonList = jsonValue.GetArray("UnprocessedAccounts");
for(unsigned unprocessedAccountsIndex = 0; unprocessedAccountsIndex < unprocessedAccountsJsonList.GetLength(); ++unprocessedAccountsIndex)
{
m_unprocessedAccounts.push_back(unprocessedAccountsJsonList[unprocessedAccountsIndex].AsObject());
}
}
return *this;
}

View File

@@ -0,0 +1,73 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/Graph.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
namespace Aws
{
namespace Detective
{
namespace Model
{
Graph::Graph() :
m_arnHasBeenSet(false),
m_createdTimeHasBeenSet(false)
{
}
Graph::Graph(JsonView jsonValue) :
m_arnHasBeenSet(false),
m_createdTimeHasBeenSet(false)
{
*this = jsonValue;
}
Graph& Graph::operator =(JsonView jsonValue)
{
if(jsonValue.ValueExists("Arn"))
{
m_arn = jsonValue.GetString("Arn");
m_arnHasBeenSet = true;
}
if(jsonValue.ValueExists("CreatedTime"))
{
m_createdTime = jsonValue.GetDouble("CreatedTime");
m_createdTimeHasBeenSet = true;
}
return *this;
}
JsonValue Graph::Jsonize() const
{
JsonValue payload;
if(m_arnHasBeenSet)
{
payload.WithString("Arn", m_arn);
}
if(m_createdTimeHasBeenSet)
{
payload.WithDouble("CreatedTime", m_createdTime.SecondsWithMSPrecision());
}
return payload;
}
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,43 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/ListGraphsRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
ListGraphsRequest::ListGraphsRequest() :
m_nextTokenHasBeenSet(false),
m_maxResults(0),
m_maxResultsHasBeenSet(false)
{
}
Aws::String ListGraphsRequest::SerializePayload() const
{
JsonValue payload;
if(m_nextTokenHasBeenSet)
{
payload.WithString("NextToken", m_nextToken);
}
if(m_maxResultsHasBeenSet)
{
payload.WithInteger("MaxResults", m_maxResults);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,49 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/ListGraphsResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
ListGraphsResult::ListGraphsResult()
{
}
ListGraphsResult::ListGraphsResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
ListGraphsResult& ListGraphsResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("GraphList"))
{
Array<JsonView> graphListJsonList = jsonValue.GetArray("GraphList");
for(unsigned graphListIndex = 0; graphListIndex < graphListJsonList.GetLength(); ++graphListIndex)
{
m_graphList.push_back(graphListJsonList[graphListIndex].AsObject());
}
}
if(jsonValue.ValueExists("NextToken"))
{
m_nextToken = jsonValue.GetString("NextToken");
}
return *this;
}

View File

@@ -0,0 +1,43 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/ListInvitationsRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
ListInvitationsRequest::ListInvitationsRequest() :
m_nextTokenHasBeenSet(false),
m_maxResults(0),
m_maxResultsHasBeenSet(false)
{
}
Aws::String ListInvitationsRequest::SerializePayload() const
{
JsonValue payload;
if(m_nextTokenHasBeenSet)
{
payload.WithString("NextToken", m_nextToken);
}
if(m_maxResultsHasBeenSet)
{
payload.WithInteger("MaxResults", m_maxResults);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,49 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/ListInvitationsResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
ListInvitationsResult::ListInvitationsResult()
{
}
ListInvitationsResult::ListInvitationsResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
ListInvitationsResult& ListInvitationsResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("Invitations"))
{
Array<JsonView> invitationsJsonList = jsonValue.GetArray("Invitations");
for(unsigned invitationsIndex = 0; invitationsIndex < invitationsJsonList.GetLength(); ++invitationsIndex)
{
m_invitations.push_back(invitationsJsonList[invitationsIndex].AsObject());
}
}
if(jsonValue.ValueExists("NextToken"))
{
m_nextToken = jsonValue.GetString("NextToken");
}
return *this;
}

View File

@@ -0,0 +1,50 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/ListMembersRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
ListMembersRequest::ListMembersRequest() :
m_graphArnHasBeenSet(false),
m_nextTokenHasBeenSet(false),
m_maxResults(0),
m_maxResultsHasBeenSet(false)
{
}
Aws::String ListMembersRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
if(m_nextTokenHasBeenSet)
{
payload.WithString("NextToken", m_nextToken);
}
if(m_maxResultsHasBeenSet)
{
payload.WithInteger("MaxResults", m_maxResults);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,49 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/ListMembersResult.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <aws/core/AmazonWebServiceResult.h>
#include <aws/core/utils/StringUtils.h>
#include <aws/core/utils/UnreferencedParam.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
using namespace Aws;
ListMembersResult::ListMembersResult()
{
}
ListMembersResult::ListMembersResult(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
*this = result;
}
ListMembersResult& ListMembersResult::operator =(const Aws::AmazonWebServiceResult<JsonValue>& result)
{
JsonView jsonValue = result.GetPayload().View();
if(jsonValue.ValueExists("MemberDetails"))
{
Array<JsonView> memberDetailsJsonList = jsonValue.GetArray("MemberDetails");
for(unsigned memberDetailsIndex = 0; memberDetailsIndex < memberDetailsJsonList.GetLength(); ++memberDetailsIndex)
{
m_memberDetails.push_back(memberDetailsJsonList[memberDetailsIndex].AsObject());
}
}
if(jsonValue.ValueExists("NextToken"))
{
m_nextToken = jsonValue.GetString("NextToken");
}
return *this;
}

View File

@@ -0,0 +1,195 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/MemberDetail.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
namespace Aws
{
namespace Detective
{
namespace Model
{
MemberDetail::MemberDetail() :
m_accountIdHasBeenSet(false),
m_emailAddressHasBeenSet(false),
m_graphArnHasBeenSet(false),
m_masterIdHasBeenSet(false),
m_status(MemberStatus::NOT_SET),
m_statusHasBeenSet(false),
m_disabledReason(MemberDisabledReason::NOT_SET),
m_disabledReasonHasBeenSet(false),
m_invitedTimeHasBeenSet(false),
m_updatedTimeHasBeenSet(false),
m_percentOfGraphUtilization(0.0),
m_percentOfGraphUtilizationHasBeenSet(false),
m_percentOfGraphUtilizationUpdatedTimeHasBeenSet(false)
{
}
MemberDetail::MemberDetail(JsonView jsonValue) :
m_accountIdHasBeenSet(false),
m_emailAddressHasBeenSet(false),
m_graphArnHasBeenSet(false),
m_masterIdHasBeenSet(false),
m_status(MemberStatus::NOT_SET),
m_statusHasBeenSet(false),
m_disabledReason(MemberDisabledReason::NOT_SET),
m_disabledReasonHasBeenSet(false),
m_invitedTimeHasBeenSet(false),
m_updatedTimeHasBeenSet(false),
m_percentOfGraphUtilization(0.0),
m_percentOfGraphUtilizationHasBeenSet(false),
m_percentOfGraphUtilizationUpdatedTimeHasBeenSet(false)
{
*this = jsonValue;
}
MemberDetail& MemberDetail::operator =(JsonView jsonValue)
{
if(jsonValue.ValueExists("AccountId"))
{
m_accountId = jsonValue.GetString("AccountId");
m_accountIdHasBeenSet = true;
}
if(jsonValue.ValueExists("EmailAddress"))
{
m_emailAddress = jsonValue.GetString("EmailAddress");
m_emailAddressHasBeenSet = true;
}
if(jsonValue.ValueExists("GraphArn"))
{
m_graphArn = jsonValue.GetString("GraphArn");
m_graphArnHasBeenSet = true;
}
if(jsonValue.ValueExists("MasterId"))
{
m_masterId = jsonValue.GetString("MasterId");
m_masterIdHasBeenSet = true;
}
if(jsonValue.ValueExists("Status"))
{
m_status = MemberStatusMapper::GetMemberStatusForName(jsonValue.GetString("Status"));
m_statusHasBeenSet = true;
}
if(jsonValue.ValueExists("DisabledReason"))
{
m_disabledReason = MemberDisabledReasonMapper::GetMemberDisabledReasonForName(jsonValue.GetString("DisabledReason"));
m_disabledReasonHasBeenSet = true;
}
if(jsonValue.ValueExists("InvitedTime"))
{
m_invitedTime = jsonValue.GetDouble("InvitedTime");
m_invitedTimeHasBeenSet = true;
}
if(jsonValue.ValueExists("UpdatedTime"))
{
m_updatedTime = jsonValue.GetDouble("UpdatedTime");
m_updatedTimeHasBeenSet = true;
}
if(jsonValue.ValueExists("PercentOfGraphUtilization"))
{
m_percentOfGraphUtilization = jsonValue.GetDouble("PercentOfGraphUtilization");
m_percentOfGraphUtilizationHasBeenSet = true;
}
if(jsonValue.ValueExists("PercentOfGraphUtilizationUpdatedTime"))
{
m_percentOfGraphUtilizationUpdatedTime = jsonValue.GetDouble("PercentOfGraphUtilizationUpdatedTime");
m_percentOfGraphUtilizationUpdatedTimeHasBeenSet = true;
}
return *this;
}
JsonValue MemberDetail::Jsonize() const
{
JsonValue payload;
if(m_accountIdHasBeenSet)
{
payload.WithString("AccountId", m_accountId);
}
if(m_emailAddressHasBeenSet)
{
payload.WithString("EmailAddress", m_emailAddress);
}
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
if(m_masterIdHasBeenSet)
{
payload.WithString("MasterId", m_masterId);
}
if(m_statusHasBeenSet)
{
payload.WithString("Status", MemberStatusMapper::GetNameForMemberStatus(m_status));
}
if(m_disabledReasonHasBeenSet)
{
payload.WithString("DisabledReason", MemberDisabledReasonMapper::GetNameForMemberDisabledReason(m_disabledReason));
}
if(m_invitedTimeHasBeenSet)
{
payload.WithDouble("InvitedTime", m_invitedTime.SecondsWithMSPrecision());
}
if(m_updatedTimeHasBeenSet)
{
payload.WithDouble("UpdatedTime", m_updatedTime.SecondsWithMSPrecision());
}
if(m_percentOfGraphUtilizationHasBeenSet)
{
payload.WithDouble("PercentOfGraphUtilization", m_percentOfGraphUtilization);
}
if(m_percentOfGraphUtilizationUpdatedTimeHasBeenSet)
{
payload.WithDouble("PercentOfGraphUtilizationUpdatedTime", m_percentOfGraphUtilizationUpdatedTime.SecondsWithMSPrecision());
}
return payload;
}
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,70 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/MemberDisabledReason.h>
#include <aws/core/utils/HashingUtils.h>
#include <aws/core/Globals.h>
#include <aws/core/utils/EnumParseOverflowContainer.h>
using namespace Aws::Utils;
namespace Aws
{
namespace Detective
{
namespace Model
{
namespace MemberDisabledReasonMapper
{
static const int VOLUME_TOO_HIGH_HASH = HashingUtils::HashString("VOLUME_TOO_HIGH");
static const int VOLUME_UNKNOWN_HASH = HashingUtils::HashString("VOLUME_UNKNOWN");
MemberDisabledReason GetMemberDisabledReasonForName(const Aws::String& name)
{
int hashCode = HashingUtils::HashString(name.c_str());
if (hashCode == VOLUME_TOO_HIGH_HASH)
{
return MemberDisabledReason::VOLUME_TOO_HIGH;
}
else if (hashCode == VOLUME_UNKNOWN_HASH)
{
return MemberDisabledReason::VOLUME_UNKNOWN;
}
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
overflowContainer->StoreOverflow(hashCode, name);
return static_cast<MemberDisabledReason>(hashCode);
}
return MemberDisabledReason::NOT_SET;
}
Aws::String GetNameForMemberDisabledReason(MemberDisabledReason enumValue)
{
switch(enumValue)
{
case MemberDisabledReason::VOLUME_TOO_HIGH:
return "VOLUME_TOO_HIGH";
case MemberDisabledReason::VOLUME_UNKNOWN:
return "VOLUME_UNKNOWN";
default:
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
return overflowContainer->RetrieveOverflow(static_cast<int>(enumValue));
}
return {};
}
}
} // namespace MemberDisabledReasonMapper
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,91 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/MemberStatus.h>
#include <aws/core/utils/HashingUtils.h>
#include <aws/core/Globals.h>
#include <aws/core/utils/EnumParseOverflowContainer.h>
using namespace Aws::Utils;
namespace Aws
{
namespace Detective
{
namespace Model
{
namespace MemberStatusMapper
{
static const int INVITED_HASH = HashingUtils::HashString("INVITED");
static const int VERIFICATION_IN_PROGRESS_HASH = HashingUtils::HashString("VERIFICATION_IN_PROGRESS");
static const int VERIFICATION_FAILED_HASH = HashingUtils::HashString("VERIFICATION_FAILED");
static const int ENABLED_HASH = HashingUtils::HashString("ENABLED");
static const int ACCEPTED_BUT_DISABLED_HASH = HashingUtils::HashString("ACCEPTED_BUT_DISABLED");
MemberStatus GetMemberStatusForName(const Aws::String& name)
{
int hashCode = HashingUtils::HashString(name.c_str());
if (hashCode == INVITED_HASH)
{
return MemberStatus::INVITED;
}
else if (hashCode == VERIFICATION_IN_PROGRESS_HASH)
{
return MemberStatus::VERIFICATION_IN_PROGRESS;
}
else if (hashCode == VERIFICATION_FAILED_HASH)
{
return MemberStatus::VERIFICATION_FAILED;
}
else if (hashCode == ENABLED_HASH)
{
return MemberStatus::ENABLED;
}
else if (hashCode == ACCEPTED_BUT_DISABLED_HASH)
{
return MemberStatus::ACCEPTED_BUT_DISABLED;
}
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
overflowContainer->StoreOverflow(hashCode, name);
return static_cast<MemberStatus>(hashCode);
}
return MemberStatus::NOT_SET;
}
Aws::String GetNameForMemberStatus(MemberStatus enumValue)
{
switch(enumValue)
{
case MemberStatus::INVITED:
return "INVITED";
case MemberStatus::VERIFICATION_IN_PROGRESS:
return "VERIFICATION_IN_PROGRESS";
case MemberStatus::VERIFICATION_FAILED:
return "VERIFICATION_FAILED";
case MemberStatus::ENABLED:
return "ENABLED";
case MemberStatus::ACCEPTED_BUT_DISABLED:
return "ACCEPTED_BUT_DISABLED";
default:
EnumParseOverflowContainer* overflowContainer = Aws::GetEnumOverflowContainer();
if(overflowContainer)
{
return overflowContainer->RetrieveOverflow(static_cast<int>(enumValue));
}
return {};
}
}
} // namespace MemberStatusMapper
} // namespace Model
} // namespace Detective
} // namespace Aws

View File

@@ -0,0 +1,35 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/RejectInvitationRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
RejectInvitationRequest::RejectInvitationRequest() :
m_graphArnHasBeenSet(false)
{
}
Aws::String RejectInvitationRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,42 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/StartMonitoringMemberRequest.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Detective::Model;
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
StartMonitoringMemberRequest::StartMonitoringMemberRequest() :
m_graphArnHasBeenSet(false),
m_accountIdHasBeenSet(false)
{
}
Aws::String StartMonitoringMemberRequest::SerializePayload() const
{
JsonValue payload;
if(m_graphArnHasBeenSet)
{
payload.WithString("GraphArn", m_graphArn);
}
if(m_accountIdHasBeenSet)
{
payload.WithString("AccountId", m_accountId);
}
return payload.View().WriteReadable();
}

View File

@@ -0,0 +1,74 @@
/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#include <aws/detective/model/UnprocessedAccount.h>
#include <aws/core/utils/json/JsonSerializer.h>
#include <utility>
using namespace Aws::Utils::Json;
using namespace Aws::Utils;
namespace Aws
{
namespace Detective
{
namespace Model
{
UnprocessedAccount::UnprocessedAccount() :
m_accountIdHasBeenSet(false),
m_reasonHasBeenSet(false)
{
}
UnprocessedAccount::UnprocessedAccount(JsonView jsonValue) :
m_accountIdHasBeenSet(false),
m_reasonHasBeenSet(false)
{
*this = jsonValue;
}
UnprocessedAccount& UnprocessedAccount::operator =(JsonView jsonValue)
{
if(jsonValue.ValueExists("AccountId"))
{
m_accountId = jsonValue.GetString("AccountId");
m_accountIdHasBeenSet = true;
}
if(jsonValue.ValueExists("Reason"))
{
m_reason = jsonValue.GetString("Reason");
m_reasonHasBeenSet = true;
}
return *this;
}
JsonValue UnprocessedAccount::Jsonize() const
{
JsonValue payload;
if(m_accountIdHasBeenSet)
{
payload.WithString("AccountId", m_accountId);
}
if(m_reasonHasBeenSet)
{
payload.WithString("Reason", m_reason);
}
return payload;
}
} // namespace Model
} // namespace Detective
} // namespace Aws