From b88765a938b5568ff72d2c6d56db83a15df794f8 Mon Sep 17 00:00:00 2001 From: sdk-team Date: Fri, 23 Aug 2024 02:51:13 +0000 Subject: [PATCH] =?UTF-8?q?=E6=B2=BB=E7=90=86=E6=A3=80=E6=B5=8B=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E7=AC=AC=E4=B8=80=E7=89=88OpenAPI?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- VERSION | 2 +- governance/CMakeLists.txt | 142 +++++ .../governance/GovernanceClient.h | 166 +++++ .../governance/GovernanceExport.h | 32 + .../model/BatchEnrollAccountsRequest.h | 60 ++ .../model/BatchEnrollAccountsResult.h | 49 ++ .../CreateAccountFactoryBaselineRequest.h | 56 ++ .../CreateAccountFactoryBaselineResult.h | 51 ++ .../DeleteAccountFactoryBaselineRequest.h | 45 ++ .../DeleteAccountFactoryBaselineResult.h | 49 ++ .../governance/model/EnrollAccountRequest.h | 72 +++ .../governance/model/EnrollAccountResult.h | 51 ++ .../model/GetAccountFactoryBaselineRequest.h | 45 ++ .../model/GetAccountFactoryBaselineResult.h | 69 ++ .../model/GetEnrolledAccountRequest.h | 45 ++ .../model/GetEnrolledAccountResult.h | 112 ++++ .../ListAccountFactoryBaselineItemsRequest.h | 57 ++ .../ListAccountFactoryBaselineItemsResult.h | 67 ++ .../ListAccountFactoryBaselinesRequest.h | 48 ++ .../model/ListAccountFactoryBaselinesResult.h | 62 ++ .../model/ListEnrolledAccountsRequest.h | 48 ++ .../model/ListEnrolledAccountsResult.h | 64 ++ .../model/ListEvaluationMetadataRequest.h | 48 ++ .../model/ListEvaluationMetadataResult.h | 109 ++++ .../ListEvaluationMetricDetailsRequest.h | 57 ++ .../model/ListEvaluationMetricDetailsResult.h | 69 ++ .../model/ListEvaluationResultsRequest.h | 48 ++ .../model/ListEvaluationResultsResult.h | 91 +++ .../model/ListEvaluationScoreHistoryRequest.h | 54 ++ .../model/ListEvaluationScoreHistoryResult.h | 82 +++ .../governance/model/RunEvaluationRequest.h | 51 ++ .../governance/model/RunEvaluationResult.h | 49 ++ .../UpdateAccountFactoryBaselineRequest.h | 59 ++ .../UpdateAccountFactoryBaselineResult.h | 49 ++ governance/src/GovernanceClient.cc | 593 ++++++++++++++++++ .../src/model/BatchEnrollAccountsRequest.cc | 70 +++ .../src/model/BatchEnrollAccountsResult.cc | 44 ++ .../CreateAccountFactoryBaselineRequest.cc | 67 ++ .../CreateAccountFactoryBaselineResult.cc | 51 ++ .../DeleteAccountFactoryBaselineRequest.cc | 45 ++ .../DeleteAccountFactoryBaselineResult.cc | 44 ++ governance/src/model/EnrollAccountRequest.cc | 113 ++++ governance/src/model/EnrollAccountResult.cc | 51 ++ .../model/GetAccountFactoryBaselineRequest.cc | 45 ++ .../model/GetAccountFactoryBaselineResult.cc | 103 +++ .../src/model/GetEnrolledAccountRequest.cc | 45 ++ .../src/model/GetEnrolledAccountResult.cc | 192 ++++++ .../ListAccountFactoryBaselineItemsRequest.cc | 85 +++ .../ListAccountFactoryBaselineItemsResult.cc | 82 +++ .../ListAccountFactoryBaselinesRequest.cc | 54 ++ .../ListAccountFactoryBaselinesResult.cc | 74 +++ .../src/model/ListEnrolledAccountsRequest.cc | 54 ++ .../src/model/ListEnrolledAccountsResult.cc | 78 +++ .../model/ListEvaluationMetadataRequest.cc | 54 ++ .../src/model/ListEvaluationMetadataResult.cc | 141 +++++ .../ListEvaluationMetricDetailsRequest.cc | 81 +++ .../ListEvaluationMetricDetailsResult.cc | 86 +++ .../src/model/ListEvaluationResultsRequest.cc | 54 ++ .../src/model/ListEvaluationResultsResult.cc | 107 ++++ .../ListEvaluationScoreHistoryRequest.cc | 72 +++ .../model/ListEvaluationScoreHistoryResult.cc | 96 +++ governance/src/model/RunEvaluationRequest.cc | 63 ++ governance/src/model/RunEvaluationResult.cc | 44 ++ .../UpdateAccountFactoryBaselineRequest.cc | 76 +++ .../UpdateAccountFactoryBaselineResult.cc | 44 ++ 65 files changed, 4965 insertions(+), 1 deletion(-) create mode 100644 governance/CMakeLists.txt create mode 100644 governance/include/alibabacloud/governance/GovernanceClient.h create mode 100644 governance/include/alibabacloud/governance/GovernanceExport.h create mode 100644 governance/include/alibabacloud/governance/model/BatchEnrollAccountsRequest.h create mode 100644 governance/include/alibabacloud/governance/model/BatchEnrollAccountsResult.h create mode 100644 governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineRequest.h create mode 100644 governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineResult.h create mode 100644 governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineRequest.h create mode 100644 governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineResult.h create mode 100644 governance/include/alibabacloud/governance/model/EnrollAccountRequest.h create mode 100644 governance/include/alibabacloud/governance/model/EnrollAccountResult.h create mode 100644 governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineRequest.h create mode 100644 governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineResult.h create mode 100644 governance/include/alibabacloud/governance/model/GetEnrolledAccountRequest.h create mode 100644 governance/include/alibabacloud/governance/model/GetEnrolledAccountResult.h create mode 100644 governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsRequest.h create mode 100644 governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsResult.h create mode 100644 governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesRequest.h create mode 100644 governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesResult.h create mode 100644 governance/include/alibabacloud/governance/model/ListEnrolledAccountsRequest.h create mode 100644 governance/include/alibabacloud/governance/model/ListEnrolledAccountsResult.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationMetadataRequest.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationMetadataResult.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsRequest.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsResult.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationResultsRequest.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationResultsResult.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryRequest.h create mode 100644 governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryResult.h create mode 100644 governance/include/alibabacloud/governance/model/RunEvaluationRequest.h create mode 100644 governance/include/alibabacloud/governance/model/RunEvaluationResult.h create mode 100644 governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineRequest.h create mode 100644 governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineResult.h create mode 100644 governance/src/GovernanceClient.cc create mode 100644 governance/src/model/BatchEnrollAccountsRequest.cc create mode 100644 governance/src/model/BatchEnrollAccountsResult.cc create mode 100644 governance/src/model/CreateAccountFactoryBaselineRequest.cc create mode 100644 governance/src/model/CreateAccountFactoryBaselineResult.cc create mode 100644 governance/src/model/DeleteAccountFactoryBaselineRequest.cc create mode 100644 governance/src/model/DeleteAccountFactoryBaselineResult.cc create mode 100644 governance/src/model/EnrollAccountRequest.cc create mode 100644 governance/src/model/EnrollAccountResult.cc create mode 100644 governance/src/model/GetAccountFactoryBaselineRequest.cc create mode 100644 governance/src/model/GetAccountFactoryBaselineResult.cc create mode 100644 governance/src/model/GetEnrolledAccountRequest.cc create mode 100644 governance/src/model/GetEnrolledAccountResult.cc create mode 100644 governance/src/model/ListAccountFactoryBaselineItemsRequest.cc create mode 100644 governance/src/model/ListAccountFactoryBaselineItemsResult.cc create mode 100644 governance/src/model/ListAccountFactoryBaselinesRequest.cc create mode 100644 governance/src/model/ListAccountFactoryBaselinesResult.cc create mode 100644 governance/src/model/ListEnrolledAccountsRequest.cc create mode 100644 governance/src/model/ListEnrolledAccountsResult.cc create mode 100644 governance/src/model/ListEvaluationMetadataRequest.cc create mode 100644 governance/src/model/ListEvaluationMetadataResult.cc create mode 100644 governance/src/model/ListEvaluationMetricDetailsRequest.cc create mode 100644 governance/src/model/ListEvaluationMetricDetailsResult.cc create mode 100644 governance/src/model/ListEvaluationResultsRequest.cc create mode 100644 governance/src/model/ListEvaluationResultsResult.cc create mode 100644 governance/src/model/ListEvaluationScoreHistoryRequest.cc create mode 100644 governance/src/model/ListEvaluationScoreHistoryResult.cc create mode 100644 governance/src/model/RunEvaluationRequest.cc create mode 100644 governance/src/model/RunEvaluationResult.cc create mode 100644 governance/src/model/UpdateAccountFactoryBaselineRequest.cc create mode 100644 governance/src/model/UpdateAccountFactoryBaselineResult.cc diff --git a/VERSION b/VERSION index 21379d0a5..d49a5ab74 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.36.1978 \ No newline at end of file +1.36.1979 \ No newline at end of file diff --git a/governance/CMakeLists.txt b/governance/CMakeLists.txt new file mode 100644 index 000000000..d7dd4cc36 --- /dev/null +++ b/governance/CMakeLists.txt @@ -0,0 +1,142 @@ +# +# Copyright 2009-2017 Alibaba Cloud All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include) + +set(governance_public_header + include/alibabacloud/governance/GovernanceClient.h + include/alibabacloud/governance/GovernanceExport.h ) + +set(governance_public_header_model + include/alibabacloud/governance/model/BatchEnrollAccountsRequest.h + include/alibabacloud/governance/model/BatchEnrollAccountsResult.h + include/alibabacloud/governance/model/CreateAccountFactoryBaselineRequest.h + include/alibabacloud/governance/model/CreateAccountFactoryBaselineResult.h + include/alibabacloud/governance/model/DeleteAccountFactoryBaselineRequest.h + include/alibabacloud/governance/model/DeleteAccountFactoryBaselineResult.h + include/alibabacloud/governance/model/EnrollAccountRequest.h + include/alibabacloud/governance/model/EnrollAccountResult.h + include/alibabacloud/governance/model/GetAccountFactoryBaselineRequest.h + include/alibabacloud/governance/model/GetAccountFactoryBaselineResult.h + include/alibabacloud/governance/model/GetEnrolledAccountRequest.h + include/alibabacloud/governance/model/GetEnrolledAccountResult.h + include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsRequest.h + include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsResult.h + include/alibabacloud/governance/model/ListAccountFactoryBaselinesRequest.h + include/alibabacloud/governance/model/ListAccountFactoryBaselinesResult.h + include/alibabacloud/governance/model/ListEnrolledAccountsRequest.h + include/alibabacloud/governance/model/ListEnrolledAccountsResult.h + include/alibabacloud/governance/model/ListEvaluationMetadataRequest.h + include/alibabacloud/governance/model/ListEvaluationMetadataResult.h + include/alibabacloud/governance/model/ListEvaluationMetricDetailsRequest.h + include/alibabacloud/governance/model/ListEvaluationMetricDetailsResult.h + include/alibabacloud/governance/model/ListEvaluationResultsRequest.h + include/alibabacloud/governance/model/ListEvaluationResultsResult.h + include/alibabacloud/governance/model/ListEvaluationScoreHistoryRequest.h + include/alibabacloud/governance/model/ListEvaluationScoreHistoryResult.h + include/alibabacloud/governance/model/RunEvaluationRequest.h + include/alibabacloud/governance/model/RunEvaluationResult.h + include/alibabacloud/governance/model/UpdateAccountFactoryBaselineRequest.h + include/alibabacloud/governance/model/UpdateAccountFactoryBaselineResult.h ) + +set(governance_src + src/GovernanceClient.cc + src/model/BatchEnrollAccountsRequest.cc + src/model/BatchEnrollAccountsResult.cc + src/model/CreateAccountFactoryBaselineRequest.cc + src/model/CreateAccountFactoryBaselineResult.cc + src/model/DeleteAccountFactoryBaselineRequest.cc + src/model/DeleteAccountFactoryBaselineResult.cc + src/model/EnrollAccountRequest.cc + src/model/EnrollAccountResult.cc + src/model/GetAccountFactoryBaselineRequest.cc + src/model/GetAccountFactoryBaselineResult.cc + src/model/GetEnrolledAccountRequest.cc + src/model/GetEnrolledAccountResult.cc + src/model/ListAccountFactoryBaselineItemsRequest.cc + src/model/ListAccountFactoryBaselineItemsResult.cc + src/model/ListAccountFactoryBaselinesRequest.cc + src/model/ListAccountFactoryBaselinesResult.cc + src/model/ListEnrolledAccountsRequest.cc + src/model/ListEnrolledAccountsResult.cc + src/model/ListEvaluationMetadataRequest.cc + src/model/ListEvaluationMetadataResult.cc + src/model/ListEvaluationMetricDetailsRequest.cc + src/model/ListEvaluationMetricDetailsResult.cc + src/model/ListEvaluationResultsRequest.cc + src/model/ListEvaluationResultsResult.cc + src/model/ListEvaluationScoreHistoryRequest.cc + src/model/ListEvaluationScoreHistoryResult.cc + src/model/RunEvaluationRequest.cc + src/model/RunEvaluationResult.cc + src/model/UpdateAccountFactoryBaselineRequest.cc + src/model/UpdateAccountFactoryBaselineResult.cc ) + +add_library(governance ${LIB_TYPE} + ${governance_public_header} + ${governance_public_header_model} + ${governance_src}) + +set_target_properties(governance + PROPERTIES + LINKER_LANGUAGE CXX + ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib + LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib + RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin + OUTPUT_NAME ${TARGET_OUTPUT_NAME_PREFIX}governance + ) + +if(${LIB_TYPE} STREQUAL "SHARED") + set_target_properties(governance + PROPERTIES + DEFINE_SYMBOL ALIBABACLOUD_GOVERNANCE_LIBRARY) +endif() + +target_include_directories(governance + PRIVATE include + ${CMAKE_SOURCE_DIR}/core/include + ) +target_link_libraries(governance + core) + +if(CMAKE_HOST_WIN32) + ExternalProject_Get_Property(jsoncpp INSTALL_DIR) + set(jsoncpp_install_dir ${INSTALL_DIR}) + add_dependencies(governance + jsoncpp) + target_include_directories(governance + PRIVATE ${jsoncpp_install_dir}/include) + target_link_libraries(governance + ${jsoncpp_install_dir}/lib/jsoncpp.lib) + set_target_properties(governance + PROPERTIES + COMPILE_OPTIONS "/bigobj") +else() + target_include_directories(governance + PRIVATE /usr/include/jsoncpp) + target_link_libraries(governance + jsoncpp) +endif() + +install(FILES ${governance_public_header} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/governance) +install(FILES ${governance_public_header_model} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/governance/model) +install(TARGETS governance + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + ) \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/GovernanceClient.h b/governance/include/alibabacloud/governance/GovernanceClient.h new file mode 100644 index 000000000..e72941101 --- /dev/null +++ b/governance/include/alibabacloud/governance/GovernanceClient.h @@ -0,0 +1,166 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_GOVERNANCECLIENT_H_ +#define ALIBABACLOUD_GOVERNANCE_GOVERNANCECLIENT_H_ + +#include +#include +#include +#include +#include "GovernanceExport.h" +#include "model/BatchEnrollAccountsRequest.h" +#include "model/BatchEnrollAccountsResult.h" +#include "model/CreateAccountFactoryBaselineRequest.h" +#include "model/CreateAccountFactoryBaselineResult.h" +#include "model/DeleteAccountFactoryBaselineRequest.h" +#include "model/DeleteAccountFactoryBaselineResult.h" +#include "model/EnrollAccountRequest.h" +#include "model/EnrollAccountResult.h" +#include "model/GetAccountFactoryBaselineRequest.h" +#include "model/GetAccountFactoryBaselineResult.h" +#include "model/GetEnrolledAccountRequest.h" +#include "model/GetEnrolledAccountResult.h" +#include "model/ListAccountFactoryBaselineItemsRequest.h" +#include "model/ListAccountFactoryBaselineItemsResult.h" +#include "model/ListAccountFactoryBaselinesRequest.h" +#include "model/ListAccountFactoryBaselinesResult.h" +#include "model/ListEnrolledAccountsRequest.h" +#include "model/ListEnrolledAccountsResult.h" +#include "model/ListEvaluationMetadataRequest.h" +#include "model/ListEvaluationMetadataResult.h" +#include "model/ListEvaluationMetricDetailsRequest.h" +#include "model/ListEvaluationMetricDetailsResult.h" +#include "model/ListEvaluationResultsRequest.h" +#include "model/ListEvaluationResultsResult.h" +#include "model/ListEvaluationScoreHistoryRequest.h" +#include "model/ListEvaluationScoreHistoryResult.h" +#include "model/RunEvaluationRequest.h" +#include "model/RunEvaluationResult.h" +#include "model/UpdateAccountFactoryBaselineRequest.h" +#include "model/UpdateAccountFactoryBaselineResult.h" + + +namespace AlibabaCloud +{ + namespace Governance + { + class ALIBABACLOUD_GOVERNANCE_EXPORT GovernanceClient : public RpcServiceClient + { + public: + typedef Outcome BatchEnrollAccountsOutcome; + typedef std::future BatchEnrollAccountsOutcomeCallable; + typedef std::function&)> BatchEnrollAccountsAsyncHandler; + typedef Outcome CreateAccountFactoryBaselineOutcome; + typedef std::future CreateAccountFactoryBaselineOutcomeCallable; + typedef std::function&)> CreateAccountFactoryBaselineAsyncHandler; + typedef Outcome DeleteAccountFactoryBaselineOutcome; + typedef std::future DeleteAccountFactoryBaselineOutcomeCallable; + typedef std::function&)> DeleteAccountFactoryBaselineAsyncHandler; + typedef Outcome EnrollAccountOutcome; + typedef std::future EnrollAccountOutcomeCallable; + typedef std::function&)> EnrollAccountAsyncHandler; + typedef Outcome GetAccountFactoryBaselineOutcome; + typedef std::future GetAccountFactoryBaselineOutcomeCallable; + typedef std::function&)> GetAccountFactoryBaselineAsyncHandler; + typedef Outcome GetEnrolledAccountOutcome; + typedef std::future GetEnrolledAccountOutcomeCallable; + typedef std::function&)> GetEnrolledAccountAsyncHandler; + typedef Outcome ListAccountFactoryBaselineItemsOutcome; + typedef std::future ListAccountFactoryBaselineItemsOutcomeCallable; + typedef std::function&)> ListAccountFactoryBaselineItemsAsyncHandler; + typedef Outcome ListAccountFactoryBaselinesOutcome; + typedef std::future ListAccountFactoryBaselinesOutcomeCallable; + typedef std::function&)> ListAccountFactoryBaselinesAsyncHandler; + typedef Outcome ListEnrolledAccountsOutcome; + typedef std::future ListEnrolledAccountsOutcomeCallable; + typedef std::function&)> ListEnrolledAccountsAsyncHandler; + typedef Outcome ListEvaluationMetadataOutcome; + typedef std::future ListEvaluationMetadataOutcomeCallable; + typedef std::function&)> ListEvaluationMetadataAsyncHandler; + typedef Outcome ListEvaluationMetricDetailsOutcome; + typedef std::future ListEvaluationMetricDetailsOutcomeCallable; + typedef std::function&)> ListEvaluationMetricDetailsAsyncHandler; + typedef Outcome ListEvaluationResultsOutcome; + typedef std::future ListEvaluationResultsOutcomeCallable; + typedef std::function&)> ListEvaluationResultsAsyncHandler; + typedef Outcome ListEvaluationScoreHistoryOutcome; + typedef std::future ListEvaluationScoreHistoryOutcomeCallable; + typedef std::function&)> ListEvaluationScoreHistoryAsyncHandler; + typedef Outcome RunEvaluationOutcome; + typedef std::future RunEvaluationOutcomeCallable; + typedef std::function&)> RunEvaluationAsyncHandler; + typedef Outcome UpdateAccountFactoryBaselineOutcome; + typedef std::future UpdateAccountFactoryBaselineOutcomeCallable; + typedef std::function&)> UpdateAccountFactoryBaselineAsyncHandler; + + GovernanceClient(const Credentials &credentials, const ClientConfiguration &configuration); + GovernanceClient(const std::shared_ptr &credentialsProvider, const ClientConfiguration &configuration); + GovernanceClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration); + ~GovernanceClient(); + BatchEnrollAccountsOutcome batchEnrollAccounts(const Model::BatchEnrollAccountsRequest &request)const; + void batchEnrollAccountsAsync(const Model::BatchEnrollAccountsRequest& request, const BatchEnrollAccountsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + BatchEnrollAccountsOutcomeCallable batchEnrollAccountsCallable(const Model::BatchEnrollAccountsRequest& request) const; + CreateAccountFactoryBaselineOutcome createAccountFactoryBaseline(const Model::CreateAccountFactoryBaselineRequest &request)const; + void createAccountFactoryBaselineAsync(const Model::CreateAccountFactoryBaselineRequest& request, const CreateAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateAccountFactoryBaselineOutcomeCallable createAccountFactoryBaselineCallable(const Model::CreateAccountFactoryBaselineRequest& request) const; + DeleteAccountFactoryBaselineOutcome deleteAccountFactoryBaseline(const Model::DeleteAccountFactoryBaselineRequest &request)const; + void deleteAccountFactoryBaselineAsync(const Model::DeleteAccountFactoryBaselineRequest& request, const DeleteAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteAccountFactoryBaselineOutcomeCallable deleteAccountFactoryBaselineCallable(const Model::DeleteAccountFactoryBaselineRequest& request) const; + EnrollAccountOutcome enrollAccount(const Model::EnrollAccountRequest &request)const; + void enrollAccountAsync(const Model::EnrollAccountRequest& request, const EnrollAccountAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + EnrollAccountOutcomeCallable enrollAccountCallable(const Model::EnrollAccountRequest& request) const; + GetAccountFactoryBaselineOutcome getAccountFactoryBaseline(const Model::GetAccountFactoryBaselineRequest &request)const; + void getAccountFactoryBaselineAsync(const Model::GetAccountFactoryBaselineRequest& request, const GetAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetAccountFactoryBaselineOutcomeCallable getAccountFactoryBaselineCallable(const Model::GetAccountFactoryBaselineRequest& request) const; + GetEnrolledAccountOutcome getEnrolledAccount(const Model::GetEnrolledAccountRequest &request)const; + void getEnrolledAccountAsync(const Model::GetEnrolledAccountRequest& request, const GetEnrolledAccountAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetEnrolledAccountOutcomeCallable getEnrolledAccountCallable(const Model::GetEnrolledAccountRequest& request) const; + ListAccountFactoryBaselineItemsOutcome listAccountFactoryBaselineItems(const Model::ListAccountFactoryBaselineItemsRequest &request)const; + void listAccountFactoryBaselineItemsAsync(const Model::ListAccountFactoryBaselineItemsRequest& request, const ListAccountFactoryBaselineItemsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListAccountFactoryBaselineItemsOutcomeCallable listAccountFactoryBaselineItemsCallable(const Model::ListAccountFactoryBaselineItemsRequest& request) const; + ListAccountFactoryBaselinesOutcome listAccountFactoryBaselines(const Model::ListAccountFactoryBaselinesRequest &request)const; + void listAccountFactoryBaselinesAsync(const Model::ListAccountFactoryBaselinesRequest& request, const ListAccountFactoryBaselinesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListAccountFactoryBaselinesOutcomeCallable listAccountFactoryBaselinesCallable(const Model::ListAccountFactoryBaselinesRequest& request) const; + ListEnrolledAccountsOutcome listEnrolledAccounts(const Model::ListEnrolledAccountsRequest &request)const; + void listEnrolledAccountsAsync(const Model::ListEnrolledAccountsRequest& request, const ListEnrolledAccountsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListEnrolledAccountsOutcomeCallable listEnrolledAccountsCallable(const Model::ListEnrolledAccountsRequest& request) const; + ListEvaluationMetadataOutcome listEvaluationMetadata(const Model::ListEvaluationMetadataRequest &request)const; + void listEvaluationMetadataAsync(const Model::ListEvaluationMetadataRequest& request, const ListEvaluationMetadataAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListEvaluationMetadataOutcomeCallable listEvaluationMetadataCallable(const Model::ListEvaluationMetadataRequest& request) const; + ListEvaluationMetricDetailsOutcome listEvaluationMetricDetails(const Model::ListEvaluationMetricDetailsRequest &request)const; + void listEvaluationMetricDetailsAsync(const Model::ListEvaluationMetricDetailsRequest& request, const ListEvaluationMetricDetailsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListEvaluationMetricDetailsOutcomeCallable listEvaluationMetricDetailsCallable(const Model::ListEvaluationMetricDetailsRequest& request) const; + ListEvaluationResultsOutcome listEvaluationResults(const Model::ListEvaluationResultsRequest &request)const; + void listEvaluationResultsAsync(const Model::ListEvaluationResultsRequest& request, const ListEvaluationResultsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListEvaluationResultsOutcomeCallable listEvaluationResultsCallable(const Model::ListEvaluationResultsRequest& request) const; + ListEvaluationScoreHistoryOutcome listEvaluationScoreHistory(const Model::ListEvaluationScoreHistoryRequest &request)const; + void listEvaluationScoreHistoryAsync(const Model::ListEvaluationScoreHistoryRequest& request, const ListEvaluationScoreHistoryAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListEvaluationScoreHistoryOutcomeCallable listEvaluationScoreHistoryCallable(const Model::ListEvaluationScoreHistoryRequest& request) const; + RunEvaluationOutcome runEvaluation(const Model::RunEvaluationRequest &request)const; + void runEvaluationAsync(const Model::RunEvaluationRequest& request, const RunEvaluationAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + RunEvaluationOutcomeCallable runEvaluationCallable(const Model::RunEvaluationRequest& request) const; + UpdateAccountFactoryBaselineOutcome updateAccountFactoryBaseline(const Model::UpdateAccountFactoryBaselineRequest &request)const; + void updateAccountFactoryBaselineAsync(const Model::UpdateAccountFactoryBaselineRequest& request, const UpdateAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + UpdateAccountFactoryBaselineOutcomeCallable updateAccountFactoryBaselineCallable(const Model::UpdateAccountFactoryBaselineRequest& request) const; + + private: + std::shared_ptr endpointProvider_; + }; + } +} + +#endif // !ALIBABACLOUD_GOVERNANCE_GOVERNANCECLIENT_H_ diff --git a/governance/include/alibabacloud/governance/GovernanceExport.h b/governance/include/alibabacloud/governance/GovernanceExport.h new file mode 100644 index 000000000..78cf992c7 --- /dev/null +++ b/governance/include/alibabacloud/governance/GovernanceExport.h @@ -0,0 +1,32 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_GOVERNANCEEXPORT_H_ +#define ALIBABACLOUD_GOVERNANCE_GOVERNANCEEXPORT_H_ + +#include + +#if defined(ALIBABACLOUD_SHARED) +# if defined(ALIBABACLOUD_GOVERNANCE_LIBRARY) +# define ALIBABACLOUD_GOVERNANCE_EXPORT ALIBABACLOUD_DECL_EXPORT +# else +# define ALIBABACLOUD_GOVERNANCE_EXPORT ALIBABACLOUD_DECL_IMPORT +# endif +#else +# define ALIBABACLOUD_GOVERNANCE_EXPORT +#endif + +#endif // !ALIBABACLOUD_GOVERNANCE_GOVERNANCEEXPORT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/BatchEnrollAccountsRequest.h b/governance/include/alibabacloud/governance/model/BatchEnrollAccountsRequest.h new file mode 100644 index 000000000..edfa754a9 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/BatchEnrollAccountsRequest.h @@ -0,0 +1,60 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_BATCHENROLLACCOUNTSREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_BATCHENROLLACCOUNTSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT BatchEnrollAccountsRequest : public RpcServiceRequest { +public: + struct BaselineItems { + std::string name; + bool skip; + std::string config; + std::string version; + }; + struct Accounts { + long accountUid; + }; + BatchEnrollAccountsRequest(); + ~BatchEnrollAccountsRequest(); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getBaselineId() const; + void setBaselineId(const std::string &baselineId); + std::vector getBaselineItems() const; + void setBaselineItems(const std::vector &baselineItems); + std::vector getAccounts() const; + void setAccounts(const std::vector &accounts); + +private: + std::string regionId_; + std::string baselineId_; + std::vector baselineItems_; + std::vector accounts_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_BATCHENROLLACCOUNTSREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/BatchEnrollAccountsResult.h b/governance/include/alibabacloud/governance/model/BatchEnrollAccountsResult.h new file mode 100644 index 000000000..2d2b8a248 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/BatchEnrollAccountsResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_BATCHENROLLACCOUNTSRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_BATCHENROLLACCOUNTSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT BatchEnrollAccountsResult : public ServiceResult + { + public: + + + BatchEnrollAccountsResult(); + explicit BatchEnrollAccountsResult(const std::string &payload); + ~BatchEnrollAccountsResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_BATCHENROLLACCOUNTSRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineRequest.h b/governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineRequest.h new file mode 100644 index 000000000..48318bd05 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineRequest.h @@ -0,0 +1,56 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_CREATEACCOUNTFACTORYBASELINEREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_CREATEACCOUNTFACTORYBASELINEREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT CreateAccountFactoryBaselineRequest : public RpcServiceRequest { +public: + struct BaselineItems { + std::string name; + std::string config; + std::string version; + }; + CreateAccountFactoryBaselineRequest(); + ~CreateAccountFactoryBaselineRequest(); + std::string getDescription() const; + void setDescription(const std::string &description); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getBaselineName() const; + void setBaselineName(const std::string &baselineName); + std::vector getBaselineItems() const; + void setBaselineItems(const std::vector &baselineItems); + +private: + std::string description_; + std::string regionId_; + std::string baselineName_; + std::vector baselineItems_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_CREATEACCOUNTFACTORYBASELINEREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineResult.h b/governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineResult.h new file mode 100644 index 000000000..226d8eee2 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/CreateAccountFactoryBaselineResult.h @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_CREATEACCOUNTFACTORYBASELINERESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_CREATEACCOUNTFACTORYBASELINERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT CreateAccountFactoryBaselineResult : public ServiceResult + { + public: + + + CreateAccountFactoryBaselineResult(); + explicit CreateAccountFactoryBaselineResult(const std::string &payload); + ~CreateAccountFactoryBaselineResult(); + std::string getBaselineId()const; + + protected: + void parse(const std::string &payload); + private: + std::string baselineId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_CREATEACCOUNTFACTORYBASELINERESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineRequest.h b/governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineRequest.h new file mode 100644 index 000000000..5d1938678 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_DELETEACCOUNTFACTORYBASELINEREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_DELETEACCOUNTFACTORYBASELINEREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT DeleteAccountFactoryBaselineRequest : public RpcServiceRequest { +public: + DeleteAccountFactoryBaselineRequest(); + ~DeleteAccountFactoryBaselineRequest(); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getBaselineId() const; + void setBaselineId(const std::string &baselineId); + +private: + std::string regionId_; + std::string baselineId_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_DELETEACCOUNTFACTORYBASELINEREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineResult.h b/governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineResult.h new file mode 100644 index 000000000..324e9fabf --- /dev/null +++ b/governance/include/alibabacloud/governance/model/DeleteAccountFactoryBaselineResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_DELETEACCOUNTFACTORYBASELINERESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_DELETEACCOUNTFACTORYBASELINERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT DeleteAccountFactoryBaselineResult : public ServiceResult + { + public: + + + DeleteAccountFactoryBaselineResult(); + explicit DeleteAccountFactoryBaselineResult(const std::string &payload); + ~DeleteAccountFactoryBaselineResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_DELETEACCOUNTFACTORYBASELINERESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/EnrollAccountRequest.h b/governance/include/alibabacloud/governance/model/EnrollAccountRequest.h new file mode 100644 index 000000000..ab7d952a9 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/EnrollAccountRequest.h @@ -0,0 +1,72 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_ENROLLACCOUNTREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_ENROLLACCOUNTREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT EnrollAccountRequest : public RpcServiceRequest { +public: + struct BaselineItems { + std::string name; + bool skip; + std::string config; + std::string version; + }; + EnrollAccountRequest(); + ~EnrollAccountRequest(); + std::string getFolderId() const; + void setFolderId(const std::string &folderId); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + long getPayerAccountUid() const; + void setPayerAccountUid(long payerAccountUid); + long getAccountUid() const; + void setAccountUid(long accountUid); + std::string getAccountNamePrefix() const; + void setAccountNamePrefix(const std::string &accountNamePrefix); + std::string getResellAccountType() const; + void setResellAccountType(const std::string &resellAccountType); + std::string getBaselineId() const; + void setBaselineId(const std::string &baselineId); + std::vector getBaselineItems() const; + void setBaselineItems(const std::vector &baselineItems); + std::string getDisplayName() const; + void setDisplayName(const std::string &displayName); + +private: + std::string folderId_; + std::string regionId_; + long payerAccountUid_; + long accountUid_; + std::string accountNamePrefix_; + std::string resellAccountType_; + std::string baselineId_; + std::vector baselineItems_; + std::string displayName_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_ENROLLACCOUNTREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/EnrollAccountResult.h b/governance/include/alibabacloud/governance/model/EnrollAccountResult.h new file mode 100644 index 000000000..0426447c0 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/EnrollAccountResult.h @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_ENROLLACCOUNTRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_ENROLLACCOUNTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT EnrollAccountResult : public ServiceResult + { + public: + + + EnrollAccountResult(); + explicit EnrollAccountResult(const std::string &payload); + ~EnrollAccountResult(); + long getAccountUid()const; + + protected: + void parse(const std::string &payload); + private: + long accountUid_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_ENROLLACCOUNTRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineRequest.h b/governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineRequest.h new file mode 100644 index 000000000..17bc350fa --- /dev/null +++ b/governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_GETACCOUNTFACTORYBASELINEREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_GETACCOUNTFACTORYBASELINEREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT GetAccountFactoryBaselineRequest : public RpcServiceRequest { +public: + GetAccountFactoryBaselineRequest(); + ~GetAccountFactoryBaselineRequest(); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getBaselineId() const; + void setBaselineId(const std::string &baselineId); + +private: + std::string regionId_; + std::string baselineId_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_GETACCOUNTFACTORYBASELINEREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineResult.h b/governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineResult.h new file mode 100644 index 000000000..1a92f7538 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/GetAccountFactoryBaselineResult.h @@ -0,0 +1,69 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_GETACCOUNTFACTORYBASELINERESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_GETACCOUNTFACTORYBASELINERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT GetAccountFactoryBaselineResult : public ServiceResult + { + public: + struct BaselineItem + { + std::string version; + std::string config; + std::string name; + }; + + + GetAccountFactoryBaselineResult(); + explicit GetAccountFactoryBaselineResult(const std::string &payload); + ~GetAccountFactoryBaselineResult(); + std::string getBaselineId()const; + std::vector getBaselineItems()const; + std::string getType()const; + std::string getDescription()const; + std::string getCreateTime()const; + std::string getBaselineName()const; + std::string getUpdateTime()const; + + protected: + void parse(const std::string &payload); + private: + std::string baselineId_; + std::vector baselineItems_; + std::string type_; + std::string description_; + std::string createTime_; + std::string baselineName_; + std::string updateTime_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_GETACCOUNTFACTORYBASELINERESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/GetEnrolledAccountRequest.h b/governance/include/alibabacloud/governance/model/GetEnrolledAccountRequest.h new file mode 100644 index 000000000..2f00b63bd --- /dev/null +++ b/governance/include/alibabacloud/governance/model/GetEnrolledAccountRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_GETENROLLEDACCOUNTREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_GETENROLLEDACCOUNTREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT GetEnrolledAccountRequest : public RpcServiceRequest { +public: + GetEnrolledAccountRequest(); + ~GetEnrolledAccountRequest(); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + long getAccountUid() const; + void setAccountUid(long accountUid); + +private: + std::string regionId_; + long accountUid_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_GETENROLLEDACCOUNTREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/GetEnrolledAccountResult.h b/governance/include/alibabacloud/governance/model/GetEnrolledAccountResult.h new file mode 100644 index 000000000..144ba6d0d --- /dev/null +++ b/governance/include/alibabacloud/governance/model/GetEnrolledAccountResult.h @@ -0,0 +1,112 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_GETENROLLEDACCOUNTRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_GETENROLLEDACCOUNTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT GetEnrolledAccountResult : public ServiceResult + { + public: + struct ErrorInfo + { + std::string message; + std::string recommend; + std::string requestId; + std::string code; + }; + struct Inputs + { + struct BaselineItem2 + { + std::string version; + std::string config; + bool skip; + std::string name; + }; + std::vector baselineItems1; + std::string displayName; + std::string folderId; + long accountUid; + std::string accountNamePrefix; + long payerAccountUid; + }; + struct BaselineItem + { + std::string version; + std::string config; + bool skip; + std::string name; + }; + struct Progres + { + std::string status; + std::string name; + }; + + + GetEnrolledAccountResult(); + explicit GetEnrolledAccountResult(const std::string &payload); + ~GetEnrolledAccountResult(); + std::string getBaselineId()const; + std::string getStatus()const; + std::vector getProgress()const; + bool getInitialized()const; + long getMasterAccountUid()const; + ErrorInfo getErrorInfo()const; + std::string getCreateTime()const; + std::string getFolderId()const; + long getAccountUid()const; + std::vector getBaselineItems()const; + std::string getDisplayName()const; + std::string getUpdateTime()const; + Inputs getInputs()const; + long getPayerAccountUid()const; + + protected: + void parse(const std::string &payload); + private: + std::string baselineId_; + std::string status_; + std::vector progress_; + bool initialized_; + long masterAccountUid_; + ErrorInfo errorInfo_; + std::string createTime_; + std::string folderId_; + long accountUid_; + std::vector baselineItems_; + std::string displayName_; + std::string updateTime_; + Inputs inputs_; + long payerAccountUid_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_GETENROLLEDACCOUNTRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsRequest.h b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsRequest.h new file mode 100644 index 000000000..09fefdd9a --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsRequest.h @@ -0,0 +1,57 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINEITEMSREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINEITEMSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT ListAccountFactoryBaselineItemsRequest : public RpcServiceRequest { +public: + ListAccountFactoryBaselineItemsRequest(); + ~ListAccountFactoryBaselineItemsRequest(); + std::string getType() const; + void setType(const std::string &type); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::vector getNames() const; + void setNames(const std::vector &names); + std::vector getVersions() const; + void setVersions(const std::vector &versions); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::string type_; + std::string nextToken_; + std::string regionId_; + std::vector names_; + std::vector versions_; + int maxResults_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINEITEMSREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsResult.h b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsResult.h new file mode 100644 index 000000000..58558421c --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselineItemsResult.h @@ -0,0 +1,67 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINEITEMSRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINEITEMSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT ListAccountFactoryBaselineItemsResult : public ServiceResult + { + public: + struct BaselineItem + { + struct DependsOnItem + { + std::string type; + std::string version; + std::string name; + }; + std::vector dependsOn; + std::string type; + std::string description; + std::string version; + std::string name; + }; + + + ListAccountFactoryBaselineItemsResult(); + explicit ListAccountFactoryBaselineItemsResult(const std::string &payload); + ~ListAccountFactoryBaselineItemsResult(); + std::vector getBaselineItems()const; + std::string getNextToken()const; + + protected: + void parse(const std::string &payload); + private: + std::vector baselineItems_; + std::string nextToken_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINEITEMSRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesRequest.h b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesRequest.h new file mode 100644 index 000000000..fe4ad663a --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesRequest.h @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINESREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINESREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT ListAccountFactoryBaselinesRequest : public RpcServiceRequest { +public: + ListAccountFactoryBaselinesRequest(); + ~ListAccountFactoryBaselinesRequest(); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::string nextToken_; + std::string regionId_; + int maxResults_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINESREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesResult.h b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesResult.h new file mode 100644 index 000000000..506397f93 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListAccountFactoryBaselinesResult.h @@ -0,0 +1,62 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINESRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINESRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT ListAccountFactoryBaselinesResult : public ServiceResult + { + public: + struct Baseline + { + std::string baselineId; + std::string type; + std::string description; + std::string createTime; + std::string baselineName; + std::string updateTime; + }; + + + ListAccountFactoryBaselinesResult(); + explicit ListAccountFactoryBaselinesResult(const std::string &payload); + ~ListAccountFactoryBaselinesResult(); + std::string getNextToken()const; + std::vector getBaselines()const; + + protected: + void parse(const std::string &payload); + private: + std::string nextToken_; + std::vector baselines_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTACCOUNTFACTORYBASELINESRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/ListEnrolledAccountsRequest.h b/governance/include/alibabacloud/governance/model/ListEnrolledAccountsRequest.h new file mode 100644 index 000000000..cbe4ba33a --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEnrolledAccountsRequest.h @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTENROLLEDACCOUNTSREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTENROLLEDACCOUNTSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT ListEnrolledAccountsRequest : public RpcServiceRequest { +public: + ListEnrolledAccountsRequest(); + ~ListEnrolledAccountsRequest(); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::string nextToken_; + std::string regionId_; + int maxResults_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTENROLLEDACCOUNTSREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/ListEnrolledAccountsResult.h b/governance/include/alibabacloud/governance/model/ListEnrolledAccountsResult.h new file mode 100644 index 000000000..a7c4d3f26 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEnrolledAccountsResult.h @@ -0,0 +1,64 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTENROLLEDACCOUNTSRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTENROLLEDACCOUNTSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT ListEnrolledAccountsResult : public ServiceResult + { + public: + struct EnrolledAccountsItem + { + std::string baselineId; + std::string status; + std::string createTime; + std::string displayName; + std::string updateTime; + std::string folderId; + long accountUid; + long payerAccountUid; + }; + + + ListEnrolledAccountsResult(); + explicit ListEnrolledAccountsResult(const std::string &payload); + ~ListEnrolledAccountsResult(); + std::string getNextToken()const; + std::vector getEnrolledAccounts()const; + + protected: + void parse(const std::string &payload); + private: + std::string nextToken_; + std::vector enrolledAccounts_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTENROLLEDACCOUNTSRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationMetadataRequest.h b/governance/include/alibabacloud/governance/model/ListEvaluationMetadataRequest.h new file mode 100644 index 000000000..0c1724eaf --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationMetadataRequest.h @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETADATAREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETADATAREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationMetadataRequest : public RpcServiceRequest { +public: + ListEvaluationMetadataRequest(); + ~ListEvaluationMetadataRequest(); + std::string getLanguage() const; + void setLanguage(const std::string &language); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getPartnerCode() const; + void setPartnerCode(const std::string &partnerCode); + +private: + std::string language_; + std::string regionId_; + std::string partnerCode_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETADATAREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationMetadataResult.h b/governance/include/alibabacloud/governance/model/ListEvaluationMetadataResult.h new file mode 100644 index 000000000..1cc828ca8 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationMetadataResult.h @@ -0,0 +1,109 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETADATARESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETADATARESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationMetadataResult : public ServiceResult + { + public: + struct EvaluationMetadataItem + { + struct MetadataItem + { + struct RemediationMetadata + { + struct RemediationItem + { + struct Action + { + struct GuidanceItem + { + std::string buttonName; + std::string buttonRef; + std::string content; + std::string title; + }; + std::vector guidance; + std::string suggestion; + std::string description; + std::string notice; + std::string classification; + std::string costDescription; + }; + std::vector actions; + std::string remediationTarget; + std::string remediationParameters; + std::string analysisDefinition; + std::string remediationType; + }; + std::vector remediation; + }; + struct ResourceMetadata + { + struct ResourcePropertyMetadataItem + { + std::string propertyName; + std::string propertyReference; + std::string displayName; + std::string propertyType; + }; + std::vector resourcePropertyMetadata; + }; + std::string parentId; + std::string category; + std::string description; + std::string scope; + std::string displayName; + std::string recommendationLevel; + std::string stage; + std::string id; + RemediationMetadata remediationMetadata; + ResourceMetadata resourceMetadata; + std::string noRiskDisplayName; + }; + std::string type; + std::vector metadata; + }; + + + ListEvaluationMetadataResult(); + explicit ListEvaluationMetadataResult(const std::string &payload); + ~ListEvaluationMetadataResult(); + std::vector getEvaluationMetadata()const; + + protected: + void parse(const std::string &payload); + private: + std::vector evaluationMetadata_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETADATARESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsRequest.h b/governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsRequest.h new file mode 100644 index 000000000..8d0b1bd9a --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsRequest.h @@ -0,0 +1,57 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETRICDETAILSREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETRICDETAILSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationMetricDetailsRequest : public RpcServiceRequest { +public: + ListEvaluationMetricDetailsRequest(); + ~ListEvaluationMetricDetailsRequest(); + long getAccountId() const; + void setAccountId(long accountId); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getId() const; + void setId(const std::string &id); + std::string getPartnerCode() const; + void setPartnerCode(const std::string &partnerCode); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + long accountId_; + std::string nextToken_; + std::string regionId_; + std::string id_; + std::string partnerCode_; + int maxResults_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETRICDETAILSREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsResult.h b/governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsResult.h new file mode 100644 index 000000000..d75b24ee6 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationMetricDetailsResult.h @@ -0,0 +1,69 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETRICDETAILSRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETRICDETAILSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationMetricDetailsResult : public ServiceResult + { + public: + struct Resource + { + struct ResourcePropertie + { + std::string propertyName; + std::string propertyValue; + }; + std::string resourceId; + std::string resourceOwnerDisplayName; + std::string resourceName; + std::vector resourceProperties; + std::string resourceClassification; + std::string resourceType; + std::string regionId; + long resourceOwnerId; + }; + + + ListEvaluationMetricDetailsResult(); + explicit ListEvaluationMetricDetailsResult(const std::string &payload); + ~ListEvaluationMetricDetailsResult(); + std::string getNextToken()const; + std::vector getResources()const; + + protected: + void parse(const std::string &payload); + private: + std::string nextToken_; + std::vector resources_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONMETRICDETAILSRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationResultsRequest.h b/governance/include/alibabacloud/governance/model/ListEvaluationResultsRequest.h new file mode 100644 index 000000000..addb967a5 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationResultsRequest.h @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONRESULTSREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONRESULTSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationResultsRequest : public RpcServiceRequest { +public: + ListEvaluationResultsRequest(); + ~ListEvaluationResultsRequest(); + long getAccountId() const; + void setAccountId(long accountId); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getPartnerCode() const; + void setPartnerCode(const std::string &partnerCode); + +private: + long accountId_; + std::string regionId_; + std::string partnerCode_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONRESULTSREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationResultsResult.h b/governance/include/alibabacloud/governance/model/ListEvaluationResultsResult.h new file mode 100644 index 000000000..7ff02619b --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationResultsResult.h @@ -0,0 +1,91 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONRESULTSRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONRESULTSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationResultsResult : public ServiceResult + { + public: + struct Results + { + struct CategoryResultsItem + { + std::string id; + double result; + }; + struct GroupResultsItem + { + double potentialScoreIncrease; + std::string id; + }; + struct MetricResult + { + struct ErrorInfo + { + std::string message; + std::string code; + }; + struct ResourcesSummary + { + int nonCompliant; + }; + std::string status; + ResourcesSummary resourcesSummary; + std::string evaluationTime; + ErrorInfo errorInfo; + std::string risk; + std::string id; + double result; + }; + std::string status; + std::vector groupResults; + std::string evaluationTime; + std::vector metricResults; + std::vector categoryResults; + double totalScore; + }; + + + ListEvaluationResultsResult(); + explicit ListEvaluationResultsResult(const std::string &payload); + ~ListEvaluationResultsResult(); + long getAccountId()const; + Results getResults()const; + + protected: + void parse(const std::string &payload); + private: + long accountId_; + Results results_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONRESULTSRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryRequest.h b/governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryRequest.h new file mode 100644 index 000000000..551cb6ae3 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryRequest.h @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONSCOREHISTORYREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONSCOREHISTORYREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationScoreHistoryRequest : public RpcServiceRequest { +public: + ListEvaluationScoreHistoryRequest(); + ~ListEvaluationScoreHistoryRequest(); + std::string getStartDate() const; + void setStartDate(const std::string &startDate); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getPartnerCode() const; + void setPartnerCode(const std::string &partnerCode); + std::string getEndDate() const; + void setEndDate(const std::string &endDate); + bool getShowScoreDiff() const; + void setShowScoreDiff(bool showScoreDiff); + +private: + std::string startDate_; + std::string regionId_; + std::string partnerCode_; + std::string endDate_; + bool showScoreDiff_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONSCOREHISTORYREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryResult.h b/governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryResult.h new file mode 100644 index 000000000..0e9c72782 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/ListEvaluationScoreHistoryResult.h @@ -0,0 +1,82 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONSCOREHISTORYRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONSCOREHISTORYRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT ListEvaluationScoreHistoryResult : public ServiceResult + { + public: + struct ScoreDiff + { + struct CategoryScoreDiff + { + std::string currentEvaluationTime; + std::string scoreDiff; + std::string id; + std::string previousEvaluationTime; + }; + struct MetricScoreDiff + { + std::string currentEvaluationTime; + std::string category; + std::string scoreDiff; + std::string id; + std::string previousEvaluationTime; + }; + std::vector metricScoreDiffs; + std::vector categoryScoreDiffs; + }; + struct ScoreHistory + { + struct TotalScoreHistoryItem + { + double score; + std::string evaluationTime; + }; + std::vector totalScoreHistory; + }; + + + ListEvaluationScoreHistoryResult(); + explicit ListEvaluationScoreHistoryResult(const std::string &payload); + ~ListEvaluationScoreHistoryResult(); + ScoreDiff getScoreDiff()const; + ScoreHistory getScoreHistory()const; + + protected: + void parse(const std::string &payload); + private: + ScoreDiff scoreDiff_; + ScoreHistory scoreHistory_; + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_LISTEVALUATIONSCOREHISTORYRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/RunEvaluationRequest.h b/governance/include/alibabacloud/governance/model/RunEvaluationRequest.h new file mode 100644 index 000000000..50c411ffb --- /dev/null +++ b/governance/include/alibabacloud/governance/model/RunEvaluationRequest.h @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_RUNEVALUATIONREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_RUNEVALUATIONREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT RunEvaluationRequest : public RpcServiceRequest { +public: + RunEvaluationRequest(); + ~RunEvaluationRequest(); + long getAccountId() const; + void setAccountId(long accountId); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getScope() const; + void setScope(const std::string &scope); + std::string getPartnerCode() const; + void setPartnerCode(const std::string &partnerCode); + +private: + long accountId_; + std::string regionId_; + std::string scope_; + std::string partnerCode_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_RUNEVALUATIONREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/RunEvaluationResult.h b/governance/include/alibabacloud/governance/model/RunEvaluationResult.h new file mode 100644 index 000000000..5450eb818 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/RunEvaluationResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_RUNEVALUATIONRESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_RUNEVALUATIONRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT RunEvaluationResult : public ServiceResult + { + public: + + + RunEvaluationResult(); + explicit RunEvaluationResult(const std::string &payload); + ~RunEvaluationResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_RUNEVALUATIONRESULT_H_ \ No newline at end of file diff --git a/governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineRequest.h b/governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineRequest.h new file mode 100644 index 000000000..bae368171 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineRequest.h @@ -0,0 +1,59 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_UPDATEACCOUNTFACTORYBASELINEREQUEST_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_UPDATEACCOUNTFACTORYBASELINEREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Governance { +namespace Model { +class ALIBABACLOUD_GOVERNANCE_EXPORT UpdateAccountFactoryBaselineRequest : public RpcServiceRequest { +public: + struct BaselineItems { + std::string name; + std::string config; + std::string version; + }; + UpdateAccountFactoryBaselineRequest(); + ~UpdateAccountFactoryBaselineRequest(); + std::string getDescription() const; + void setDescription(const std::string &description); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getBaselineName() const; + void setBaselineName(const std::string &baselineName); + std::string getBaselineId() const; + void setBaselineId(const std::string &baselineId); + std::vector getBaselineItems() const; + void setBaselineItems(const std::vector &baselineItems); + +private: + std::string description_; + std::string regionId_; + std::string baselineName_; + std::string baselineId_; + std::vector baselineItems_; +}; +} // namespace Model +} // namespace Governance +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_UPDATEACCOUNTFACTORYBASELINEREQUEST_H_ diff --git a/governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineResult.h b/governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineResult.h new file mode 100644 index 000000000..aa98afae8 --- /dev/null +++ b/governance/include/alibabacloud/governance/model/UpdateAccountFactoryBaselineResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_GOVERNANCE_MODEL_UPDATEACCOUNTFACTORYBASELINERESULT_H_ +#define ALIBABACLOUD_GOVERNANCE_MODEL_UPDATEACCOUNTFACTORYBASELINERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Governance + { + namespace Model + { + class ALIBABACLOUD_GOVERNANCE_EXPORT UpdateAccountFactoryBaselineResult : public ServiceResult + { + public: + + + UpdateAccountFactoryBaselineResult(); + explicit UpdateAccountFactoryBaselineResult(const std::string &payload); + ~UpdateAccountFactoryBaselineResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_GOVERNANCE_MODEL_UPDATEACCOUNTFACTORYBASELINERESULT_H_ \ No newline at end of file diff --git a/governance/src/GovernanceClient.cc b/governance/src/GovernanceClient.cc new file mode 100644 index 000000000..a5d115b36 --- /dev/null +++ b/governance/src/GovernanceClient.cc @@ -0,0 +1,593 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud; +using namespace AlibabaCloud::Location; +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +namespace +{ + const std::string SERVICE_NAME = "governance"; +} + +GovernanceClient::GovernanceClient(const Credentials &credentials, const ClientConfiguration &configuration) : + RpcServiceClient(SERVICE_NAME, std::make_shared(credentials), configuration) +{ + auto locationClient = std::make_shared(credentials, configuration); + endpointProvider_ = std::make_shared(locationClient, configuration.regionId(), SERVICE_NAME, "governance"); +} + +GovernanceClient::GovernanceClient(const std::shared_ptr& credentialsProvider, const ClientConfiguration & configuration) : + RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration) +{ + auto locationClient = std::make_shared(credentialsProvider, configuration); + endpointProvider_ = std::make_shared(locationClient, configuration.regionId(), SERVICE_NAME, "governance"); +} + +GovernanceClient::GovernanceClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) : + RpcServiceClient(SERVICE_NAME, std::make_shared(accessKeyId, accessKeySecret), configuration) +{ + auto locationClient = std::make_shared(accessKeyId, accessKeySecret, configuration); + endpointProvider_ = std::make_shared(locationClient, configuration.regionId(), SERVICE_NAME, "governance"); +} + +GovernanceClient::~GovernanceClient() +{} + +GovernanceClient::BatchEnrollAccountsOutcome GovernanceClient::batchEnrollAccounts(const BatchEnrollAccountsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return BatchEnrollAccountsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return BatchEnrollAccountsOutcome(BatchEnrollAccountsResult(outcome.result())); + else + return BatchEnrollAccountsOutcome(outcome.error()); +} + +void GovernanceClient::batchEnrollAccountsAsync(const BatchEnrollAccountsRequest& request, const BatchEnrollAccountsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, batchEnrollAccounts(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::BatchEnrollAccountsOutcomeCallable GovernanceClient::batchEnrollAccountsCallable(const BatchEnrollAccountsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->batchEnrollAccounts(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::CreateAccountFactoryBaselineOutcome GovernanceClient::createAccountFactoryBaseline(const CreateAccountFactoryBaselineRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateAccountFactoryBaselineOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateAccountFactoryBaselineOutcome(CreateAccountFactoryBaselineResult(outcome.result())); + else + return CreateAccountFactoryBaselineOutcome(outcome.error()); +} + +void GovernanceClient::createAccountFactoryBaselineAsync(const CreateAccountFactoryBaselineRequest& request, const CreateAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createAccountFactoryBaseline(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::CreateAccountFactoryBaselineOutcomeCallable GovernanceClient::createAccountFactoryBaselineCallable(const CreateAccountFactoryBaselineRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createAccountFactoryBaseline(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::DeleteAccountFactoryBaselineOutcome GovernanceClient::deleteAccountFactoryBaseline(const DeleteAccountFactoryBaselineRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteAccountFactoryBaselineOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteAccountFactoryBaselineOutcome(DeleteAccountFactoryBaselineResult(outcome.result())); + else + return DeleteAccountFactoryBaselineOutcome(outcome.error()); +} + +void GovernanceClient::deleteAccountFactoryBaselineAsync(const DeleteAccountFactoryBaselineRequest& request, const DeleteAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteAccountFactoryBaseline(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::DeleteAccountFactoryBaselineOutcomeCallable GovernanceClient::deleteAccountFactoryBaselineCallable(const DeleteAccountFactoryBaselineRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteAccountFactoryBaseline(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::EnrollAccountOutcome GovernanceClient::enrollAccount(const EnrollAccountRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return EnrollAccountOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return EnrollAccountOutcome(EnrollAccountResult(outcome.result())); + else + return EnrollAccountOutcome(outcome.error()); +} + +void GovernanceClient::enrollAccountAsync(const EnrollAccountRequest& request, const EnrollAccountAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, enrollAccount(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::EnrollAccountOutcomeCallable GovernanceClient::enrollAccountCallable(const EnrollAccountRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->enrollAccount(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::GetAccountFactoryBaselineOutcome GovernanceClient::getAccountFactoryBaseline(const GetAccountFactoryBaselineRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetAccountFactoryBaselineOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetAccountFactoryBaselineOutcome(GetAccountFactoryBaselineResult(outcome.result())); + else + return GetAccountFactoryBaselineOutcome(outcome.error()); +} + +void GovernanceClient::getAccountFactoryBaselineAsync(const GetAccountFactoryBaselineRequest& request, const GetAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getAccountFactoryBaseline(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::GetAccountFactoryBaselineOutcomeCallable GovernanceClient::getAccountFactoryBaselineCallable(const GetAccountFactoryBaselineRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getAccountFactoryBaseline(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::GetEnrolledAccountOutcome GovernanceClient::getEnrolledAccount(const GetEnrolledAccountRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetEnrolledAccountOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetEnrolledAccountOutcome(GetEnrolledAccountResult(outcome.result())); + else + return GetEnrolledAccountOutcome(outcome.error()); +} + +void GovernanceClient::getEnrolledAccountAsync(const GetEnrolledAccountRequest& request, const GetEnrolledAccountAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getEnrolledAccount(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::GetEnrolledAccountOutcomeCallable GovernanceClient::getEnrolledAccountCallable(const GetEnrolledAccountRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getEnrolledAccount(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::ListAccountFactoryBaselineItemsOutcome GovernanceClient::listAccountFactoryBaselineItems(const ListAccountFactoryBaselineItemsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListAccountFactoryBaselineItemsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListAccountFactoryBaselineItemsOutcome(ListAccountFactoryBaselineItemsResult(outcome.result())); + else + return ListAccountFactoryBaselineItemsOutcome(outcome.error()); +} + +void GovernanceClient::listAccountFactoryBaselineItemsAsync(const ListAccountFactoryBaselineItemsRequest& request, const ListAccountFactoryBaselineItemsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listAccountFactoryBaselineItems(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::ListAccountFactoryBaselineItemsOutcomeCallable GovernanceClient::listAccountFactoryBaselineItemsCallable(const ListAccountFactoryBaselineItemsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listAccountFactoryBaselineItems(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::ListAccountFactoryBaselinesOutcome GovernanceClient::listAccountFactoryBaselines(const ListAccountFactoryBaselinesRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListAccountFactoryBaselinesOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListAccountFactoryBaselinesOutcome(ListAccountFactoryBaselinesResult(outcome.result())); + else + return ListAccountFactoryBaselinesOutcome(outcome.error()); +} + +void GovernanceClient::listAccountFactoryBaselinesAsync(const ListAccountFactoryBaselinesRequest& request, const ListAccountFactoryBaselinesAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listAccountFactoryBaselines(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::ListAccountFactoryBaselinesOutcomeCallable GovernanceClient::listAccountFactoryBaselinesCallable(const ListAccountFactoryBaselinesRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listAccountFactoryBaselines(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::ListEnrolledAccountsOutcome GovernanceClient::listEnrolledAccounts(const ListEnrolledAccountsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListEnrolledAccountsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListEnrolledAccountsOutcome(ListEnrolledAccountsResult(outcome.result())); + else + return ListEnrolledAccountsOutcome(outcome.error()); +} + +void GovernanceClient::listEnrolledAccountsAsync(const ListEnrolledAccountsRequest& request, const ListEnrolledAccountsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listEnrolledAccounts(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::ListEnrolledAccountsOutcomeCallable GovernanceClient::listEnrolledAccountsCallable(const ListEnrolledAccountsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listEnrolledAccounts(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::ListEvaluationMetadataOutcome GovernanceClient::listEvaluationMetadata(const ListEvaluationMetadataRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListEvaluationMetadataOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListEvaluationMetadataOutcome(ListEvaluationMetadataResult(outcome.result())); + else + return ListEvaluationMetadataOutcome(outcome.error()); +} + +void GovernanceClient::listEvaluationMetadataAsync(const ListEvaluationMetadataRequest& request, const ListEvaluationMetadataAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listEvaluationMetadata(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::ListEvaluationMetadataOutcomeCallable GovernanceClient::listEvaluationMetadataCallable(const ListEvaluationMetadataRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listEvaluationMetadata(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::ListEvaluationMetricDetailsOutcome GovernanceClient::listEvaluationMetricDetails(const ListEvaluationMetricDetailsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListEvaluationMetricDetailsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListEvaluationMetricDetailsOutcome(ListEvaluationMetricDetailsResult(outcome.result())); + else + return ListEvaluationMetricDetailsOutcome(outcome.error()); +} + +void GovernanceClient::listEvaluationMetricDetailsAsync(const ListEvaluationMetricDetailsRequest& request, const ListEvaluationMetricDetailsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listEvaluationMetricDetails(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::ListEvaluationMetricDetailsOutcomeCallable GovernanceClient::listEvaluationMetricDetailsCallable(const ListEvaluationMetricDetailsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listEvaluationMetricDetails(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::ListEvaluationResultsOutcome GovernanceClient::listEvaluationResults(const ListEvaluationResultsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListEvaluationResultsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListEvaluationResultsOutcome(ListEvaluationResultsResult(outcome.result())); + else + return ListEvaluationResultsOutcome(outcome.error()); +} + +void GovernanceClient::listEvaluationResultsAsync(const ListEvaluationResultsRequest& request, const ListEvaluationResultsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listEvaluationResults(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::ListEvaluationResultsOutcomeCallable GovernanceClient::listEvaluationResultsCallable(const ListEvaluationResultsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listEvaluationResults(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::ListEvaluationScoreHistoryOutcome GovernanceClient::listEvaluationScoreHistory(const ListEvaluationScoreHistoryRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListEvaluationScoreHistoryOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListEvaluationScoreHistoryOutcome(ListEvaluationScoreHistoryResult(outcome.result())); + else + return ListEvaluationScoreHistoryOutcome(outcome.error()); +} + +void GovernanceClient::listEvaluationScoreHistoryAsync(const ListEvaluationScoreHistoryRequest& request, const ListEvaluationScoreHistoryAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listEvaluationScoreHistory(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::ListEvaluationScoreHistoryOutcomeCallable GovernanceClient::listEvaluationScoreHistoryCallable(const ListEvaluationScoreHistoryRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listEvaluationScoreHistory(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::RunEvaluationOutcome GovernanceClient::runEvaluation(const RunEvaluationRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return RunEvaluationOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return RunEvaluationOutcome(RunEvaluationResult(outcome.result())); + else + return RunEvaluationOutcome(outcome.error()); +} + +void GovernanceClient::runEvaluationAsync(const RunEvaluationRequest& request, const RunEvaluationAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, runEvaluation(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::RunEvaluationOutcomeCallable GovernanceClient::runEvaluationCallable(const RunEvaluationRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->runEvaluation(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +GovernanceClient::UpdateAccountFactoryBaselineOutcome GovernanceClient::updateAccountFactoryBaseline(const UpdateAccountFactoryBaselineRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return UpdateAccountFactoryBaselineOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return UpdateAccountFactoryBaselineOutcome(UpdateAccountFactoryBaselineResult(outcome.result())); + else + return UpdateAccountFactoryBaselineOutcome(outcome.error()); +} + +void GovernanceClient::updateAccountFactoryBaselineAsync(const UpdateAccountFactoryBaselineRequest& request, const UpdateAccountFactoryBaselineAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, updateAccountFactoryBaseline(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +GovernanceClient::UpdateAccountFactoryBaselineOutcomeCallable GovernanceClient::updateAccountFactoryBaselineCallable(const UpdateAccountFactoryBaselineRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->updateAccountFactoryBaseline(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + diff --git a/governance/src/model/BatchEnrollAccountsRequest.cc b/governance/src/model/BatchEnrollAccountsRequest.cc new file mode 100644 index 000000000..2ca11705d --- /dev/null +++ b/governance/src/model/BatchEnrollAccountsRequest.cc @@ -0,0 +1,70 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::BatchEnrollAccountsRequest; + +BatchEnrollAccountsRequest::BatchEnrollAccountsRequest() + : RpcServiceRequest("governance", "2021-01-20", "BatchEnrollAccounts") { + setMethod(HttpRequest::Method::Post); +} + +BatchEnrollAccountsRequest::~BatchEnrollAccountsRequest() {} + +std::string BatchEnrollAccountsRequest::getRegionId() const { + return regionId_; +} + +void BatchEnrollAccountsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string BatchEnrollAccountsRequest::getBaselineId() const { + return baselineId_; +} + +void BatchEnrollAccountsRequest::setBaselineId(const std::string &baselineId) { + baselineId_ = baselineId; + setParameter(std::string("BaselineId"), baselineId); +} + +std::vector BatchEnrollAccountsRequest::getBaselineItems() const { + return baselineItems_; +} + +void BatchEnrollAccountsRequest::setBaselineItems(const std::vector &baselineItems) { + baselineItems_ = baselineItems; + for(int dep1 = 0; dep1 != baselineItems.size(); dep1++) { + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Name", baselineItems[dep1].name); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Skip", baselineItems[dep1].skip ? "true" : "false"); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Config", baselineItems[dep1].config); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Version", baselineItems[dep1].version); + } +} + +std::vector BatchEnrollAccountsRequest::getAccounts() const { + return accounts_; +} + +void BatchEnrollAccountsRequest::setAccounts(const std::vector &accounts) { + accounts_ = accounts; + for(int dep1 = 0; dep1 != accounts.size(); dep1++) { + setParameter(std::string("Accounts") + "." + std::to_string(dep1 + 1) + ".AccountUid", std::to_string(accounts[dep1].accountUid)); + } +} + diff --git a/governance/src/model/BatchEnrollAccountsResult.cc b/governance/src/model/BatchEnrollAccountsResult.cc new file mode 100644 index 000000000..3a41be6d9 --- /dev/null +++ b/governance/src/model/BatchEnrollAccountsResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +BatchEnrollAccountsResult::BatchEnrollAccountsResult() : + ServiceResult() +{} + +BatchEnrollAccountsResult::BatchEnrollAccountsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +BatchEnrollAccountsResult::~BatchEnrollAccountsResult() +{} + +void BatchEnrollAccountsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/governance/src/model/CreateAccountFactoryBaselineRequest.cc b/governance/src/model/CreateAccountFactoryBaselineRequest.cc new file mode 100644 index 000000000..6c9513d49 --- /dev/null +++ b/governance/src/model/CreateAccountFactoryBaselineRequest.cc @@ -0,0 +1,67 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::CreateAccountFactoryBaselineRequest; + +CreateAccountFactoryBaselineRequest::CreateAccountFactoryBaselineRequest() + : RpcServiceRequest("governance", "2021-01-20", "CreateAccountFactoryBaseline") { + setMethod(HttpRequest::Method::Post); +} + +CreateAccountFactoryBaselineRequest::~CreateAccountFactoryBaselineRequest() {} + +std::string CreateAccountFactoryBaselineRequest::getDescription() const { + return description_; +} + +void CreateAccountFactoryBaselineRequest::setDescription(const std::string &description) { + description_ = description; + setParameter(std::string("Description"), description); +} + +std::string CreateAccountFactoryBaselineRequest::getRegionId() const { + return regionId_; +} + +void CreateAccountFactoryBaselineRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string CreateAccountFactoryBaselineRequest::getBaselineName() const { + return baselineName_; +} + +void CreateAccountFactoryBaselineRequest::setBaselineName(const std::string &baselineName) { + baselineName_ = baselineName; + setParameter(std::string("BaselineName"), baselineName); +} + +std::vector CreateAccountFactoryBaselineRequest::getBaselineItems() const { + return baselineItems_; +} + +void CreateAccountFactoryBaselineRequest::setBaselineItems(const std::vector &baselineItems) { + baselineItems_ = baselineItems; + for(int dep1 = 0; dep1 != baselineItems.size(); dep1++) { + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Name", baselineItems[dep1].name); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Config", baselineItems[dep1].config); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Version", baselineItems[dep1].version); + } +} + diff --git a/governance/src/model/CreateAccountFactoryBaselineResult.cc b/governance/src/model/CreateAccountFactoryBaselineResult.cc new file mode 100644 index 000000000..c7f1ee07a --- /dev/null +++ b/governance/src/model/CreateAccountFactoryBaselineResult.cc @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +CreateAccountFactoryBaselineResult::CreateAccountFactoryBaselineResult() : + ServiceResult() +{} + +CreateAccountFactoryBaselineResult::CreateAccountFactoryBaselineResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateAccountFactoryBaselineResult::~CreateAccountFactoryBaselineResult() +{} + +void CreateAccountFactoryBaselineResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["BaselineId"].isNull()) + baselineId_ = value["BaselineId"].asString(); + +} + +std::string CreateAccountFactoryBaselineResult::getBaselineId()const +{ + return baselineId_; +} + diff --git a/governance/src/model/DeleteAccountFactoryBaselineRequest.cc b/governance/src/model/DeleteAccountFactoryBaselineRequest.cc new file mode 100644 index 000000000..4d6fe1346 --- /dev/null +++ b/governance/src/model/DeleteAccountFactoryBaselineRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::DeleteAccountFactoryBaselineRequest; + +DeleteAccountFactoryBaselineRequest::DeleteAccountFactoryBaselineRequest() + : RpcServiceRequest("governance", "2021-01-20", "DeleteAccountFactoryBaseline") { + setMethod(HttpRequest::Method::Post); +} + +DeleteAccountFactoryBaselineRequest::~DeleteAccountFactoryBaselineRequest() {} + +std::string DeleteAccountFactoryBaselineRequest::getRegionId() const { + return regionId_; +} + +void DeleteAccountFactoryBaselineRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string DeleteAccountFactoryBaselineRequest::getBaselineId() const { + return baselineId_; +} + +void DeleteAccountFactoryBaselineRequest::setBaselineId(const std::string &baselineId) { + baselineId_ = baselineId; + setParameter(std::string("BaselineId"), baselineId); +} + diff --git a/governance/src/model/DeleteAccountFactoryBaselineResult.cc b/governance/src/model/DeleteAccountFactoryBaselineResult.cc new file mode 100644 index 000000000..a63a7d62d --- /dev/null +++ b/governance/src/model/DeleteAccountFactoryBaselineResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +DeleteAccountFactoryBaselineResult::DeleteAccountFactoryBaselineResult() : + ServiceResult() +{} + +DeleteAccountFactoryBaselineResult::DeleteAccountFactoryBaselineResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteAccountFactoryBaselineResult::~DeleteAccountFactoryBaselineResult() +{} + +void DeleteAccountFactoryBaselineResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/governance/src/model/EnrollAccountRequest.cc b/governance/src/model/EnrollAccountRequest.cc new file mode 100644 index 000000000..22fc8d7f7 --- /dev/null +++ b/governance/src/model/EnrollAccountRequest.cc @@ -0,0 +1,113 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::EnrollAccountRequest; + +EnrollAccountRequest::EnrollAccountRequest() + : RpcServiceRequest("governance", "2021-01-20", "EnrollAccount") { + setMethod(HttpRequest::Method::Post); +} + +EnrollAccountRequest::~EnrollAccountRequest() {} + +std::string EnrollAccountRequest::getFolderId() const { + return folderId_; +} + +void EnrollAccountRequest::setFolderId(const std::string &folderId) { + folderId_ = folderId; + setParameter(std::string("FolderId"), folderId); +} + +std::string EnrollAccountRequest::getRegionId() const { + return regionId_; +} + +void EnrollAccountRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +long EnrollAccountRequest::getPayerAccountUid() const { + return payerAccountUid_; +} + +void EnrollAccountRequest::setPayerAccountUid(long payerAccountUid) { + payerAccountUid_ = payerAccountUid; + setParameter(std::string("PayerAccountUid"), std::to_string(payerAccountUid)); +} + +long EnrollAccountRequest::getAccountUid() const { + return accountUid_; +} + +void EnrollAccountRequest::setAccountUid(long accountUid) { + accountUid_ = accountUid; + setParameter(std::string("AccountUid"), std::to_string(accountUid)); +} + +std::string EnrollAccountRequest::getAccountNamePrefix() const { + return accountNamePrefix_; +} + +void EnrollAccountRequest::setAccountNamePrefix(const std::string &accountNamePrefix) { + accountNamePrefix_ = accountNamePrefix; + setParameter(std::string("AccountNamePrefix"), accountNamePrefix); +} + +std::string EnrollAccountRequest::getResellAccountType() const { + return resellAccountType_; +} + +void EnrollAccountRequest::setResellAccountType(const std::string &resellAccountType) { + resellAccountType_ = resellAccountType; + setParameter(std::string("ResellAccountType"), resellAccountType); +} + +std::string EnrollAccountRequest::getBaselineId() const { + return baselineId_; +} + +void EnrollAccountRequest::setBaselineId(const std::string &baselineId) { + baselineId_ = baselineId; + setParameter(std::string("BaselineId"), baselineId); +} + +std::vector EnrollAccountRequest::getBaselineItems() const { + return baselineItems_; +} + +void EnrollAccountRequest::setBaselineItems(const std::vector &baselineItems) { + baselineItems_ = baselineItems; + for(int dep1 = 0; dep1 != baselineItems.size(); dep1++) { + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Name", baselineItems[dep1].name); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Skip", baselineItems[dep1].skip ? "true" : "false"); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Config", baselineItems[dep1].config); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Version", baselineItems[dep1].version); + } +} + +std::string EnrollAccountRequest::getDisplayName() const { + return displayName_; +} + +void EnrollAccountRequest::setDisplayName(const std::string &displayName) { + displayName_ = displayName; + setParameter(std::string("DisplayName"), displayName); +} + diff --git a/governance/src/model/EnrollAccountResult.cc b/governance/src/model/EnrollAccountResult.cc new file mode 100644 index 000000000..00d3436d3 --- /dev/null +++ b/governance/src/model/EnrollAccountResult.cc @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +EnrollAccountResult::EnrollAccountResult() : + ServiceResult() +{} + +EnrollAccountResult::EnrollAccountResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +EnrollAccountResult::~EnrollAccountResult() +{} + +void EnrollAccountResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["AccountUid"].isNull()) + accountUid_ = std::stol(value["AccountUid"].asString()); + +} + +long EnrollAccountResult::getAccountUid()const +{ + return accountUid_; +} + diff --git a/governance/src/model/GetAccountFactoryBaselineRequest.cc b/governance/src/model/GetAccountFactoryBaselineRequest.cc new file mode 100644 index 000000000..338b3b976 --- /dev/null +++ b/governance/src/model/GetAccountFactoryBaselineRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::GetAccountFactoryBaselineRequest; + +GetAccountFactoryBaselineRequest::GetAccountFactoryBaselineRequest() + : RpcServiceRequest("governance", "2021-01-20", "GetAccountFactoryBaseline") { + setMethod(HttpRequest::Method::Post); +} + +GetAccountFactoryBaselineRequest::~GetAccountFactoryBaselineRequest() {} + +std::string GetAccountFactoryBaselineRequest::getRegionId() const { + return regionId_; +} + +void GetAccountFactoryBaselineRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string GetAccountFactoryBaselineRequest::getBaselineId() const { + return baselineId_; +} + +void GetAccountFactoryBaselineRequest::setBaselineId(const std::string &baselineId) { + baselineId_ = baselineId; + setParameter(std::string("BaselineId"), baselineId); +} + diff --git a/governance/src/model/GetAccountFactoryBaselineResult.cc b/governance/src/model/GetAccountFactoryBaselineResult.cc new file mode 100644 index 000000000..100c96d05 --- /dev/null +++ b/governance/src/model/GetAccountFactoryBaselineResult.cc @@ -0,0 +1,103 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +GetAccountFactoryBaselineResult::GetAccountFactoryBaselineResult() : + ServiceResult() +{} + +GetAccountFactoryBaselineResult::GetAccountFactoryBaselineResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetAccountFactoryBaselineResult::~GetAccountFactoryBaselineResult() +{} + +void GetAccountFactoryBaselineResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allBaselineItemsNode = value["BaselineItems"]["BaselineItem"]; + for (auto valueBaselineItemsBaselineItem : allBaselineItemsNode) + { + BaselineItem baselineItemsObject; + if(!valueBaselineItemsBaselineItem["Config"].isNull()) + baselineItemsObject.config = valueBaselineItemsBaselineItem["Config"].asString(); + if(!valueBaselineItemsBaselineItem["Name"].isNull()) + baselineItemsObject.name = valueBaselineItemsBaselineItem["Name"].asString(); + if(!valueBaselineItemsBaselineItem["Version"].isNull()) + baselineItemsObject.version = valueBaselineItemsBaselineItem["Version"].asString(); + baselineItems_.push_back(baselineItemsObject); + } + if(!value["BaselineId"].isNull()) + baselineId_ = value["BaselineId"].asString(); + if(!value["BaselineName"].isNull()) + baselineName_ = value["BaselineName"].asString(); + if(!value["CreateTime"].isNull()) + createTime_ = value["CreateTime"].asString(); + if(!value["Description"].isNull()) + description_ = value["Description"].asString(); + if(!value["Type"].isNull()) + type_ = value["Type"].asString(); + if(!value["UpdateTime"].isNull()) + updateTime_ = value["UpdateTime"].asString(); + +} + +std::string GetAccountFactoryBaselineResult::getBaselineId()const +{ + return baselineId_; +} + +std::vector GetAccountFactoryBaselineResult::getBaselineItems()const +{ + return baselineItems_; +} + +std::string GetAccountFactoryBaselineResult::getType()const +{ + return type_; +} + +std::string GetAccountFactoryBaselineResult::getDescription()const +{ + return description_; +} + +std::string GetAccountFactoryBaselineResult::getCreateTime()const +{ + return createTime_; +} + +std::string GetAccountFactoryBaselineResult::getBaselineName()const +{ + return baselineName_; +} + +std::string GetAccountFactoryBaselineResult::getUpdateTime()const +{ + return updateTime_; +} + diff --git a/governance/src/model/GetEnrolledAccountRequest.cc b/governance/src/model/GetEnrolledAccountRequest.cc new file mode 100644 index 000000000..670194a55 --- /dev/null +++ b/governance/src/model/GetEnrolledAccountRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::GetEnrolledAccountRequest; + +GetEnrolledAccountRequest::GetEnrolledAccountRequest() + : RpcServiceRequest("governance", "2021-01-20", "GetEnrolledAccount") { + setMethod(HttpRequest::Method::Post); +} + +GetEnrolledAccountRequest::~GetEnrolledAccountRequest() {} + +std::string GetEnrolledAccountRequest::getRegionId() const { + return regionId_; +} + +void GetEnrolledAccountRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +long GetEnrolledAccountRequest::getAccountUid() const { + return accountUid_; +} + +void GetEnrolledAccountRequest::setAccountUid(long accountUid) { + accountUid_ = accountUid; + setParameter(std::string("AccountUid"), std::to_string(accountUid)); +} + diff --git a/governance/src/model/GetEnrolledAccountResult.cc b/governance/src/model/GetEnrolledAccountResult.cc new file mode 100644 index 000000000..40cbf1785 --- /dev/null +++ b/governance/src/model/GetEnrolledAccountResult.cc @@ -0,0 +1,192 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +GetEnrolledAccountResult::GetEnrolledAccountResult() : + ServiceResult() +{} + +GetEnrolledAccountResult::GetEnrolledAccountResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetEnrolledAccountResult::~GetEnrolledAccountResult() +{} + +void GetEnrolledAccountResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allBaselineItemsNode = value["BaselineItems"]["BaselineItem"]; + for (auto valueBaselineItemsBaselineItem : allBaselineItemsNode) + { + BaselineItem baselineItemsObject; + if(!valueBaselineItemsBaselineItem["Config"].isNull()) + baselineItemsObject.config = valueBaselineItemsBaselineItem["Config"].asString(); + if(!valueBaselineItemsBaselineItem["Name"].isNull()) + baselineItemsObject.name = valueBaselineItemsBaselineItem["Name"].asString(); + if(!valueBaselineItemsBaselineItem["Skip"].isNull()) + baselineItemsObject.skip = valueBaselineItemsBaselineItem["Skip"].asString() == "true"; + if(!valueBaselineItemsBaselineItem["Version"].isNull()) + baselineItemsObject.version = valueBaselineItemsBaselineItem["Version"].asString(); + baselineItems_.push_back(baselineItemsObject); + } + auto allProgressNode = value["Progress"]["Progres"]; + for (auto valueProgressProgres : allProgressNode) + { + Progres progressObject; + if(!valueProgressProgres["Name"].isNull()) + progressObject.name = valueProgressProgres["Name"].asString(); + if(!valueProgressProgres["Status"].isNull()) + progressObject.status = valueProgressProgres["Status"].asString(); + progress_.push_back(progressObject); + } + auto errorInfoNode = value["ErrorInfo"]; + if(!errorInfoNode["Code"].isNull()) + errorInfo_.code = errorInfoNode["Code"].asString(); + if(!errorInfoNode["Message"].isNull()) + errorInfo_.message = errorInfoNode["Message"].asString(); + if(!errorInfoNode["Recommend"].isNull()) + errorInfo_.recommend = errorInfoNode["Recommend"].asString(); + if(!errorInfoNode["RequestId"].isNull()) + errorInfo_.requestId = errorInfoNode["RequestId"].asString(); + auto inputsNode = value["Inputs"]; + if(!inputsNode["AccountNamePrefix"].isNull()) + inputs_.accountNamePrefix = inputsNode["AccountNamePrefix"].asString(); + if(!inputsNode["AccountUid"].isNull()) + inputs_.accountUid = std::stol(inputsNode["AccountUid"].asString()); + if(!inputsNode["DisplayName"].isNull()) + inputs_.displayName = inputsNode["DisplayName"].asString(); + if(!inputsNode["FolderId"].isNull()) + inputs_.folderId = inputsNode["FolderId"].asString(); + if(!inputsNode["PayerAccountUid"].isNull()) + inputs_.payerAccountUid = std::stol(inputsNode["PayerAccountUid"].asString()); + auto allBaselineItems1Node = inputsNode["BaselineItems"]["BaselineItem"]; + for (auto inputsNodeBaselineItemsBaselineItem : allBaselineItems1Node) + { + Inputs::BaselineItem2 baselineItem2Object; + if(!inputsNodeBaselineItemsBaselineItem["Config"].isNull()) + baselineItem2Object.config = inputsNodeBaselineItemsBaselineItem["Config"].asString(); + if(!inputsNodeBaselineItemsBaselineItem["Name"].isNull()) + baselineItem2Object.name = inputsNodeBaselineItemsBaselineItem["Name"].asString(); + if(!inputsNodeBaselineItemsBaselineItem["Skip"].isNull()) + baselineItem2Object.skip = inputsNodeBaselineItemsBaselineItem["Skip"].asString() == "true"; + if(!inputsNodeBaselineItemsBaselineItem["Version"].isNull()) + baselineItem2Object.version = inputsNodeBaselineItemsBaselineItem["Version"].asString(); + inputs_.baselineItems1.push_back(baselineItem2Object); + } + if(!value["AccountUid"].isNull()) + accountUid_ = std::stol(value["AccountUid"].asString()); + if(!value["BaselineId"].isNull()) + baselineId_ = value["BaselineId"].asString(); + if(!value["CreateTime"].isNull()) + createTime_ = value["CreateTime"].asString(); + if(!value["DisplayName"].isNull()) + displayName_ = value["DisplayName"].asString(); + if(!value["FolderId"].isNull()) + folderId_ = value["FolderId"].asString(); + if(!value["Initialized"].isNull()) + initialized_ = value["Initialized"].asString() == "true"; + if(!value["MasterAccountUid"].isNull()) + masterAccountUid_ = std::stol(value["MasterAccountUid"].asString()); + if(!value["PayerAccountUid"].isNull()) + payerAccountUid_ = std::stol(value["PayerAccountUid"].asString()); + if(!value["Status"].isNull()) + status_ = value["Status"].asString(); + if(!value["UpdateTime"].isNull()) + updateTime_ = value["UpdateTime"].asString(); + +} + +std::string GetEnrolledAccountResult::getBaselineId()const +{ + return baselineId_; +} + +std::string GetEnrolledAccountResult::getStatus()const +{ + return status_; +} + +std::vector GetEnrolledAccountResult::getProgress()const +{ + return progress_; +} + +bool GetEnrolledAccountResult::getInitialized()const +{ + return initialized_; +} + +long GetEnrolledAccountResult::getMasterAccountUid()const +{ + return masterAccountUid_; +} + +GetEnrolledAccountResult::ErrorInfo GetEnrolledAccountResult::getErrorInfo()const +{ + return errorInfo_; +} + +std::string GetEnrolledAccountResult::getCreateTime()const +{ + return createTime_; +} + +std::string GetEnrolledAccountResult::getFolderId()const +{ + return folderId_; +} + +long GetEnrolledAccountResult::getAccountUid()const +{ + return accountUid_; +} + +std::vector GetEnrolledAccountResult::getBaselineItems()const +{ + return baselineItems_; +} + +std::string GetEnrolledAccountResult::getDisplayName()const +{ + return displayName_; +} + +std::string GetEnrolledAccountResult::getUpdateTime()const +{ + return updateTime_; +} + +GetEnrolledAccountResult::Inputs GetEnrolledAccountResult::getInputs()const +{ + return inputs_; +} + +long GetEnrolledAccountResult::getPayerAccountUid()const +{ + return payerAccountUid_; +} + diff --git a/governance/src/model/ListAccountFactoryBaselineItemsRequest.cc b/governance/src/model/ListAccountFactoryBaselineItemsRequest.cc new file mode 100644 index 000000000..fa8b58840 --- /dev/null +++ b/governance/src/model/ListAccountFactoryBaselineItemsRequest.cc @@ -0,0 +1,85 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::ListAccountFactoryBaselineItemsRequest; + +ListAccountFactoryBaselineItemsRequest::ListAccountFactoryBaselineItemsRequest() + : RpcServiceRequest("governance", "2021-01-20", "ListAccountFactoryBaselineItems") { + setMethod(HttpRequest::Method::Post); +} + +ListAccountFactoryBaselineItemsRequest::~ListAccountFactoryBaselineItemsRequest() {} + +std::string ListAccountFactoryBaselineItemsRequest::getType() const { + return type_; +} + +void ListAccountFactoryBaselineItemsRequest::setType(const std::string &type) { + type_ = type; + setParameter(std::string("Type"), type); +} + +std::string ListAccountFactoryBaselineItemsRequest::getNextToken() const { + return nextToken_; +} + +void ListAccountFactoryBaselineItemsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +std::string ListAccountFactoryBaselineItemsRequest::getRegionId() const { + return regionId_; +} + +void ListAccountFactoryBaselineItemsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::vector ListAccountFactoryBaselineItemsRequest::getNames() const { + return names_; +} + +void ListAccountFactoryBaselineItemsRequest::setNames(const std::vector &names) { + names_ = names; + for(int dep1 = 0; dep1 != names.size(); dep1++) { + setParameter(std::string("Names") + "." + std::to_string(dep1 + 1), names[dep1]); + } +} + +std::vector ListAccountFactoryBaselineItemsRequest::getVersions() const { + return versions_; +} + +void ListAccountFactoryBaselineItemsRequest::setVersions(const std::vector &versions) { + versions_ = versions; + for(int dep1 = 0; dep1 != versions.size(); dep1++) { + setParameter(std::string("Versions") + "." + std::to_string(dep1 + 1), versions[dep1]); + } +} + +int ListAccountFactoryBaselineItemsRequest::getMaxResults() const { + return maxResults_; +} + +void ListAccountFactoryBaselineItemsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + diff --git a/governance/src/model/ListAccountFactoryBaselineItemsResult.cc b/governance/src/model/ListAccountFactoryBaselineItemsResult.cc new file mode 100644 index 000000000..d29bc99c7 --- /dev/null +++ b/governance/src/model/ListAccountFactoryBaselineItemsResult.cc @@ -0,0 +1,82 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +ListAccountFactoryBaselineItemsResult::ListAccountFactoryBaselineItemsResult() : + ServiceResult() +{} + +ListAccountFactoryBaselineItemsResult::ListAccountFactoryBaselineItemsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListAccountFactoryBaselineItemsResult::~ListAccountFactoryBaselineItemsResult() +{} + +void ListAccountFactoryBaselineItemsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allBaselineItemsNode = value["BaselineItems"]["BaselineItem"]; + for (auto valueBaselineItemsBaselineItem : allBaselineItemsNode) + { + BaselineItem baselineItemsObject; + if(!valueBaselineItemsBaselineItem["Description"].isNull()) + baselineItemsObject.description = valueBaselineItemsBaselineItem["Description"].asString(); + if(!valueBaselineItemsBaselineItem["Name"].isNull()) + baselineItemsObject.name = valueBaselineItemsBaselineItem["Name"].asString(); + if(!valueBaselineItemsBaselineItem["Type"].isNull()) + baselineItemsObject.type = valueBaselineItemsBaselineItem["Type"].asString(); + if(!valueBaselineItemsBaselineItem["Version"].isNull()) + baselineItemsObject.version = valueBaselineItemsBaselineItem["Version"].asString(); + auto allDependsOnNode = valueBaselineItemsBaselineItem["DependsOn"]["DependsOnItem"]; + for (auto valueBaselineItemsBaselineItemDependsOnDependsOnItem : allDependsOnNode) + { + BaselineItem::DependsOnItem dependsOnObject; + if(!valueBaselineItemsBaselineItemDependsOnDependsOnItem["Name"].isNull()) + dependsOnObject.name = valueBaselineItemsBaselineItemDependsOnDependsOnItem["Name"].asString(); + if(!valueBaselineItemsBaselineItemDependsOnDependsOnItem["Type"].isNull()) + dependsOnObject.type = valueBaselineItemsBaselineItemDependsOnDependsOnItem["Type"].asString(); + if(!valueBaselineItemsBaselineItemDependsOnDependsOnItem["Version"].isNull()) + dependsOnObject.version = valueBaselineItemsBaselineItemDependsOnDependsOnItem["Version"].asString(); + baselineItemsObject.dependsOn.push_back(dependsOnObject); + } + baselineItems_.push_back(baselineItemsObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + +} + +std::vector ListAccountFactoryBaselineItemsResult::getBaselineItems()const +{ + return baselineItems_; +} + +std::string ListAccountFactoryBaselineItemsResult::getNextToken()const +{ + return nextToken_; +} + diff --git a/governance/src/model/ListAccountFactoryBaselinesRequest.cc b/governance/src/model/ListAccountFactoryBaselinesRequest.cc new file mode 100644 index 000000000..551979044 --- /dev/null +++ b/governance/src/model/ListAccountFactoryBaselinesRequest.cc @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::ListAccountFactoryBaselinesRequest; + +ListAccountFactoryBaselinesRequest::ListAccountFactoryBaselinesRequest() + : RpcServiceRequest("governance", "2021-01-20", "ListAccountFactoryBaselines") { + setMethod(HttpRequest::Method::Post); +} + +ListAccountFactoryBaselinesRequest::~ListAccountFactoryBaselinesRequest() {} + +std::string ListAccountFactoryBaselinesRequest::getNextToken() const { + return nextToken_; +} + +void ListAccountFactoryBaselinesRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +std::string ListAccountFactoryBaselinesRequest::getRegionId() const { + return regionId_; +} + +void ListAccountFactoryBaselinesRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +int ListAccountFactoryBaselinesRequest::getMaxResults() const { + return maxResults_; +} + +void ListAccountFactoryBaselinesRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + diff --git a/governance/src/model/ListAccountFactoryBaselinesResult.cc b/governance/src/model/ListAccountFactoryBaselinesResult.cc new file mode 100644 index 000000000..6f8b9b484 --- /dev/null +++ b/governance/src/model/ListAccountFactoryBaselinesResult.cc @@ -0,0 +1,74 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +ListAccountFactoryBaselinesResult::ListAccountFactoryBaselinesResult() : + ServiceResult() +{} + +ListAccountFactoryBaselinesResult::ListAccountFactoryBaselinesResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListAccountFactoryBaselinesResult::~ListAccountFactoryBaselinesResult() +{} + +void ListAccountFactoryBaselinesResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allBaselinesNode = value["Baselines"]["Baseline"]; + for (auto valueBaselinesBaseline : allBaselinesNode) + { + Baseline baselinesObject; + if(!valueBaselinesBaseline["BaselineId"].isNull()) + baselinesObject.baselineId = valueBaselinesBaseline["BaselineId"].asString(); + if(!valueBaselinesBaseline["BaselineName"].isNull()) + baselinesObject.baselineName = valueBaselinesBaseline["BaselineName"].asString(); + if(!valueBaselinesBaseline["CreateTime"].isNull()) + baselinesObject.createTime = valueBaselinesBaseline["CreateTime"].asString(); + if(!valueBaselinesBaseline["Description"].isNull()) + baselinesObject.description = valueBaselinesBaseline["Description"].asString(); + if(!valueBaselinesBaseline["Type"].isNull()) + baselinesObject.type = valueBaselinesBaseline["Type"].asString(); + if(!valueBaselinesBaseline["UpdateTime"].isNull()) + baselinesObject.updateTime = valueBaselinesBaseline["UpdateTime"].asString(); + baselines_.push_back(baselinesObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + +} + +std::string ListAccountFactoryBaselinesResult::getNextToken()const +{ + return nextToken_; +} + +std::vector ListAccountFactoryBaselinesResult::getBaselines()const +{ + return baselines_; +} + diff --git a/governance/src/model/ListEnrolledAccountsRequest.cc b/governance/src/model/ListEnrolledAccountsRequest.cc new file mode 100644 index 000000000..edc440ca1 --- /dev/null +++ b/governance/src/model/ListEnrolledAccountsRequest.cc @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::ListEnrolledAccountsRequest; + +ListEnrolledAccountsRequest::ListEnrolledAccountsRequest() + : RpcServiceRequest("governance", "2021-01-20", "ListEnrolledAccounts") { + setMethod(HttpRequest::Method::Post); +} + +ListEnrolledAccountsRequest::~ListEnrolledAccountsRequest() {} + +std::string ListEnrolledAccountsRequest::getNextToken() const { + return nextToken_; +} + +void ListEnrolledAccountsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +std::string ListEnrolledAccountsRequest::getRegionId() const { + return regionId_; +} + +void ListEnrolledAccountsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +int ListEnrolledAccountsRequest::getMaxResults() const { + return maxResults_; +} + +void ListEnrolledAccountsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + diff --git a/governance/src/model/ListEnrolledAccountsResult.cc b/governance/src/model/ListEnrolledAccountsResult.cc new file mode 100644 index 000000000..35eb9484e --- /dev/null +++ b/governance/src/model/ListEnrolledAccountsResult.cc @@ -0,0 +1,78 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +ListEnrolledAccountsResult::ListEnrolledAccountsResult() : + ServiceResult() +{} + +ListEnrolledAccountsResult::ListEnrolledAccountsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListEnrolledAccountsResult::~ListEnrolledAccountsResult() +{} + +void ListEnrolledAccountsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allEnrolledAccountsNode = value["EnrolledAccounts"]["EnrolledAccountsItem"]; + for (auto valueEnrolledAccountsEnrolledAccountsItem : allEnrolledAccountsNode) + { + EnrolledAccountsItem enrolledAccountsObject; + if(!valueEnrolledAccountsEnrolledAccountsItem["AccountUid"].isNull()) + enrolledAccountsObject.accountUid = std::stol(valueEnrolledAccountsEnrolledAccountsItem["AccountUid"].asString()); + if(!valueEnrolledAccountsEnrolledAccountsItem["BaselineId"].isNull()) + enrolledAccountsObject.baselineId = valueEnrolledAccountsEnrolledAccountsItem["BaselineId"].asString(); + if(!valueEnrolledAccountsEnrolledAccountsItem["CreateTime"].isNull()) + enrolledAccountsObject.createTime = valueEnrolledAccountsEnrolledAccountsItem["CreateTime"].asString(); + if(!valueEnrolledAccountsEnrolledAccountsItem["DisplayName"].isNull()) + enrolledAccountsObject.displayName = valueEnrolledAccountsEnrolledAccountsItem["DisplayName"].asString(); + if(!valueEnrolledAccountsEnrolledAccountsItem["FolderId"].isNull()) + enrolledAccountsObject.folderId = valueEnrolledAccountsEnrolledAccountsItem["FolderId"].asString(); + if(!valueEnrolledAccountsEnrolledAccountsItem["PayerAccountUid"].isNull()) + enrolledAccountsObject.payerAccountUid = std::stol(valueEnrolledAccountsEnrolledAccountsItem["PayerAccountUid"].asString()); + if(!valueEnrolledAccountsEnrolledAccountsItem["Status"].isNull()) + enrolledAccountsObject.status = valueEnrolledAccountsEnrolledAccountsItem["Status"].asString(); + if(!valueEnrolledAccountsEnrolledAccountsItem["UpdateTime"].isNull()) + enrolledAccountsObject.updateTime = valueEnrolledAccountsEnrolledAccountsItem["UpdateTime"].asString(); + enrolledAccounts_.push_back(enrolledAccountsObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + +} + +std::string ListEnrolledAccountsResult::getNextToken()const +{ + return nextToken_; +} + +std::vector ListEnrolledAccountsResult::getEnrolledAccounts()const +{ + return enrolledAccounts_; +} + diff --git a/governance/src/model/ListEvaluationMetadataRequest.cc b/governance/src/model/ListEvaluationMetadataRequest.cc new file mode 100644 index 000000000..11b03b2da --- /dev/null +++ b/governance/src/model/ListEvaluationMetadataRequest.cc @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::ListEvaluationMetadataRequest; + +ListEvaluationMetadataRequest::ListEvaluationMetadataRequest() + : RpcServiceRequest("governance", "2021-01-20", "ListEvaluationMetadata") { + setMethod(HttpRequest::Method::Post); +} + +ListEvaluationMetadataRequest::~ListEvaluationMetadataRequest() {} + +std::string ListEvaluationMetadataRequest::getLanguage() const { + return language_; +} + +void ListEvaluationMetadataRequest::setLanguage(const std::string &language) { + language_ = language; + setParameter(std::string("Language"), language); +} + +std::string ListEvaluationMetadataRequest::getRegionId() const { + return regionId_; +} + +void ListEvaluationMetadataRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string ListEvaluationMetadataRequest::getPartnerCode() const { + return partnerCode_; +} + +void ListEvaluationMetadataRequest::setPartnerCode(const std::string &partnerCode) { + partnerCode_ = partnerCode; + setParameter(std::string("PartnerCode"), partnerCode); +} + diff --git a/governance/src/model/ListEvaluationMetadataResult.cc b/governance/src/model/ListEvaluationMetadataResult.cc new file mode 100644 index 000000000..1119fc331 --- /dev/null +++ b/governance/src/model/ListEvaluationMetadataResult.cc @@ -0,0 +1,141 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +ListEvaluationMetadataResult::ListEvaluationMetadataResult() : + ServiceResult() +{} + +ListEvaluationMetadataResult::ListEvaluationMetadataResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListEvaluationMetadataResult::~ListEvaluationMetadataResult() +{} + +void ListEvaluationMetadataResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allEvaluationMetadataNode = value["EvaluationMetadata"]["EvaluationMetadataItem"]; + for (auto valueEvaluationMetadataEvaluationMetadataItem : allEvaluationMetadataNode) + { + EvaluationMetadataItem evaluationMetadataObject; + if(!valueEvaluationMetadataEvaluationMetadataItem["Type"].isNull()) + evaluationMetadataObject.type = valueEvaluationMetadataEvaluationMetadataItem["Type"].asString(); + auto allMetadataNode = valueEvaluationMetadataEvaluationMetadataItem["Metadata"]["MetadataItem"]; + for (auto valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem : allMetadataNode) + { + EvaluationMetadataItem::MetadataItem metadataObject; + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Category"].isNull()) + metadataObject.category = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Category"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Description"].isNull()) + metadataObject.description = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Description"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["DisplayName"].isNull()) + metadataObject.displayName = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["DisplayName"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Id"].isNull()) + metadataObject.id = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Id"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["NoRiskDisplayName"].isNull()) + metadataObject.noRiskDisplayName = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["NoRiskDisplayName"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["ParentId"].isNull()) + metadataObject.parentId = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["ParentId"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["RecommendationLevel"].isNull()) + metadataObject.recommendationLevel = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["RecommendationLevel"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Scope"].isNull()) + metadataObject.scope = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Scope"].asString(); + if(!valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Stage"].isNull()) + metadataObject.stage = valueEvaluationMetadataEvaluationMetadataItemMetadataMetadataItem["Stage"].asString(); + auto remediationMetadataNode = value["RemediationMetadata"]; + auto allRemediationNode = remediationMetadataNode["Remediation"]["RemediationItem"]; + for (auto remediationMetadataNodeRemediationRemediationItem : allRemediationNode) + { + EvaluationMetadataItem::MetadataItem::RemediationMetadata::RemediationItem remediationItemObject; + if(!remediationMetadataNodeRemediationRemediationItem["AnalysisDefinition"].isNull()) + remediationItemObject.analysisDefinition = remediationMetadataNodeRemediationRemediationItem["AnalysisDefinition"].asString(); + if(!remediationMetadataNodeRemediationRemediationItem["RemediationParameters"].isNull()) + remediationItemObject.remediationParameters = remediationMetadataNodeRemediationRemediationItem["RemediationParameters"].asString(); + if(!remediationMetadataNodeRemediationRemediationItem["RemediationTarget"].isNull()) + remediationItemObject.remediationTarget = remediationMetadataNodeRemediationRemediationItem["RemediationTarget"].asString(); + if(!remediationMetadataNodeRemediationRemediationItem["RemediationType"].isNull()) + remediationItemObject.remediationType = remediationMetadataNodeRemediationRemediationItem["RemediationType"].asString(); + auto allActionsNode = remediationMetadataNodeRemediationRemediationItem["Actions"]["Action"]; + for (auto remediationMetadataNodeRemediationRemediationItemActionsAction : allActionsNode) + { + EvaluationMetadataItem::MetadataItem::RemediationMetadata::RemediationItem::Action actionsObject; + if(!remediationMetadataNodeRemediationRemediationItemActionsAction["Classification"].isNull()) + actionsObject.classification = remediationMetadataNodeRemediationRemediationItemActionsAction["Classification"].asString(); + if(!remediationMetadataNodeRemediationRemediationItemActionsAction["CostDescription"].isNull()) + actionsObject.costDescription = remediationMetadataNodeRemediationRemediationItemActionsAction["CostDescription"].asString(); + if(!remediationMetadataNodeRemediationRemediationItemActionsAction["Description"].isNull()) + actionsObject.description = remediationMetadataNodeRemediationRemediationItemActionsAction["Description"].asString(); + if(!remediationMetadataNodeRemediationRemediationItemActionsAction["Notice"].isNull()) + actionsObject.notice = remediationMetadataNodeRemediationRemediationItemActionsAction["Notice"].asString(); + if(!remediationMetadataNodeRemediationRemediationItemActionsAction["Suggestion"].isNull()) + actionsObject.suggestion = remediationMetadataNodeRemediationRemediationItemActionsAction["Suggestion"].asString(); + auto allGuidanceNode = remediationMetadataNodeRemediationRemediationItemActionsAction["Guidance"]["GuidanceItem"]; + for (auto remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem : allGuidanceNode) + { + EvaluationMetadataItem::MetadataItem::RemediationMetadata::RemediationItem::Action::GuidanceItem guidanceObject; + if(!remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["ButtonName"].isNull()) + guidanceObject.buttonName = remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["ButtonName"].asString(); + if(!remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["ButtonRef"].isNull()) + guidanceObject.buttonRef = remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["ButtonRef"].asString(); + if(!remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["Content"].isNull()) + guidanceObject.content = remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["Content"].asString(); + if(!remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["Title"].isNull()) + guidanceObject.title = remediationMetadataNodeRemediationRemediationItemActionsActionGuidanceGuidanceItem["Title"].asString(); + actionsObject.guidance.push_back(guidanceObject); + } + remediationItemObject.actions.push_back(actionsObject); + } + metadataObject.remediationMetadata.remediation.push_back(remediationItemObject); + } + auto resourceMetadataNode = value["ResourceMetadata"]; + auto allResourcePropertyMetadataNode = resourceMetadataNode["ResourcePropertyMetadata"]["ResourcePropertyMetadataItem"]; + for (auto resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem : allResourcePropertyMetadataNode) + { + EvaluationMetadataItem::MetadataItem::ResourceMetadata::ResourcePropertyMetadataItem resourcePropertyMetadataItemObject; + if(!resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["DisplayName"].isNull()) + resourcePropertyMetadataItemObject.displayName = resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["DisplayName"].asString(); + if(!resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["PropertyName"].isNull()) + resourcePropertyMetadataItemObject.propertyName = resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["PropertyName"].asString(); + if(!resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["PropertyReference"].isNull()) + resourcePropertyMetadataItemObject.propertyReference = resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["PropertyReference"].asString(); + if(!resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["PropertyType"].isNull()) + resourcePropertyMetadataItemObject.propertyType = resourceMetadataNodeResourcePropertyMetadataResourcePropertyMetadataItem["PropertyType"].asString(); + metadataObject.resourceMetadata.resourcePropertyMetadata.push_back(resourcePropertyMetadataItemObject); + } + evaluationMetadataObject.metadata.push_back(metadataObject); + } + evaluationMetadata_.push_back(evaluationMetadataObject); + } + +} + +std::vector ListEvaluationMetadataResult::getEvaluationMetadata()const +{ + return evaluationMetadata_; +} + diff --git a/governance/src/model/ListEvaluationMetricDetailsRequest.cc b/governance/src/model/ListEvaluationMetricDetailsRequest.cc new file mode 100644 index 000000000..16fbca3ab --- /dev/null +++ b/governance/src/model/ListEvaluationMetricDetailsRequest.cc @@ -0,0 +1,81 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::ListEvaluationMetricDetailsRequest; + +ListEvaluationMetricDetailsRequest::ListEvaluationMetricDetailsRequest() + : RpcServiceRequest("governance", "2021-01-20", "ListEvaluationMetricDetails") { + setMethod(HttpRequest::Method::Post); +} + +ListEvaluationMetricDetailsRequest::~ListEvaluationMetricDetailsRequest() {} + +long ListEvaluationMetricDetailsRequest::getAccountId() const { + return accountId_; +} + +void ListEvaluationMetricDetailsRequest::setAccountId(long accountId) { + accountId_ = accountId; + setParameter(std::string("AccountId"), std::to_string(accountId)); +} + +std::string ListEvaluationMetricDetailsRequest::getNextToken() const { + return nextToken_; +} + +void ListEvaluationMetricDetailsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +std::string ListEvaluationMetricDetailsRequest::getRegionId() const { + return regionId_; +} + +void ListEvaluationMetricDetailsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string ListEvaluationMetricDetailsRequest::getId() const { + return id_; +} + +void ListEvaluationMetricDetailsRequest::setId(const std::string &id) { + id_ = id; + setParameter(std::string("Id"), id); +} + +std::string ListEvaluationMetricDetailsRequest::getPartnerCode() const { + return partnerCode_; +} + +void ListEvaluationMetricDetailsRequest::setPartnerCode(const std::string &partnerCode) { + partnerCode_ = partnerCode; + setParameter(std::string("PartnerCode"), partnerCode); +} + +int ListEvaluationMetricDetailsRequest::getMaxResults() const { + return maxResults_; +} + +void ListEvaluationMetricDetailsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + diff --git a/governance/src/model/ListEvaluationMetricDetailsResult.cc b/governance/src/model/ListEvaluationMetricDetailsResult.cc new file mode 100644 index 000000000..8ad3b3cc4 --- /dev/null +++ b/governance/src/model/ListEvaluationMetricDetailsResult.cc @@ -0,0 +1,86 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +ListEvaluationMetricDetailsResult::ListEvaluationMetricDetailsResult() : + ServiceResult() +{} + +ListEvaluationMetricDetailsResult::ListEvaluationMetricDetailsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListEvaluationMetricDetailsResult::~ListEvaluationMetricDetailsResult() +{} + +void ListEvaluationMetricDetailsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allResourcesNode = value["Resources"]["Resource"]; + for (auto valueResourcesResource : allResourcesNode) + { + Resource resourcesObject; + if(!valueResourcesResource["RegionId"].isNull()) + resourcesObject.regionId = valueResourcesResource["RegionId"].asString(); + if(!valueResourcesResource["ResourceClassification"].isNull()) + resourcesObject.resourceClassification = valueResourcesResource["ResourceClassification"].asString(); + if(!valueResourcesResource["ResourceId"].isNull()) + resourcesObject.resourceId = valueResourcesResource["ResourceId"].asString(); + if(!valueResourcesResource["ResourceName"].isNull()) + resourcesObject.resourceName = valueResourcesResource["ResourceName"].asString(); + if(!valueResourcesResource["ResourceOwnerDisplayName"].isNull()) + resourcesObject.resourceOwnerDisplayName = valueResourcesResource["ResourceOwnerDisplayName"].asString(); + if(!valueResourcesResource["ResourceOwnerId"].isNull()) + resourcesObject.resourceOwnerId = std::stol(valueResourcesResource["ResourceOwnerId"].asString()); + if(!valueResourcesResource["ResourceType"].isNull()) + resourcesObject.resourceType = valueResourcesResource["ResourceType"].asString(); + auto allResourcePropertiesNode = valueResourcesResource["ResourceProperties"]["ResourcePropertie"]; + for (auto valueResourcesResourceResourcePropertiesResourcePropertie : allResourcePropertiesNode) + { + Resource::ResourcePropertie resourcePropertiesObject; + if(!valueResourcesResourceResourcePropertiesResourcePropertie["PropertyName"].isNull()) + resourcePropertiesObject.propertyName = valueResourcesResourceResourcePropertiesResourcePropertie["PropertyName"].asString(); + if(!valueResourcesResourceResourcePropertiesResourcePropertie["PropertyValue"].isNull()) + resourcePropertiesObject.propertyValue = valueResourcesResourceResourcePropertiesResourcePropertie["PropertyValue"].asString(); + resourcesObject.resourceProperties.push_back(resourcePropertiesObject); + } + resources_.push_back(resourcesObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + +} + +std::string ListEvaluationMetricDetailsResult::getNextToken()const +{ + return nextToken_; +} + +std::vector ListEvaluationMetricDetailsResult::getResources()const +{ + return resources_; +} + diff --git a/governance/src/model/ListEvaluationResultsRequest.cc b/governance/src/model/ListEvaluationResultsRequest.cc new file mode 100644 index 000000000..4b5d4fedb --- /dev/null +++ b/governance/src/model/ListEvaluationResultsRequest.cc @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::ListEvaluationResultsRequest; + +ListEvaluationResultsRequest::ListEvaluationResultsRequest() + : RpcServiceRequest("governance", "2021-01-20", "ListEvaluationResults") { + setMethod(HttpRequest::Method::Post); +} + +ListEvaluationResultsRequest::~ListEvaluationResultsRequest() {} + +long ListEvaluationResultsRequest::getAccountId() const { + return accountId_; +} + +void ListEvaluationResultsRequest::setAccountId(long accountId) { + accountId_ = accountId; + setParameter(std::string("AccountId"), std::to_string(accountId)); +} + +std::string ListEvaluationResultsRequest::getRegionId() const { + return regionId_; +} + +void ListEvaluationResultsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string ListEvaluationResultsRequest::getPartnerCode() const { + return partnerCode_; +} + +void ListEvaluationResultsRequest::setPartnerCode(const std::string &partnerCode) { + partnerCode_ = partnerCode; + setParameter(std::string("PartnerCode"), partnerCode); +} + diff --git a/governance/src/model/ListEvaluationResultsResult.cc b/governance/src/model/ListEvaluationResultsResult.cc new file mode 100644 index 000000000..c30fcb7c2 --- /dev/null +++ b/governance/src/model/ListEvaluationResultsResult.cc @@ -0,0 +1,107 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +ListEvaluationResultsResult::ListEvaluationResultsResult() : + ServiceResult() +{} + +ListEvaluationResultsResult::ListEvaluationResultsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListEvaluationResultsResult::~ListEvaluationResultsResult() +{} + +void ListEvaluationResultsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto resultsNode = value["Results"]; + if(!resultsNode["EvaluationTime"].isNull()) + results_.evaluationTime = resultsNode["EvaluationTime"].asString(); + if(!resultsNode["Status"].isNull()) + results_.status = resultsNode["Status"].asString(); + if(!resultsNode["TotalScore"].isNull()) + results_.totalScore = resultsNode["TotalScore"].asString(); + auto allCategoryResultsNode = resultsNode["CategoryResults"]["CategoryResultsItem"]; + for (auto resultsNodeCategoryResultsCategoryResultsItem : allCategoryResultsNode) + { + Results::CategoryResultsItem categoryResultsItemObject; + if(!resultsNodeCategoryResultsCategoryResultsItem["Id"].isNull()) + categoryResultsItemObject.id = resultsNodeCategoryResultsCategoryResultsItem["Id"].asString(); + if(!resultsNodeCategoryResultsCategoryResultsItem["Result"].isNull()) + categoryResultsItemObject.result = resultsNodeCategoryResultsCategoryResultsItem["Result"].asString(); + results_.categoryResults.push_back(categoryResultsItemObject); + } + auto allGroupResultsNode = resultsNode["GroupResults"]["GroupResultsItem"]; + for (auto resultsNodeGroupResultsGroupResultsItem : allGroupResultsNode) + { + Results::GroupResultsItem groupResultsItemObject; + if(!resultsNodeGroupResultsGroupResultsItem["Id"].isNull()) + groupResultsItemObject.id = resultsNodeGroupResultsGroupResultsItem["Id"].asString(); + if(!resultsNodeGroupResultsGroupResultsItem["PotentialScoreIncrease"].isNull()) + groupResultsItemObject.potentialScoreIncrease = resultsNodeGroupResultsGroupResultsItem["PotentialScoreIncrease"].asString(); + results_.groupResults.push_back(groupResultsItemObject); + } + auto allMetricResultsNode = resultsNode["MetricResults"]["MetricResult"]; + for (auto resultsNodeMetricResultsMetricResult : allMetricResultsNode) + { + Results::MetricResult metricResultObject; + if(!resultsNodeMetricResultsMetricResult["EvaluationTime"].isNull()) + metricResultObject.evaluationTime = resultsNodeMetricResultsMetricResult["EvaluationTime"].asString(); + if(!resultsNodeMetricResultsMetricResult["Id"].isNull()) + metricResultObject.id = resultsNodeMetricResultsMetricResult["Id"].asString(); + if(!resultsNodeMetricResultsMetricResult["Result"].isNull()) + metricResultObject.result = resultsNodeMetricResultsMetricResult["Result"].asString(); + if(!resultsNodeMetricResultsMetricResult["Risk"].isNull()) + metricResultObject.risk = resultsNodeMetricResultsMetricResult["Risk"].asString(); + if(!resultsNodeMetricResultsMetricResult["Status"].isNull()) + metricResultObject.status = resultsNodeMetricResultsMetricResult["Status"].asString(); + auto errorInfoNode = value["ErrorInfo"]; + if(!errorInfoNode["Code"].isNull()) + metricResultObject.errorInfo.code = errorInfoNode["Code"].asString(); + if(!errorInfoNode["Message"].isNull()) + metricResultObject.errorInfo.message = errorInfoNode["Message"].asString(); + auto resourcesSummaryNode = value["ResourcesSummary"]; + if(!resourcesSummaryNode["NonCompliant"].isNull()) + metricResultObject.resourcesSummary.nonCompliant = std::stoi(resourcesSummaryNode["NonCompliant"].asString()); + results_.metricResults.push_back(metricResultObject); + } + if(!value["AccountId"].isNull()) + accountId_ = std::stol(value["AccountId"].asString()); + +} + +long ListEvaluationResultsResult::getAccountId()const +{ + return accountId_; +} + +ListEvaluationResultsResult::Results ListEvaluationResultsResult::getResults()const +{ + return results_; +} + diff --git a/governance/src/model/ListEvaluationScoreHistoryRequest.cc b/governance/src/model/ListEvaluationScoreHistoryRequest.cc new file mode 100644 index 000000000..593535868 --- /dev/null +++ b/governance/src/model/ListEvaluationScoreHistoryRequest.cc @@ -0,0 +1,72 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::ListEvaluationScoreHistoryRequest; + +ListEvaluationScoreHistoryRequest::ListEvaluationScoreHistoryRequest() + : RpcServiceRequest("governance", "2021-01-20", "ListEvaluationScoreHistory") { + setMethod(HttpRequest::Method::Post); +} + +ListEvaluationScoreHistoryRequest::~ListEvaluationScoreHistoryRequest() {} + +std::string ListEvaluationScoreHistoryRequest::getStartDate() const { + return startDate_; +} + +void ListEvaluationScoreHistoryRequest::setStartDate(const std::string &startDate) { + startDate_ = startDate; + setParameter(std::string("StartDate"), startDate); +} + +std::string ListEvaluationScoreHistoryRequest::getRegionId() const { + return regionId_; +} + +void ListEvaluationScoreHistoryRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string ListEvaluationScoreHistoryRequest::getPartnerCode() const { + return partnerCode_; +} + +void ListEvaluationScoreHistoryRequest::setPartnerCode(const std::string &partnerCode) { + partnerCode_ = partnerCode; + setParameter(std::string("PartnerCode"), partnerCode); +} + +std::string ListEvaluationScoreHistoryRequest::getEndDate() const { + return endDate_; +} + +void ListEvaluationScoreHistoryRequest::setEndDate(const std::string &endDate) { + endDate_ = endDate; + setParameter(std::string("EndDate"), endDate); +} + +bool ListEvaluationScoreHistoryRequest::getShowScoreDiff() const { + return showScoreDiff_; +} + +void ListEvaluationScoreHistoryRequest::setShowScoreDiff(bool showScoreDiff) { + showScoreDiff_ = showScoreDiff; + setParameter(std::string("ShowScoreDiff"), showScoreDiff ? "true" : "false"); +} + diff --git a/governance/src/model/ListEvaluationScoreHistoryResult.cc b/governance/src/model/ListEvaluationScoreHistoryResult.cc new file mode 100644 index 000000000..4d529dcfa --- /dev/null +++ b/governance/src/model/ListEvaluationScoreHistoryResult.cc @@ -0,0 +1,96 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +ListEvaluationScoreHistoryResult::ListEvaluationScoreHistoryResult() : + ServiceResult() +{} + +ListEvaluationScoreHistoryResult::ListEvaluationScoreHistoryResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListEvaluationScoreHistoryResult::~ListEvaluationScoreHistoryResult() +{} + +void ListEvaluationScoreHistoryResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto scoreDiffNode = value["ScoreDiff"]; + auto allCategoryScoreDiffsNode = scoreDiffNode["CategoryScoreDiffs"]["CategoryScoreDiff"]; + for (auto scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff : allCategoryScoreDiffsNode) + { + ScoreDiff::CategoryScoreDiff categoryScoreDiffObject; + if(!scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["CurrentEvaluationTime"].isNull()) + categoryScoreDiffObject.currentEvaluationTime = scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["CurrentEvaluationTime"].asString(); + if(!scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["Id"].isNull()) + categoryScoreDiffObject.id = scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["Id"].asString(); + if(!scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["PreviousEvaluationTime"].isNull()) + categoryScoreDiffObject.previousEvaluationTime = scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["PreviousEvaluationTime"].asString(); + if(!scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["ScoreDiff"].isNull()) + categoryScoreDiffObject.scoreDiff = scoreDiffNodeCategoryScoreDiffsCategoryScoreDiff["ScoreDiff"].asString(); + scoreDiff_.categoryScoreDiffs.push_back(categoryScoreDiffObject); + } + auto allMetricScoreDiffsNode = scoreDiffNode["MetricScoreDiffs"]["MetricScoreDiff"]; + for (auto scoreDiffNodeMetricScoreDiffsMetricScoreDiff : allMetricScoreDiffsNode) + { + ScoreDiff::MetricScoreDiff metricScoreDiffObject; + if(!scoreDiffNodeMetricScoreDiffsMetricScoreDiff["Category"].isNull()) + metricScoreDiffObject.category = scoreDiffNodeMetricScoreDiffsMetricScoreDiff["Category"].asString(); + if(!scoreDiffNodeMetricScoreDiffsMetricScoreDiff["CurrentEvaluationTime"].isNull()) + metricScoreDiffObject.currentEvaluationTime = scoreDiffNodeMetricScoreDiffsMetricScoreDiff["CurrentEvaluationTime"].asString(); + if(!scoreDiffNodeMetricScoreDiffsMetricScoreDiff["Id"].isNull()) + metricScoreDiffObject.id = scoreDiffNodeMetricScoreDiffsMetricScoreDiff["Id"].asString(); + if(!scoreDiffNodeMetricScoreDiffsMetricScoreDiff["PreviousEvaluationTime"].isNull()) + metricScoreDiffObject.previousEvaluationTime = scoreDiffNodeMetricScoreDiffsMetricScoreDiff["PreviousEvaluationTime"].asString(); + if(!scoreDiffNodeMetricScoreDiffsMetricScoreDiff["ScoreDiff"].isNull()) + metricScoreDiffObject.scoreDiff = scoreDiffNodeMetricScoreDiffsMetricScoreDiff["ScoreDiff"].asString(); + scoreDiff_.metricScoreDiffs.push_back(metricScoreDiffObject); + } + auto scoreHistoryNode = value["ScoreHistory"]; + auto allTotalScoreHistoryNode = scoreHistoryNode["TotalScoreHistory"]["TotalScoreHistoryItem"]; + for (auto scoreHistoryNodeTotalScoreHistoryTotalScoreHistoryItem : allTotalScoreHistoryNode) + { + ScoreHistory::TotalScoreHistoryItem totalScoreHistoryItemObject; + if(!scoreHistoryNodeTotalScoreHistoryTotalScoreHistoryItem["EvaluationTime"].isNull()) + totalScoreHistoryItemObject.evaluationTime = scoreHistoryNodeTotalScoreHistoryTotalScoreHistoryItem["EvaluationTime"].asString(); + if(!scoreHistoryNodeTotalScoreHistoryTotalScoreHistoryItem["Score"].isNull()) + totalScoreHistoryItemObject.score = scoreHistoryNodeTotalScoreHistoryTotalScoreHistoryItem["Score"].asString(); + scoreHistory_.totalScoreHistory.push_back(totalScoreHistoryItemObject); + } + +} + +ListEvaluationScoreHistoryResult::ScoreDiff ListEvaluationScoreHistoryResult::getScoreDiff()const +{ + return scoreDiff_; +} + +ListEvaluationScoreHistoryResult::ScoreHistory ListEvaluationScoreHistoryResult::getScoreHistory()const +{ + return scoreHistory_; +} + diff --git a/governance/src/model/RunEvaluationRequest.cc b/governance/src/model/RunEvaluationRequest.cc new file mode 100644 index 000000000..af4668f22 --- /dev/null +++ b/governance/src/model/RunEvaluationRequest.cc @@ -0,0 +1,63 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::RunEvaluationRequest; + +RunEvaluationRequest::RunEvaluationRequest() + : RpcServiceRequest("governance", "2021-01-20", "RunEvaluation") { + setMethod(HttpRequest::Method::Post); +} + +RunEvaluationRequest::~RunEvaluationRequest() {} + +long RunEvaluationRequest::getAccountId() const { + return accountId_; +} + +void RunEvaluationRequest::setAccountId(long accountId) { + accountId_ = accountId; + setParameter(std::string("AccountId"), std::to_string(accountId)); +} + +std::string RunEvaluationRequest::getRegionId() const { + return regionId_; +} + +void RunEvaluationRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string RunEvaluationRequest::getScope() const { + return scope_; +} + +void RunEvaluationRequest::setScope(const std::string &scope) { + scope_ = scope; + setParameter(std::string("Scope"), scope); +} + +std::string RunEvaluationRequest::getPartnerCode() const { + return partnerCode_; +} + +void RunEvaluationRequest::setPartnerCode(const std::string &partnerCode) { + partnerCode_ = partnerCode; + setParameter(std::string("PartnerCode"), partnerCode); +} + diff --git a/governance/src/model/RunEvaluationResult.cc b/governance/src/model/RunEvaluationResult.cc new file mode 100644 index 000000000..02835c6d0 --- /dev/null +++ b/governance/src/model/RunEvaluationResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +RunEvaluationResult::RunEvaluationResult() : + ServiceResult() +{} + +RunEvaluationResult::RunEvaluationResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +RunEvaluationResult::~RunEvaluationResult() +{} + +void RunEvaluationResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/governance/src/model/UpdateAccountFactoryBaselineRequest.cc b/governance/src/model/UpdateAccountFactoryBaselineRequest.cc new file mode 100644 index 000000000..241183652 --- /dev/null +++ b/governance/src/model/UpdateAccountFactoryBaselineRequest.cc @@ -0,0 +1,76 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Governance::Model::UpdateAccountFactoryBaselineRequest; + +UpdateAccountFactoryBaselineRequest::UpdateAccountFactoryBaselineRequest() + : RpcServiceRequest("governance", "2021-01-20", "UpdateAccountFactoryBaseline") { + setMethod(HttpRequest::Method::Post); +} + +UpdateAccountFactoryBaselineRequest::~UpdateAccountFactoryBaselineRequest() {} + +std::string UpdateAccountFactoryBaselineRequest::getDescription() const { + return description_; +} + +void UpdateAccountFactoryBaselineRequest::setDescription(const std::string &description) { + description_ = description; + setParameter(std::string("Description"), description); +} + +std::string UpdateAccountFactoryBaselineRequest::getRegionId() const { + return regionId_; +} + +void UpdateAccountFactoryBaselineRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string UpdateAccountFactoryBaselineRequest::getBaselineName() const { + return baselineName_; +} + +void UpdateAccountFactoryBaselineRequest::setBaselineName(const std::string &baselineName) { + baselineName_ = baselineName; + setParameter(std::string("BaselineName"), baselineName); +} + +std::string UpdateAccountFactoryBaselineRequest::getBaselineId() const { + return baselineId_; +} + +void UpdateAccountFactoryBaselineRequest::setBaselineId(const std::string &baselineId) { + baselineId_ = baselineId; + setParameter(std::string("BaselineId"), baselineId); +} + +std::vector UpdateAccountFactoryBaselineRequest::getBaselineItems() const { + return baselineItems_; +} + +void UpdateAccountFactoryBaselineRequest::setBaselineItems(const std::vector &baselineItems) { + baselineItems_ = baselineItems; + for(int dep1 = 0; dep1 != baselineItems.size(); dep1++) { + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Name", baselineItems[dep1].name); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Config", baselineItems[dep1].config); + setParameter(std::string("BaselineItems") + "." + std::to_string(dep1 + 1) + ".Version", baselineItems[dep1].version); + } +} + diff --git a/governance/src/model/UpdateAccountFactoryBaselineResult.cc b/governance/src/model/UpdateAccountFactoryBaselineResult.cc new file mode 100644 index 000000000..45b8c7efb --- /dev/null +++ b/governance/src/model/UpdateAccountFactoryBaselineResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Governance; +using namespace AlibabaCloud::Governance::Model; + +UpdateAccountFactoryBaselineResult::UpdateAccountFactoryBaselineResult() : + ServiceResult() +{} + +UpdateAccountFactoryBaselineResult::UpdateAccountFactoryBaselineResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +UpdateAccountFactoryBaselineResult::~UpdateAccountFactoryBaselineResult() +{} + +void UpdateAccountFactoryBaselineResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} +