From 31aec3f28f15bd3adfb947c1886d959d6d2492e0 Mon Sep 17 00:00:00 2001 From: sdk-team Date: Mon, 18 Jan 2021 13:58:07 +0000 Subject: [PATCH] Generated 2019-03-27 for dg. --- CHANGELOG | 3 + dg/CMakeLists.txt | 166 ++++ dg/include/alibabacloud/dg/DgClient.h | 214 +++++ dg/include/alibabacloud/dg/DgExport.h | 32 + .../dg/model/AddDatabaseListRequest.h | 51 ++ .../dg/model/AddDatabaseListResult.h | 57 ++ .../dg/model/AddDatabaseRequest.h | 75 ++ .../alibabacloud/dg/model/AddDatabaseResult.h | 57 ++ .../dg/model/ConnectDatabaseRequest.h | 66 ++ .../dg/model/ConnectDatabaseResult.h | 57 ++ .../model/CreateDatabaseAccessPointRequest.h | 66 ++ .../model/CreateDatabaseAccessPointResult.h | 57 ++ .../dg/model/CreateGatewayRequest.h | 54 ++ .../dg/model/CreateGatewayResult.h | 57 ++ .../dg/model/CreateGatewayVerifyCodeRequest.h | 48 ++ .../dg/model/CreateGatewayVerifyCodeResult.h | 57 ++ .../model/DeleteDatabaseAccessPointRequest.h | 63 ++ .../model/DeleteDatabaseAccessPointResult.h | 57 ++ .../dg/model/DeleteDatabaseRequest.h | 48 ++ .../dg/model/DeleteDatabaseResult.h | 57 ++ .../dg/model/DeleteGatewayInstanceRequest.h | 54 ++ .../dg/model/DeleteGatewayInstanceResult.h | 57 ++ .../dg/model/DeleteGatewayRequest.h | 48 ++ .../dg/model/DeleteGatewayResult.h | 57 ++ .../dg/model/DescribeRegionsRequest.h | 48 ++ .../dg/model/DescribeRegionsResult.h | 63 ++ .../dg/model/DownloadGatewayProgramRequest.h | 51 ++ .../dg/model/DownloadGatewayProgramResult.h | 57 ++ .../dg/model/FindUserGatewayByIdRequest.h | 48 ++ .../dg/model/FindUserGatewayByIdResult.h | 57 ++ .../dg/model/GetUserDatabasesRequest.h | 72 ++ .../dg/model/GetUserDatabasesResult.h | 59 ++ .../dg/model/GetUserGatewayInstancesRequest.h | 48 ++ .../dg/model/GetUserGatewayInstancesResult.h | 57 ++ .../dg/model/GetUserGatewaysRequest.h | 57 ++ .../dg/model/GetUserGatewaysResult.h | 59 ++ .../dg/model/ListDatabaseAccessPointRequest.h | 72 ++ .../dg/model/ListDatabaseAccessPointResult.h | 59 ++ .../dg/model/ModifyDatabaseRequest.h | 69 ++ .../dg/model/ModifyDatabaseResult.h | 57 ++ .../dg/model/ModifyGatewayRequest.h | 54 ++ .../dg/model/ModifyGatewayResult.h | 57 ++ .../dg/model/RetryDatabaseRequest.h | 75 ++ .../dg/model/RetryDatabaseResult.h | 57 ++ .../dg/model/StopGatewayRequest.h | 51 ++ .../alibabacloud/dg/model/StopGatewayResult.h | 57 ++ dg/src/DgClient.cc | 809 ++++++++++++++++++ dg/src/model/AddDatabaseListRequest.cc | 51 ++ dg/src/model/AddDatabaseListResult.cc | 72 ++ dg/src/model/AddDatabaseRequest.cc | 139 +++ dg/src/model/AddDatabaseResult.cc | 72 ++ dg/src/model/ConnectDatabaseRequest.cc | 106 +++ dg/src/model/ConnectDatabaseResult.cc | 72 ++ .../model/CreateDatabaseAccessPointRequest.cc | 106 +++ .../model/CreateDatabaseAccessPointResult.cc | 72 ++ dg/src/model/CreateGatewayRequest.cc | 62 ++ dg/src/model/CreateGatewayResult.cc | 72 ++ .../model/CreateGatewayVerifyCodeRequest.cc | 40 + dg/src/model/CreateGatewayVerifyCodeResult.cc | 72 ++ .../model/DeleteDatabaseAccessPointRequest.cc | 95 ++ .../model/DeleteDatabaseAccessPointResult.cc | 72 ++ dg/src/model/DeleteDatabaseRequest.cc | 40 + dg/src/model/DeleteDatabaseResult.cc | 72 ++ dg/src/model/DeleteGatewayInstanceRequest.cc | 62 ++ dg/src/model/DeleteGatewayInstanceResult.cc | 72 ++ dg/src/model/DeleteGatewayRequest.cc | 40 + dg/src/model/DeleteGatewayResult.cc | 72 ++ dg/src/model/DescribeRegionsRequest.cc | 40 + dg/src/model/DescribeRegionsResult.cc | 82 ++ dg/src/model/DownloadGatewayProgramRequest.cc | 51 ++ dg/src/model/DownloadGatewayProgramResult.cc | 72 ++ dg/src/model/FindUserGatewayByIdRequest.cc | 40 + dg/src/model/FindUserGatewayByIdResult.cc | 72 ++ dg/src/model/GetUserDatabasesRequest.cc | 128 +++ dg/src/model/GetUserDatabasesResult.cc | 79 ++ .../model/GetUserGatewayInstancesRequest.cc | 40 + dg/src/model/GetUserGatewayInstancesResult.cc | 72 ++ dg/src/model/GetUserGatewaysRequest.cc | 73 ++ dg/src/model/GetUserGatewaysResult.cc | 79 ++ .../model/ListDatabaseAccessPointRequest.cc | 128 +++ dg/src/model/ListDatabaseAccessPointResult.cc | 79 ++ dg/src/model/ModifyDatabaseRequest.cc | 117 +++ dg/src/model/ModifyDatabaseResult.cc | 72 ++ dg/src/model/ModifyGatewayRequest.cc | 62 ++ dg/src/model/ModifyGatewayResult.cc | 72 ++ dg/src/model/RetryDatabaseRequest.cc | 139 +++ dg/src/model/RetryDatabaseResult.cc | 72 ++ dg/src/model/StopGatewayRequest.cc | 51 ++ dg/src/model/StopGatewayResult.cc | 72 ++ 89 files changed, 6804 insertions(+) create mode 100644 dg/CMakeLists.txt create mode 100644 dg/include/alibabacloud/dg/DgClient.h create mode 100644 dg/include/alibabacloud/dg/DgExport.h create mode 100644 dg/include/alibabacloud/dg/model/AddDatabaseListRequest.h create mode 100644 dg/include/alibabacloud/dg/model/AddDatabaseListResult.h create mode 100644 dg/include/alibabacloud/dg/model/AddDatabaseRequest.h create mode 100644 dg/include/alibabacloud/dg/model/AddDatabaseResult.h create mode 100644 dg/include/alibabacloud/dg/model/ConnectDatabaseRequest.h create mode 100644 dg/include/alibabacloud/dg/model/ConnectDatabaseResult.h create mode 100644 dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointRequest.h create mode 100644 dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointResult.h create mode 100644 dg/include/alibabacloud/dg/model/CreateGatewayRequest.h create mode 100644 dg/include/alibabacloud/dg/model/CreateGatewayResult.h create mode 100644 dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeRequest.h create mode 100644 dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeResult.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointRequest.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointResult.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteDatabaseRequest.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteDatabaseResult.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteGatewayInstanceRequest.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteGatewayInstanceResult.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteGatewayRequest.h create mode 100644 dg/include/alibabacloud/dg/model/DeleteGatewayResult.h create mode 100644 dg/include/alibabacloud/dg/model/DescribeRegionsRequest.h create mode 100644 dg/include/alibabacloud/dg/model/DescribeRegionsResult.h create mode 100644 dg/include/alibabacloud/dg/model/DownloadGatewayProgramRequest.h create mode 100644 dg/include/alibabacloud/dg/model/DownloadGatewayProgramResult.h create mode 100644 dg/include/alibabacloud/dg/model/FindUserGatewayByIdRequest.h create mode 100644 dg/include/alibabacloud/dg/model/FindUserGatewayByIdResult.h create mode 100644 dg/include/alibabacloud/dg/model/GetUserDatabasesRequest.h create mode 100644 dg/include/alibabacloud/dg/model/GetUserDatabasesResult.h create mode 100644 dg/include/alibabacloud/dg/model/GetUserGatewayInstancesRequest.h create mode 100644 dg/include/alibabacloud/dg/model/GetUserGatewayInstancesResult.h create mode 100644 dg/include/alibabacloud/dg/model/GetUserGatewaysRequest.h create mode 100644 dg/include/alibabacloud/dg/model/GetUserGatewaysResult.h create mode 100644 dg/include/alibabacloud/dg/model/ListDatabaseAccessPointRequest.h create mode 100644 dg/include/alibabacloud/dg/model/ListDatabaseAccessPointResult.h create mode 100644 dg/include/alibabacloud/dg/model/ModifyDatabaseRequest.h create mode 100644 dg/include/alibabacloud/dg/model/ModifyDatabaseResult.h create mode 100644 dg/include/alibabacloud/dg/model/ModifyGatewayRequest.h create mode 100644 dg/include/alibabacloud/dg/model/ModifyGatewayResult.h create mode 100644 dg/include/alibabacloud/dg/model/RetryDatabaseRequest.h create mode 100644 dg/include/alibabacloud/dg/model/RetryDatabaseResult.h create mode 100644 dg/include/alibabacloud/dg/model/StopGatewayRequest.h create mode 100644 dg/include/alibabacloud/dg/model/StopGatewayResult.h create mode 100644 dg/src/DgClient.cc create mode 100644 dg/src/model/AddDatabaseListRequest.cc create mode 100644 dg/src/model/AddDatabaseListResult.cc create mode 100644 dg/src/model/AddDatabaseRequest.cc create mode 100644 dg/src/model/AddDatabaseResult.cc create mode 100644 dg/src/model/ConnectDatabaseRequest.cc create mode 100644 dg/src/model/ConnectDatabaseResult.cc create mode 100644 dg/src/model/CreateDatabaseAccessPointRequest.cc create mode 100644 dg/src/model/CreateDatabaseAccessPointResult.cc create mode 100644 dg/src/model/CreateGatewayRequest.cc create mode 100644 dg/src/model/CreateGatewayResult.cc create mode 100644 dg/src/model/CreateGatewayVerifyCodeRequest.cc create mode 100644 dg/src/model/CreateGatewayVerifyCodeResult.cc create mode 100644 dg/src/model/DeleteDatabaseAccessPointRequest.cc create mode 100644 dg/src/model/DeleteDatabaseAccessPointResult.cc create mode 100644 dg/src/model/DeleteDatabaseRequest.cc create mode 100644 dg/src/model/DeleteDatabaseResult.cc create mode 100644 dg/src/model/DeleteGatewayInstanceRequest.cc create mode 100644 dg/src/model/DeleteGatewayInstanceResult.cc create mode 100644 dg/src/model/DeleteGatewayRequest.cc create mode 100644 dg/src/model/DeleteGatewayResult.cc create mode 100644 dg/src/model/DescribeRegionsRequest.cc create mode 100644 dg/src/model/DescribeRegionsResult.cc create mode 100644 dg/src/model/DownloadGatewayProgramRequest.cc create mode 100644 dg/src/model/DownloadGatewayProgramResult.cc create mode 100644 dg/src/model/FindUserGatewayByIdRequest.cc create mode 100644 dg/src/model/FindUserGatewayByIdResult.cc create mode 100644 dg/src/model/GetUserDatabasesRequest.cc create mode 100644 dg/src/model/GetUserDatabasesResult.cc create mode 100644 dg/src/model/GetUserGatewayInstancesRequest.cc create mode 100644 dg/src/model/GetUserGatewayInstancesResult.cc create mode 100644 dg/src/model/GetUserGatewaysRequest.cc create mode 100644 dg/src/model/GetUserGatewaysResult.cc create mode 100644 dg/src/model/ListDatabaseAccessPointRequest.cc create mode 100644 dg/src/model/ListDatabaseAccessPointResult.cc create mode 100644 dg/src/model/ModifyDatabaseRequest.cc create mode 100644 dg/src/model/ModifyDatabaseResult.cc create mode 100644 dg/src/model/ModifyGatewayRequest.cc create mode 100644 dg/src/model/ModifyGatewayResult.cc create mode 100644 dg/src/model/RetryDatabaseRequest.cc create mode 100644 dg/src/model/RetryDatabaseResult.cc create mode 100644 dg/src/model/StopGatewayRequest.cc create mode 100644 dg/src/model/StopGatewayResult.cc diff --git a/CHANGELOG b/CHANGELOG index fe43245ff..4ec4434d3 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +2021-01-18 Version: patch +- Generated 2019-03-27 for `dg`. + 2021-01-18 Version: patch - Add a set of API to support device distribution management, including CreateProductDistributeJob, CreateDeviceDistributeJob, QueryDeviceDistributeJob, ListDeviceDistributeJob, QueryDeviceDistributeDetail, DeleteDeviceDistributeJob, ListDistributedDevice, ListDistributedProduct etc. diff --git a/dg/CMakeLists.txt b/dg/CMakeLists.txt new file mode 100644 index 000000000..c09960c6e --- /dev/null +++ b/dg/CMakeLists.txt @@ -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. +# + +set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include) + +set(dg_public_header + include/alibabacloud/dg/DgClient.h + include/alibabacloud/dg/DgExport.h ) + +set(dg_public_header_model + include/alibabacloud/dg/model/AddDatabaseRequest.h + include/alibabacloud/dg/model/AddDatabaseResult.h + include/alibabacloud/dg/model/AddDatabaseListRequest.h + include/alibabacloud/dg/model/AddDatabaseListResult.h + include/alibabacloud/dg/model/ConnectDatabaseRequest.h + include/alibabacloud/dg/model/ConnectDatabaseResult.h + include/alibabacloud/dg/model/CreateDatabaseAccessPointRequest.h + include/alibabacloud/dg/model/CreateDatabaseAccessPointResult.h + include/alibabacloud/dg/model/CreateGatewayRequest.h + include/alibabacloud/dg/model/CreateGatewayResult.h + include/alibabacloud/dg/model/CreateGatewayVerifyCodeRequest.h + include/alibabacloud/dg/model/CreateGatewayVerifyCodeResult.h + include/alibabacloud/dg/model/DeleteDatabaseRequest.h + include/alibabacloud/dg/model/DeleteDatabaseResult.h + include/alibabacloud/dg/model/DeleteDatabaseAccessPointRequest.h + include/alibabacloud/dg/model/DeleteDatabaseAccessPointResult.h + include/alibabacloud/dg/model/DeleteGatewayRequest.h + include/alibabacloud/dg/model/DeleteGatewayResult.h + include/alibabacloud/dg/model/DeleteGatewayInstanceRequest.h + include/alibabacloud/dg/model/DeleteGatewayInstanceResult.h + include/alibabacloud/dg/model/DescribeRegionsRequest.h + include/alibabacloud/dg/model/DescribeRegionsResult.h + include/alibabacloud/dg/model/DownloadGatewayProgramRequest.h + include/alibabacloud/dg/model/DownloadGatewayProgramResult.h + include/alibabacloud/dg/model/FindUserGatewayByIdRequest.h + include/alibabacloud/dg/model/FindUserGatewayByIdResult.h + include/alibabacloud/dg/model/GetUserDatabasesRequest.h + include/alibabacloud/dg/model/GetUserDatabasesResult.h + include/alibabacloud/dg/model/GetUserGatewayInstancesRequest.h + include/alibabacloud/dg/model/GetUserGatewayInstancesResult.h + include/alibabacloud/dg/model/GetUserGatewaysRequest.h + include/alibabacloud/dg/model/GetUserGatewaysResult.h + include/alibabacloud/dg/model/ListDatabaseAccessPointRequest.h + include/alibabacloud/dg/model/ListDatabaseAccessPointResult.h + include/alibabacloud/dg/model/ModifyDatabaseRequest.h + include/alibabacloud/dg/model/ModifyDatabaseResult.h + include/alibabacloud/dg/model/ModifyGatewayRequest.h + include/alibabacloud/dg/model/ModifyGatewayResult.h + include/alibabacloud/dg/model/RetryDatabaseRequest.h + include/alibabacloud/dg/model/RetryDatabaseResult.h + include/alibabacloud/dg/model/StopGatewayRequest.h + include/alibabacloud/dg/model/StopGatewayResult.h ) + +set(dg_src + src/DgClient.cc + src/model/AddDatabaseRequest.cc + src/model/AddDatabaseResult.cc + src/model/AddDatabaseListRequest.cc + src/model/AddDatabaseListResult.cc + src/model/ConnectDatabaseRequest.cc + src/model/ConnectDatabaseResult.cc + src/model/CreateDatabaseAccessPointRequest.cc + src/model/CreateDatabaseAccessPointResult.cc + src/model/CreateGatewayRequest.cc + src/model/CreateGatewayResult.cc + src/model/CreateGatewayVerifyCodeRequest.cc + src/model/CreateGatewayVerifyCodeResult.cc + src/model/DeleteDatabaseRequest.cc + src/model/DeleteDatabaseResult.cc + src/model/DeleteDatabaseAccessPointRequest.cc + src/model/DeleteDatabaseAccessPointResult.cc + src/model/DeleteGatewayRequest.cc + src/model/DeleteGatewayResult.cc + src/model/DeleteGatewayInstanceRequest.cc + src/model/DeleteGatewayInstanceResult.cc + src/model/DescribeRegionsRequest.cc + src/model/DescribeRegionsResult.cc + src/model/DownloadGatewayProgramRequest.cc + src/model/DownloadGatewayProgramResult.cc + src/model/FindUserGatewayByIdRequest.cc + src/model/FindUserGatewayByIdResult.cc + src/model/GetUserDatabasesRequest.cc + src/model/GetUserDatabasesResult.cc + src/model/GetUserGatewayInstancesRequest.cc + src/model/GetUserGatewayInstancesResult.cc + src/model/GetUserGatewaysRequest.cc + src/model/GetUserGatewaysResult.cc + src/model/ListDatabaseAccessPointRequest.cc + src/model/ListDatabaseAccessPointResult.cc + src/model/ModifyDatabaseRequest.cc + src/model/ModifyDatabaseResult.cc + src/model/ModifyGatewayRequest.cc + src/model/ModifyGatewayResult.cc + src/model/RetryDatabaseRequest.cc + src/model/RetryDatabaseResult.cc + src/model/StopGatewayRequest.cc + src/model/StopGatewayResult.cc ) + +add_library(dg ${LIB_TYPE} + ${dg_public_header} + ${dg_public_header_model} + ${dg_src}) + +set_target_properties(dg + 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}dg + ) + +if(${LIB_TYPE} STREQUAL "SHARED") + set_target_properties(dg + PROPERTIES + DEFINE_SYMBOL ALIBABACLOUD_DG_LIBRARY) +endif() + +target_include_directories(dg + PRIVATE include + ${CMAKE_SOURCE_DIR}/core/include + ) +target_link_libraries(dg + core) + +if(CMAKE_HOST_WIN32) + ExternalProject_Get_Property(jsoncpp INSTALL_DIR) + set(jsoncpp_install_dir ${INSTALL_DIR}) + add_dependencies(dg + jsoncpp) + target_include_directories(dg + PRIVATE ${jsoncpp_install_dir}/include) + target_link_libraries(dg + ${jsoncpp_install_dir}/lib/jsoncpp.lib) + set_target_properties(dg + PROPERTIES + COMPILE_OPTIONS "/bigobj") +else() + target_include_directories(dg + PRIVATE /usr/include/jsoncpp) + target_link_libraries(dg + jsoncpp) +endif() + +install(FILES ${dg_public_header} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/dg) +install(FILES ${dg_public_header_model} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/dg/model) +install(TARGETS dg + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + ) \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/DgClient.h b/dg/include/alibabacloud/dg/DgClient.h new file mode 100644 index 000000000..b9405602f --- /dev/null +++ b/dg/include/alibabacloud/dg/DgClient.h @@ -0,0 +1,214 @@ +/* + * 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_DG_DGCLIENT_H_ +#define ALIBABACLOUD_DG_DGCLIENT_H_ + +#include +#include +#include +#include +#include "DgExport.h" +#include "model/AddDatabaseRequest.h" +#include "model/AddDatabaseResult.h" +#include "model/AddDatabaseListRequest.h" +#include "model/AddDatabaseListResult.h" +#include "model/ConnectDatabaseRequest.h" +#include "model/ConnectDatabaseResult.h" +#include "model/CreateDatabaseAccessPointRequest.h" +#include "model/CreateDatabaseAccessPointResult.h" +#include "model/CreateGatewayRequest.h" +#include "model/CreateGatewayResult.h" +#include "model/CreateGatewayVerifyCodeRequest.h" +#include "model/CreateGatewayVerifyCodeResult.h" +#include "model/DeleteDatabaseRequest.h" +#include "model/DeleteDatabaseResult.h" +#include "model/DeleteDatabaseAccessPointRequest.h" +#include "model/DeleteDatabaseAccessPointResult.h" +#include "model/DeleteGatewayRequest.h" +#include "model/DeleteGatewayResult.h" +#include "model/DeleteGatewayInstanceRequest.h" +#include "model/DeleteGatewayInstanceResult.h" +#include "model/DescribeRegionsRequest.h" +#include "model/DescribeRegionsResult.h" +#include "model/DownloadGatewayProgramRequest.h" +#include "model/DownloadGatewayProgramResult.h" +#include "model/FindUserGatewayByIdRequest.h" +#include "model/FindUserGatewayByIdResult.h" +#include "model/GetUserDatabasesRequest.h" +#include "model/GetUserDatabasesResult.h" +#include "model/GetUserGatewayInstancesRequest.h" +#include "model/GetUserGatewayInstancesResult.h" +#include "model/GetUserGatewaysRequest.h" +#include "model/GetUserGatewaysResult.h" +#include "model/ListDatabaseAccessPointRequest.h" +#include "model/ListDatabaseAccessPointResult.h" +#include "model/ModifyDatabaseRequest.h" +#include "model/ModifyDatabaseResult.h" +#include "model/ModifyGatewayRequest.h" +#include "model/ModifyGatewayResult.h" +#include "model/RetryDatabaseRequest.h" +#include "model/RetryDatabaseResult.h" +#include "model/StopGatewayRequest.h" +#include "model/StopGatewayResult.h" + + +namespace AlibabaCloud +{ + namespace Dg + { + class ALIBABACLOUD_DG_EXPORT DgClient : public RpcServiceClient + { + public: + typedef Outcome AddDatabaseOutcome; + typedef std::future AddDatabaseOutcomeCallable; + typedef std::function&)> AddDatabaseAsyncHandler; + typedef Outcome AddDatabaseListOutcome; + typedef std::future AddDatabaseListOutcomeCallable; + typedef std::function&)> AddDatabaseListAsyncHandler; + typedef Outcome ConnectDatabaseOutcome; + typedef std::future ConnectDatabaseOutcomeCallable; + typedef std::function&)> ConnectDatabaseAsyncHandler; + typedef Outcome CreateDatabaseAccessPointOutcome; + typedef std::future CreateDatabaseAccessPointOutcomeCallable; + typedef std::function&)> CreateDatabaseAccessPointAsyncHandler; + typedef Outcome CreateGatewayOutcome; + typedef std::future CreateGatewayOutcomeCallable; + typedef std::function&)> CreateGatewayAsyncHandler; + typedef Outcome CreateGatewayVerifyCodeOutcome; + typedef std::future CreateGatewayVerifyCodeOutcomeCallable; + typedef std::function&)> CreateGatewayVerifyCodeAsyncHandler; + typedef Outcome DeleteDatabaseOutcome; + typedef std::future DeleteDatabaseOutcomeCallable; + typedef std::function&)> DeleteDatabaseAsyncHandler; + typedef Outcome DeleteDatabaseAccessPointOutcome; + typedef std::future DeleteDatabaseAccessPointOutcomeCallable; + typedef std::function&)> DeleteDatabaseAccessPointAsyncHandler; + typedef Outcome DeleteGatewayOutcome; + typedef std::future DeleteGatewayOutcomeCallable; + typedef std::function&)> DeleteGatewayAsyncHandler; + typedef Outcome DeleteGatewayInstanceOutcome; + typedef std::future DeleteGatewayInstanceOutcomeCallable; + typedef std::function&)> DeleteGatewayInstanceAsyncHandler; + typedef Outcome DescribeRegionsOutcome; + typedef std::future DescribeRegionsOutcomeCallable; + typedef std::function&)> DescribeRegionsAsyncHandler; + typedef Outcome DownloadGatewayProgramOutcome; + typedef std::future DownloadGatewayProgramOutcomeCallable; + typedef std::function&)> DownloadGatewayProgramAsyncHandler; + typedef Outcome FindUserGatewayByIdOutcome; + typedef std::future FindUserGatewayByIdOutcomeCallable; + typedef std::function&)> FindUserGatewayByIdAsyncHandler; + typedef Outcome GetUserDatabasesOutcome; + typedef std::future GetUserDatabasesOutcomeCallable; + typedef std::function&)> GetUserDatabasesAsyncHandler; + typedef Outcome GetUserGatewayInstancesOutcome; + typedef std::future GetUserGatewayInstancesOutcomeCallable; + typedef std::function&)> GetUserGatewayInstancesAsyncHandler; + typedef Outcome GetUserGatewaysOutcome; + typedef std::future GetUserGatewaysOutcomeCallable; + typedef std::function&)> GetUserGatewaysAsyncHandler; + typedef Outcome ListDatabaseAccessPointOutcome; + typedef std::future ListDatabaseAccessPointOutcomeCallable; + typedef std::function&)> ListDatabaseAccessPointAsyncHandler; + typedef Outcome ModifyDatabaseOutcome; + typedef std::future ModifyDatabaseOutcomeCallable; + typedef std::function&)> ModifyDatabaseAsyncHandler; + typedef Outcome ModifyGatewayOutcome; + typedef std::future ModifyGatewayOutcomeCallable; + typedef std::function&)> ModifyGatewayAsyncHandler; + typedef Outcome RetryDatabaseOutcome; + typedef std::future RetryDatabaseOutcomeCallable; + typedef std::function&)> RetryDatabaseAsyncHandler; + typedef Outcome StopGatewayOutcome; + typedef std::future StopGatewayOutcomeCallable; + typedef std::function&)> StopGatewayAsyncHandler; + + DgClient(const Credentials &credentials, const ClientConfiguration &configuration); + DgClient(const std::shared_ptr &credentialsProvider, const ClientConfiguration &configuration); + DgClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration); + ~DgClient(); + AddDatabaseOutcome addDatabase(const Model::AddDatabaseRequest &request)const; + void addDatabaseAsync(const Model::AddDatabaseRequest& request, const AddDatabaseAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + AddDatabaseOutcomeCallable addDatabaseCallable(const Model::AddDatabaseRequest& request) const; + AddDatabaseListOutcome addDatabaseList(const Model::AddDatabaseListRequest &request)const; + void addDatabaseListAsync(const Model::AddDatabaseListRequest& request, const AddDatabaseListAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + AddDatabaseListOutcomeCallable addDatabaseListCallable(const Model::AddDatabaseListRequest& request) const; + ConnectDatabaseOutcome connectDatabase(const Model::ConnectDatabaseRequest &request)const; + void connectDatabaseAsync(const Model::ConnectDatabaseRequest& request, const ConnectDatabaseAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ConnectDatabaseOutcomeCallable connectDatabaseCallable(const Model::ConnectDatabaseRequest& request) const; + CreateDatabaseAccessPointOutcome createDatabaseAccessPoint(const Model::CreateDatabaseAccessPointRequest &request)const; + void createDatabaseAccessPointAsync(const Model::CreateDatabaseAccessPointRequest& request, const CreateDatabaseAccessPointAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateDatabaseAccessPointOutcomeCallable createDatabaseAccessPointCallable(const Model::CreateDatabaseAccessPointRequest& request) const; + CreateGatewayOutcome createGateway(const Model::CreateGatewayRequest &request)const; + void createGatewayAsync(const Model::CreateGatewayRequest& request, const CreateGatewayAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateGatewayOutcomeCallable createGatewayCallable(const Model::CreateGatewayRequest& request) const; + CreateGatewayVerifyCodeOutcome createGatewayVerifyCode(const Model::CreateGatewayVerifyCodeRequest &request)const; + void createGatewayVerifyCodeAsync(const Model::CreateGatewayVerifyCodeRequest& request, const CreateGatewayVerifyCodeAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateGatewayVerifyCodeOutcomeCallable createGatewayVerifyCodeCallable(const Model::CreateGatewayVerifyCodeRequest& request) const; + DeleteDatabaseOutcome deleteDatabase(const Model::DeleteDatabaseRequest &request)const; + void deleteDatabaseAsync(const Model::DeleteDatabaseRequest& request, const DeleteDatabaseAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteDatabaseOutcomeCallable deleteDatabaseCallable(const Model::DeleteDatabaseRequest& request) const; + DeleteDatabaseAccessPointOutcome deleteDatabaseAccessPoint(const Model::DeleteDatabaseAccessPointRequest &request)const; + void deleteDatabaseAccessPointAsync(const Model::DeleteDatabaseAccessPointRequest& request, const DeleteDatabaseAccessPointAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteDatabaseAccessPointOutcomeCallable deleteDatabaseAccessPointCallable(const Model::DeleteDatabaseAccessPointRequest& request) const; + DeleteGatewayOutcome deleteGateway(const Model::DeleteGatewayRequest &request)const; + void deleteGatewayAsync(const Model::DeleteGatewayRequest& request, const DeleteGatewayAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteGatewayOutcomeCallable deleteGatewayCallable(const Model::DeleteGatewayRequest& request) const; + DeleteGatewayInstanceOutcome deleteGatewayInstance(const Model::DeleteGatewayInstanceRequest &request)const; + void deleteGatewayInstanceAsync(const Model::DeleteGatewayInstanceRequest& request, const DeleteGatewayInstanceAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteGatewayInstanceOutcomeCallable deleteGatewayInstanceCallable(const Model::DeleteGatewayInstanceRequest& request) const; + DescribeRegionsOutcome describeRegions(const Model::DescribeRegionsRequest &request)const; + void describeRegionsAsync(const Model::DescribeRegionsRequest& request, const DescribeRegionsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeRegionsOutcomeCallable describeRegionsCallable(const Model::DescribeRegionsRequest& request) const; + DownloadGatewayProgramOutcome downloadGatewayProgram(const Model::DownloadGatewayProgramRequest &request)const; + void downloadGatewayProgramAsync(const Model::DownloadGatewayProgramRequest& request, const DownloadGatewayProgramAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DownloadGatewayProgramOutcomeCallable downloadGatewayProgramCallable(const Model::DownloadGatewayProgramRequest& request) const; + FindUserGatewayByIdOutcome findUserGatewayById(const Model::FindUserGatewayByIdRequest &request)const; + void findUserGatewayByIdAsync(const Model::FindUserGatewayByIdRequest& request, const FindUserGatewayByIdAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + FindUserGatewayByIdOutcomeCallable findUserGatewayByIdCallable(const Model::FindUserGatewayByIdRequest& request) const; + GetUserDatabasesOutcome getUserDatabases(const Model::GetUserDatabasesRequest &request)const; + void getUserDatabasesAsync(const Model::GetUserDatabasesRequest& request, const GetUserDatabasesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetUserDatabasesOutcomeCallable getUserDatabasesCallable(const Model::GetUserDatabasesRequest& request) const; + GetUserGatewayInstancesOutcome getUserGatewayInstances(const Model::GetUserGatewayInstancesRequest &request)const; + void getUserGatewayInstancesAsync(const Model::GetUserGatewayInstancesRequest& request, const GetUserGatewayInstancesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetUserGatewayInstancesOutcomeCallable getUserGatewayInstancesCallable(const Model::GetUserGatewayInstancesRequest& request) const; + GetUserGatewaysOutcome getUserGateways(const Model::GetUserGatewaysRequest &request)const; + void getUserGatewaysAsync(const Model::GetUserGatewaysRequest& request, const GetUserGatewaysAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetUserGatewaysOutcomeCallable getUserGatewaysCallable(const Model::GetUserGatewaysRequest& request) const; + ListDatabaseAccessPointOutcome listDatabaseAccessPoint(const Model::ListDatabaseAccessPointRequest &request)const; + void listDatabaseAccessPointAsync(const Model::ListDatabaseAccessPointRequest& request, const ListDatabaseAccessPointAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListDatabaseAccessPointOutcomeCallable listDatabaseAccessPointCallable(const Model::ListDatabaseAccessPointRequest& request) const; + ModifyDatabaseOutcome modifyDatabase(const Model::ModifyDatabaseRequest &request)const; + void modifyDatabaseAsync(const Model::ModifyDatabaseRequest& request, const ModifyDatabaseAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ModifyDatabaseOutcomeCallable modifyDatabaseCallable(const Model::ModifyDatabaseRequest& request) const; + ModifyGatewayOutcome modifyGateway(const Model::ModifyGatewayRequest &request)const; + void modifyGatewayAsync(const Model::ModifyGatewayRequest& request, const ModifyGatewayAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ModifyGatewayOutcomeCallable modifyGatewayCallable(const Model::ModifyGatewayRequest& request) const; + RetryDatabaseOutcome retryDatabase(const Model::RetryDatabaseRequest &request)const; + void retryDatabaseAsync(const Model::RetryDatabaseRequest& request, const RetryDatabaseAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + RetryDatabaseOutcomeCallable retryDatabaseCallable(const Model::RetryDatabaseRequest& request) const; + StopGatewayOutcome stopGateway(const Model::StopGatewayRequest &request)const; + void stopGatewayAsync(const Model::StopGatewayRequest& request, const StopGatewayAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + StopGatewayOutcomeCallable stopGatewayCallable(const Model::StopGatewayRequest& request) const; + + private: + std::shared_ptr endpointProvider_; + }; + } +} + +#endif // !ALIBABACLOUD_DG_DGCLIENT_H_ diff --git a/dg/include/alibabacloud/dg/DgExport.h b/dg/include/alibabacloud/dg/DgExport.h new file mode 100644 index 000000000..7b69f87f9 --- /dev/null +++ b/dg/include/alibabacloud/dg/DgExport.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_DG_DGEXPORT_H_ +#define ALIBABACLOUD_DG_DGEXPORT_H_ + +#include + +#if defined(ALIBABACLOUD_SHARED) +# if defined(ALIBABACLOUD_DG_LIBRARY) +# define ALIBABACLOUD_DG_EXPORT ALIBABACLOUD_DECL_EXPORT +# else +# define ALIBABACLOUD_DG_EXPORT ALIBABACLOUD_DECL_IMPORT +# endif +#else +# define ALIBABACLOUD_DG_EXPORT +#endif + +#endif // !ALIBABACLOUD_DG_DGEXPORT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/AddDatabaseListRequest.h b/dg/include/alibabacloud/dg/model/AddDatabaseListRequest.h new file mode 100644 index 000000000..2db524876 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/AddDatabaseListRequest.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_DG_MODEL_ADDDATABASELISTREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_ADDDATABASELISTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT AddDatabaseListRequest : public RpcServiceRequest + { + + public: + AddDatabaseListRequest(); + ~AddDatabaseListRequest(); + + std::string getDatabaseString()const; + void setDatabaseString(const std::string& databaseString); + std::string getClientToken()const; + void setClientToken(const std::string& clientToken); + + private: + std::string databaseString_; + std::string clientToken_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_ADDDATABASELISTREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/AddDatabaseListResult.h b/dg/include/alibabacloud/dg/model/AddDatabaseListResult.h new file mode 100644 index 000000000..bc34ea924 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/AddDatabaseListResult.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_DG_MODEL_ADDDATABASELISTRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_ADDDATABASELISTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT AddDatabaseListResult : public ServiceResult + { + public: + + + AddDatabaseListResult(); + explicit AddDatabaseListResult(const std::string &payload); + ~AddDatabaseListResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_ADDDATABASELISTRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/AddDatabaseRequest.h b/dg/include/alibabacloud/dg/model/AddDatabaseRequest.h new file mode 100644 index 000000000..338488d7a --- /dev/null +++ b/dg/include/alibabacloud/dg/model/AddDatabaseRequest.h @@ -0,0 +1,75 @@ +/* + * 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_DG_MODEL_ADDDATABASEREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_ADDDATABASEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT AddDatabaseRequest : public RpcServiceRequest + { + + public: + AddDatabaseRequest(); + ~AddDatabaseRequest(); + + std::string getClientToken()const; + void setClientToken(const std::string& clientToken); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getHost()const; + void setHost(const std::string& host); + std::string getDbUserName()const; + void setDbUserName(const std::string& dbUserName); + std::string getDbDescription()const; + void setDbDescription(const std::string& dbDescription); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + std::string getDbName()const; + void setDbName(const std::string& dbName); + int getPort()const; + void setPort(int port); + std::string getDbPassword()const; + void setDbPassword(const std::string& dbPassword); + std::string getDbType()const; + void setDbType(const std::string& dbType); + + private: + std::string clientToken_; + std::string regionId_; + std::string host_; + std::string dbUserName_; + std::string dbDescription_; + std::string gatewayId_; + std::string dbName_; + int port_; + std::string dbPassword_; + std::string dbType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_ADDDATABASEREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/AddDatabaseResult.h b/dg/include/alibabacloud/dg/model/AddDatabaseResult.h new file mode 100644 index 000000000..2d0f09377 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/AddDatabaseResult.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_DG_MODEL_ADDDATABASERESULT_H_ +#define ALIBABACLOUD_DG_MODEL_ADDDATABASERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT AddDatabaseResult : public ServiceResult + { + public: + + + AddDatabaseResult(); + explicit AddDatabaseResult(const std::string &payload); + ~AddDatabaseResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_ADDDATABASERESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ConnectDatabaseRequest.h b/dg/include/alibabacloud/dg/model/ConnectDatabaseRequest.h new file mode 100644 index 000000000..ba711515b --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ConnectDatabaseRequest.h @@ -0,0 +1,66 @@ +/* + * 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_DG_MODEL_CONNECTDATABASEREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_CONNECTDATABASEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ConnectDatabaseRequest : public RpcServiceRequest + { + + public: + ConnectDatabaseRequest(); + ~ConnectDatabaseRequest(); + + std::string getDbName()const; + void setDbName(const std::string& dbName); + int getPort()const; + void setPort(int port); + std::string getDbPassword()const; + void setDbPassword(const std::string& dbPassword); + std::string getHost()const; + void setHost(const std::string& host); + std::string getDbType()const; + void setDbType(const std::string& dbType); + std::string getDbUserName()const; + void setDbUserName(const std::string& dbUserName); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string dbName_; + int port_; + std::string dbPassword_; + std::string host_; + std::string dbType_; + std::string dbUserName_; + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CONNECTDATABASEREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ConnectDatabaseResult.h b/dg/include/alibabacloud/dg/model/ConnectDatabaseResult.h new file mode 100644 index 000000000..ff1c9b44c --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ConnectDatabaseResult.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_DG_MODEL_CONNECTDATABASERESULT_H_ +#define ALIBABACLOUD_DG_MODEL_CONNECTDATABASERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ConnectDatabaseResult : public ServiceResult + { + public: + + + ConnectDatabaseResult(); + explicit ConnectDatabaseResult(const std::string &payload); + ~ConnectDatabaseResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CONNECTDATABASERESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointRequest.h b/dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointRequest.h new file mode 100644 index 000000000..bd365cd4e --- /dev/null +++ b/dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointRequest.h @@ -0,0 +1,66 @@ +/* + * 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_DG_MODEL_CREATEDATABASEACCESSPOINTREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_CREATEDATABASEACCESSPOINTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT CreateDatabaseAccessPointRequest : public RpcServiceRequest + { + + public: + CreateDatabaseAccessPointRequest(); + ~CreateDatabaseAccessPointRequest(); + + std::string getVpcAZone()const; + void setVpcAZone(const std::string& vpcAZone); + std::string getClientToken()const; + void setClientToken(const std::string& clientToken); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getDbInstanceId()const; + void setDbInstanceId(const std::string& dbInstanceId); + std::string getVpcRegionId()const; + void setVpcRegionId(const std::string& vpcRegionId); + std::string getVSwitchId()const; + void setVSwitchId(const std::string& vSwitchId); + std::string getVpcId()const; + void setVpcId(const std::string& vpcId); + + private: + std::string vpcAZone_; + std::string clientToken_; + std::string regionId_; + std::string dbInstanceId_; + std::string vpcRegionId_; + std::string vSwitchId_; + std::string vpcId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CREATEDATABASEACCESSPOINTREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointResult.h b/dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointResult.h new file mode 100644 index 000000000..e86aedf3a --- /dev/null +++ b/dg/include/alibabacloud/dg/model/CreateDatabaseAccessPointResult.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_DG_MODEL_CREATEDATABASEACCESSPOINTRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_CREATEDATABASEACCESSPOINTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT CreateDatabaseAccessPointResult : public ServiceResult + { + public: + + + CreateDatabaseAccessPointResult(); + explicit CreateDatabaseAccessPointResult(const std::string &payload); + ~CreateDatabaseAccessPointResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CREATEDATABASEACCESSPOINTRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/CreateGatewayRequest.h b/dg/include/alibabacloud/dg/model/CreateGatewayRequest.h new file mode 100644 index 000000000..11127565a --- /dev/null +++ b/dg/include/alibabacloud/dg/model/CreateGatewayRequest.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_DG_MODEL_CREATEGATEWAYREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_CREATEGATEWAYREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT CreateGatewayRequest : public RpcServiceRequest + { + + public: + CreateGatewayRequest(); + ~CreateGatewayRequest(); + + std::string getGatewayDesc()const; + void setGatewayDesc(const std::string& gatewayDesc); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getGatewayName()const; + void setGatewayName(const std::string& gatewayName); + + private: + std::string gatewayDesc_; + std::string regionId_; + std::string gatewayName_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CREATEGATEWAYREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/CreateGatewayResult.h b/dg/include/alibabacloud/dg/model/CreateGatewayResult.h new file mode 100644 index 000000000..bcdf6464d --- /dev/null +++ b/dg/include/alibabacloud/dg/model/CreateGatewayResult.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_DG_MODEL_CREATEGATEWAYRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_CREATEGATEWAYRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT CreateGatewayResult : public ServiceResult + { + public: + + + CreateGatewayResult(); + explicit CreateGatewayResult(const std::string &payload); + ~CreateGatewayResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CREATEGATEWAYRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeRequest.h b/dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeRequest.h new file mode 100644 index 000000000..e48096286 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeRequest.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_DG_MODEL_CREATEGATEWAYVERIFYCODEREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_CREATEGATEWAYVERIFYCODEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT CreateGatewayVerifyCodeRequest : public RpcServiceRequest + { + + public: + CreateGatewayVerifyCodeRequest(); + ~CreateGatewayVerifyCodeRequest(); + + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CREATEGATEWAYVERIFYCODEREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeResult.h b/dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeResult.h new file mode 100644 index 000000000..ca69706c0 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/CreateGatewayVerifyCodeResult.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_DG_MODEL_CREATEGATEWAYVERIFYCODERESULT_H_ +#define ALIBABACLOUD_DG_MODEL_CREATEGATEWAYVERIFYCODERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT CreateGatewayVerifyCodeResult : public ServiceResult + { + public: + + + CreateGatewayVerifyCodeResult(); + explicit CreateGatewayVerifyCodeResult(const std::string &payload); + ~CreateGatewayVerifyCodeResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_CREATEGATEWAYVERIFYCODERESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointRequest.h b/dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointRequest.h new file mode 100644 index 000000000..ae003178f --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointRequest.h @@ -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. + */ + +#ifndef ALIBABACLOUD_DG_MODEL_DELETEDATABASEACCESSPOINTREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEDATABASEACCESSPOINTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteDatabaseAccessPointRequest : public RpcServiceRequest + { + + public: + DeleteDatabaseAccessPointRequest(); + ~DeleteDatabaseAccessPointRequest(); + + std::string getVpcAZone()const; + void setVpcAZone(const std::string& vpcAZone); + std::string getVpcRegionId()const; + void setVpcRegionId(const std::string& vpcRegionId); + std::string getVSwitchId()const; + void setVSwitchId(const std::string& vSwitchId); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getVpcId()const; + void setVpcId(const std::string& vpcId); + std::string getDbInstanceId()const; + void setDbInstanceId(const std::string& dbInstanceId); + + private: + std::string vpcAZone_; + std::string vpcRegionId_; + std::string vSwitchId_; + std::string regionId_; + std::string vpcId_; + std::string dbInstanceId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEDATABASEACCESSPOINTREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointResult.h b/dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointResult.h new file mode 100644 index 000000000..abf8da790 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteDatabaseAccessPointResult.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_DG_MODEL_DELETEDATABASEACCESSPOINTRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEDATABASEACCESSPOINTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteDatabaseAccessPointResult : public ServiceResult + { + public: + + + DeleteDatabaseAccessPointResult(); + explicit DeleteDatabaseAccessPointResult(const std::string &payload); + ~DeleteDatabaseAccessPointResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEDATABASEACCESSPOINTRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteDatabaseRequest.h b/dg/include/alibabacloud/dg/model/DeleteDatabaseRequest.h new file mode 100644 index 000000000..c327eaf06 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteDatabaseRequest.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_DG_MODEL_DELETEDATABASEREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEDATABASEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteDatabaseRequest : public RpcServiceRequest + { + + public: + DeleteDatabaseRequest(); + ~DeleteDatabaseRequest(); + + std::string getInstanceId()const; + void setInstanceId(const std::string& instanceId); + + private: + std::string instanceId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEDATABASEREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteDatabaseResult.h b/dg/include/alibabacloud/dg/model/DeleteDatabaseResult.h new file mode 100644 index 000000000..818d62d9d --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteDatabaseResult.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_DG_MODEL_DELETEDATABASERESULT_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEDATABASERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteDatabaseResult : public ServiceResult + { + public: + + + DeleteDatabaseResult(); + explicit DeleteDatabaseResult(const std::string &payload); + ~DeleteDatabaseResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEDATABASERESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteGatewayInstanceRequest.h b/dg/include/alibabacloud/dg/model/DeleteGatewayInstanceRequest.h new file mode 100644 index 000000000..6436c5530 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteGatewayInstanceRequest.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_DG_MODEL_DELETEGATEWAYINSTANCEREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEGATEWAYINSTANCEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteGatewayInstanceRequest : public RpcServiceRequest + { + + public: + DeleteGatewayInstanceRequest(); + ~DeleteGatewayInstanceRequest(); + + std::string getGatewayInstanceId()const; + void setGatewayInstanceId(const std::string& gatewayInstanceId); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string gatewayInstanceId_; + std::string regionId_; + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEGATEWAYINSTANCEREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteGatewayInstanceResult.h b/dg/include/alibabacloud/dg/model/DeleteGatewayInstanceResult.h new file mode 100644 index 000000000..3c7bd690b --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteGatewayInstanceResult.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_DG_MODEL_DELETEGATEWAYINSTANCERESULT_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEGATEWAYINSTANCERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteGatewayInstanceResult : public ServiceResult + { + public: + + + DeleteGatewayInstanceResult(); + explicit DeleteGatewayInstanceResult(const std::string &payload); + ~DeleteGatewayInstanceResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEGATEWAYINSTANCERESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteGatewayRequest.h b/dg/include/alibabacloud/dg/model/DeleteGatewayRequest.h new file mode 100644 index 000000000..e3b52295e --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteGatewayRequest.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_DG_MODEL_DELETEGATEWAYREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEGATEWAYREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteGatewayRequest : public RpcServiceRequest + { + + public: + DeleteGatewayRequest(); + ~DeleteGatewayRequest(); + + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEGATEWAYREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DeleteGatewayResult.h b/dg/include/alibabacloud/dg/model/DeleteGatewayResult.h new file mode 100644 index 000000000..cd6090db4 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DeleteGatewayResult.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_DG_MODEL_DELETEGATEWAYRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_DELETEGATEWAYRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DeleteGatewayResult : public ServiceResult + { + public: + + + DeleteGatewayResult(); + explicit DeleteGatewayResult(const std::string &payload); + ~DeleteGatewayResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DELETEGATEWAYRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DescribeRegionsRequest.h b/dg/include/alibabacloud/dg/model/DescribeRegionsRequest.h new file mode 100644 index 000000000..7ed98e9ca --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DescribeRegionsRequest.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_DG_MODEL_DESCRIBEREGIONSREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_DESCRIBEREGIONSREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DescribeRegionsRequest : public RpcServiceRequest + { + + public: + DescribeRegionsRequest(); + ~DescribeRegionsRequest(); + + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + + private: + std::string regionId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DESCRIBEREGIONSREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DescribeRegionsResult.h b/dg/include/alibabacloud/dg/model/DescribeRegionsResult.h new file mode 100644 index 000000000..32fe4b7bd --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DescribeRegionsResult.h @@ -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. + */ + +#ifndef ALIBABACLOUD_DG_MODEL_DESCRIBEREGIONSRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_DESCRIBEREGIONSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DescribeRegionsResult : public ServiceResult + { + public: + struct Region + { + std::string regionId; + std::string regionEndpoint; + std::string localName; + }; + + + DescribeRegionsResult(); + explicit DescribeRegionsResult(const std::string &payload); + ~DescribeRegionsResult(); + std::string getErrorMsg()const; + std::vector getRegions()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::vector regions_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DESCRIBEREGIONSRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DownloadGatewayProgramRequest.h b/dg/include/alibabacloud/dg/model/DownloadGatewayProgramRequest.h new file mode 100644 index 000000000..1df653701 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DownloadGatewayProgramRequest.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_DG_MODEL_DOWNLOADGATEWAYPROGRAMREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_DOWNLOADGATEWAYPROGRAMREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DownloadGatewayProgramRequest : public RpcServiceRequest + { + + public: + DownloadGatewayProgramRequest(); + ~DownloadGatewayProgramRequest(); + + std::string getUserOS()const; + void setUserOS(const std::string& userOS); + std::string getDgVersion()const; + void setDgVersion(const std::string& dgVersion); + + private: + std::string userOS_; + std::string dgVersion_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DOWNLOADGATEWAYPROGRAMREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/DownloadGatewayProgramResult.h b/dg/include/alibabacloud/dg/model/DownloadGatewayProgramResult.h new file mode 100644 index 000000000..ea824cd70 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/DownloadGatewayProgramResult.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_DG_MODEL_DOWNLOADGATEWAYPROGRAMRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_DOWNLOADGATEWAYPROGRAMRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT DownloadGatewayProgramResult : public ServiceResult + { + public: + + + DownloadGatewayProgramResult(); + explicit DownloadGatewayProgramResult(const std::string &payload); + ~DownloadGatewayProgramResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_DOWNLOADGATEWAYPROGRAMRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/FindUserGatewayByIdRequest.h b/dg/include/alibabacloud/dg/model/FindUserGatewayByIdRequest.h new file mode 100644 index 000000000..c6992aaff --- /dev/null +++ b/dg/include/alibabacloud/dg/model/FindUserGatewayByIdRequest.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_DG_MODEL_FINDUSERGATEWAYBYIDREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_FINDUSERGATEWAYBYIDREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT FindUserGatewayByIdRequest : public RpcServiceRequest + { + + public: + FindUserGatewayByIdRequest(); + ~FindUserGatewayByIdRequest(); + + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_FINDUSERGATEWAYBYIDREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/FindUserGatewayByIdResult.h b/dg/include/alibabacloud/dg/model/FindUserGatewayByIdResult.h new file mode 100644 index 000000000..f1e7660f5 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/FindUserGatewayByIdResult.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_DG_MODEL_FINDUSERGATEWAYBYIDRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_FINDUSERGATEWAYBYIDRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT FindUserGatewayByIdResult : public ServiceResult + { + public: + + + FindUserGatewayByIdResult(); + explicit FindUserGatewayByIdResult(const std::string &payload); + ~FindUserGatewayByIdResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_FINDUSERGATEWAYBYIDRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/GetUserDatabasesRequest.h b/dg/include/alibabacloud/dg/model/GetUserDatabasesRequest.h new file mode 100644 index 000000000..741bed94e --- /dev/null +++ b/dg/include/alibabacloud/dg/model/GetUserDatabasesRequest.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_DG_MODEL_GETUSERDATABASESREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_GETUSERDATABASESREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT GetUserDatabasesRequest : public RpcServiceRequest + { + + public: + GetUserDatabasesRequest(); + ~GetUserDatabasesRequest(); + + std::string getSearchKey()const; + void setSearchKey(const std::string& searchKey); + std::string getPageNumber()const; + void setPageNumber(const std::string& pageNumber); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getPageSize()const; + void setPageSize(const std::string& pageSize); + std::string getHost()const; + void setHost(const std::string& host); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + std::string getInstanceId()const; + void setInstanceId(const std::string& instanceId); + int getPort()const; + void setPort(int port); + std::string getDbType()const; + void setDbType(const std::string& dbType); + + private: + std::string searchKey_; + std::string pageNumber_; + std::string regionId_; + std::string pageSize_; + std::string host_; + std::string gatewayId_; + std::string instanceId_; + int port_; + std::string dbType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_GETUSERDATABASESREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/GetUserDatabasesResult.h b/dg/include/alibabacloud/dg/model/GetUserDatabasesResult.h new file mode 100644 index 000000000..3a1b618d1 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/GetUserDatabasesResult.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_DG_MODEL_GETUSERDATABASESRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_GETUSERDATABASESRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT GetUserDatabasesResult : public ServiceResult + { + public: + + + GetUserDatabasesResult(); + explicit GetUserDatabasesResult(const std::string &payload); + ~GetUserDatabasesResult(); + std::string getErrorMsg()const; + std::string getData()const; + int getCount()const; + std::string getCode()const; + std::string getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + int count_; + std::string code_; + std::string success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_GETUSERDATABASESRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/GetUserGatewayInstancesRequest.h b/dg/include/alibabacloud/dg/model/GetUserGatewayInstancesRequest.h new file mode 100644 index 000000000..a9ed851e6 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/GetUserGatewayInstancesRequest.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_DG_MODEL_GETUSERGATEWAYINSTANCESREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYINSTANCESREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT GetUserGatewayInstancesRequest : public RpcServiceRequest + { + + public: + GetUserGatewayInstancesRequest(); + ~GetUserGatewayInstancesRequest(); + + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYINSTANCESREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/GetUserGatewayInstancesResult.h b/dg/include/alibabacloud/dg/model/GetUserGatewayInstancesResult.h new file mode 100644 index 000000000..a87aff3ec --- /dev/null +++ b/dg/include/alibabacloud/dg/model/GetUserGatewayInstancesResult.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_DG_MODEL_GETUSERGATEWAYINSTANCESRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYINSTANCESRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT GetUserGatewayInstancesResult : public ServiceResult + { + public: + + + GetUserGatewayInstancesResult(); + explicit GetUserGatewayInstancesResult(const std::string &payload); + ~GetUserGatewayInstancesResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYINSTANCESRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/GetUserGatewaysRequest.h b/dg/include/alibabacloud/dg/model/GetUserGatewaysRequest.h new file mode 100644 index 000000000..8ae34cded --- /dev/null +++ b/dg/include/alibabacloud/dg/model/GetUserGatewaysRequest.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_DG_MODEL_GETUSERGATEWAYSREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYSREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT GetUserGatewaysRequest : public RpcServiceRequest + { + + public: + GetUserGatewaysRequest(); + ~GetUserGatewaysRequest(); + + std::string getSearchKey()const; + void setSearchKey(const std::string& searchKey); + int getPageNumber()const; + void setPageNumber(int pageNumber); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + int getPageSize()const; + void setPageSize(int pageSize); + + private: + std::string searchKey_; + int pageNumber_; + std::string regionId_; + int pageSize_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYSREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/GetUserGatewaysResult.h b/dg/include/alibabacloud/dg/model/GetUserGatewaysResult.h new file mode 100644 index 000000000..f12c14c5b --- /dev/null +++ b/dg/include/alibabacloud/dg/model/GetUserGatewaysResult.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_DG_MODEL_GETUSERGATEWAYSRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT GetUserGatewaysResult : public ServiceResult + { + public: + + + GetUserGatewaysResult(); + explicit GetUserGatewaysResult(const std::string &payload); + ~GetUserGatewaysResult(); + std::string getErrorMsg()const; + std::string getData()const; + int getCount()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + int count_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_GETUSERGATEWAYSRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ListDatabaseAccessPointRequest.h b/dg/include/alibabacloud/dg/model/ListDatabaseAccessPointRequest.h new file mode 100644 index 000000000..09e8aa4ef --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ListDatabaseAccessPointRequest.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_DG_MODEL_LISTDATABASEACCESSPOINTREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_LISTDATABASEACCESSPOINTREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ListDatabaseAccessPointRequest : public RpcServiceRequest + { + + public: + ListDatabaseAccessPointRequest(); + ~ListDatabaseAccessPointRequest(); + + std::string getSearchKey()const; + void setSearchKey(const std::string& searchKey); + std::string getPageNumber()const; + void setPageNumber(const std::string& pageNumber); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getPageSize()const; + void setPageSize(const std::string& pageSize); + std::string getHost()const; + void setHost(const std::string& host); + std::string getDbInstanceId()const; + void setDbInstanceId(const std::string& dbInstanceId); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + int getPort()const; + void setPort(int port); + std::string getVpcId()const; + void setVpcId(const std::string& vpcId); + + private: + std::string searchKey_; + std::string pageNumber_; + std::string regionId_; + std::string pageSize_; + std::string host_; + std::string dbInstanceId_; + std::string gatewayId_; + int port_; + std::string vpcId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_LISTDATABASEACCESSPOINTREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ListDatabaseAccessPointResult.h b/dg/include/alibabacloud/dg/model/ListDatabaseAccessPointResult.h new file mode 100644 index 000000000..0f71563ec --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ListDatabaseAccessPointResult.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_DG_MODEL_LISTDATABASEACCESSPOINTRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_LISTDATABASEACCESSPOINTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ListDatabaseAccessPointResult : public ServiceResult + { + public: + + + ListDatabaseAccessPointResult(); + explicit ListDatabaseAccessPointResult(const std::string &payload); + ~ListDatabaseAccessPointResult(); + std::string getErrorMsg()const; + std::string getData()const; + int getCount()const; + std::string getCode()const; + std::string getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + int count_; + std::string code_; + std::string success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_LISTDATABASEACCESSPOINTRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ModifyDatabaseRequest.h b/dg/include/alibabacloud/dg/model/ModifyDatabaseRequest.h new file mode 100644 index 000000000..3310e8816 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ModifyDatabaseRequest.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_DG_MODEL_MODIFYDATABASEREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_MODIFYDATABASEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ModifyDatabaseRequest : public RpcServiceRequest + { + + public: + ModifyDatabaseRequest(); + ~ModifyDatabaseRequest(); + + std::string getHost()const; + void setHost(const std::string& host); + std::string getDbUserName()const; + void setDbUserName(const std::string& dbUserName); + std::string getDbDescription()const; + void setDbDescription(const std::string& dbDescription); + std::string getInstanceId()const; + void setInstanceId(const std::string& instanceId); + std::string getDbName()const; + void setDbName(const std::string& dbName); + int getPort()const; + void setPort(int port); + std::string getDbPassword()const; + void setDbPassword(const std::string& dbPassword); + std::string getDbType()const; + void setDbType(const std::string& dbType); + + private: + std::string host_; + std::string dbUserName_; + std::string dbDescription_; + std::string instanceId_; + std::string dbName_; + int port_; + std::string dbPassword_; + std::string dbType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_MODIFYDATABASEREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ModifyDatabaseResult.h b/dg/include/alibabacloud/dg/model/ModifyDatabaseResult.h new file mode 100644 index 000000000..f321dc70a --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ModifyDatabaseResult.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_DG_MODEL_MODIFYDATABASERESULT_H_ +#define ALIBABACLOUD_DG_MODEL_MODIFYDATABASERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ModifyDatabaseResult : public ServiceResult + { + public: + + + ModifyDatabaseResult(); + explicit ModifyDatabaseResult(const std::string &payload); + ~ModifyDatabaseResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_MODIFYDATABASERESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ModifyGatewayRequest.h b/dg/include/alibabacloud/dg/model/ModifyGatewayRequest.h new file mode 100644 index 000000000..7a6a568eb --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ModifyGatewayRequest.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_DG_MODEL_MODIFYGATEWAYREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_MODIFYGATEWAYREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ModifyGatewayRequest : public RpcServiceRequest + { + + public: + ModifyGatewayRequest(); + ~ModifyGatewayRequest(); + + std::string getGatewayDesc()const; + void setGatewayDesc(const std::string& gatewayDesc); + std::string getGatewayName()const; + void setGatewayName(const std::string& gatewayName); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string gatewayDesc_; + std::string gatewayName_; + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_MODIFYGATEWAYREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/ModifyGatewayResult.h b/dg/include/alibabacloud/dg/model/ModifyGatewayResult.h new file mode 100644 index 000000000..1bc231edf --- /dev/null +++ b/dg/include/alibabacloud/dg/model/ModifyGatewayResult.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_DG_MODEL_MODIFYGATEWAYRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_MODIFYGATEWAYRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT ModifyGatewayResult : public ServiceResult + { + public: + + + ModifyGatewayResult(); + explicit ModifyGatewayResult(const std::string &payload); + ~ModifyGatewayResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_MODIFYGATEWAYRESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/RetryDatabaseRequest.h b/dg/include/alibabacloud/dg/model/RetryDatabaseRequest.h new file mode 100644 index 000000000..4989c35ef --- /dev/null +++ b/dg/include/alibabacloud/dg/model/RetryDatabaseRequest.h @@ -0,0 +1,75 @@ +/* + * 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_DG_MODEL_RETRYDATABASEREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_RETRYDATABASEREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT RetryDatabaseRequest : public RpcServiceRequest + { + + public: + RetryDatabaseRequest(); + ~RetryDatabaseRequest(); + + std::string getClientToken()const; + void setClientToken(const std::string& clientToken); + std::string getRegionId()const; + void setRegionId(const std::string& regionId); + std::string getHost()const; + void setHost(const std::string& host); + std::string getDbUserName()const; + void setDbUserName(const std::string& dbUserName); + std::string getDbDescription()const; + void setDbDescription(const std::string& dbDescription); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + std::string getDbName()const; + void setDbName(const std::string& dbName); + int getPort()const; + void setPort(int port); + std::string getDbPassword()const; + void setDbPassword(const std::string& dbPassword); + std::string getDbType()const; + void setDbType(const std::string& dbType); + + private: + std::string clientToken_; + std::string regionId_; + std::string host_; + std::string dbUserName_; + std::string dbDescription_; + std::string gatewayId_; + std::string dbName_; + int port_; + std::string dbPassword_; + std::string dbType_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_RETRYDATABASEREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/RetryDatabaseResult.h b/dg/include/alibabacloud/dg/model/RetryDatabaseResult.h new file mode 100644 index 000000000..3cf70c482 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/RetryDatabaseResult.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_DG_MODEL_RETRYDATABASERESULT_H_ +#define ALIBABACLOUD_DG_MODEL_RETRYDATABASERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT RetryDatabaseResult : public ServiceResult + { + public: + + + RetryDatabaseResult(); + explicit RetryDatabaseResult(const std::string &payload); + ~RetryDatabaseResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_RETRYDATABASERESULT_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/StopGatewayRequest.h b/dg/include/alibabacloud/dg/model/StopGatewayRequest.h new file mode 100644 index 000000000..f67a25c2f --- /dev/null +++ b/dg/include/alibabacloud/dg/model/StopGatewayRequest.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_DG_MODEL_STOPGATEWAYREQUEST_H_ +#define ALIBABACLOUD_DG_MODEL_STOPGATEWAYREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT StopGatewayRequest : public RpcServiceRequest + { + + public: + StopGatewayRequest(); + ~StopGatewayRequest(); + + std::string getGatewayInstanceId()const; + void setGatewayInstanceId(const std::string& gatewayInstanceId); + std::string getGatewayId()const; + void setGatewayId(const std::string& gatewayId); + + private: + std::string gatewayInstanceId_; + std::string gatewayId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_STOPGATEWAYREQUEST_H_ \ No newline at end of file diff --git a/dg/include/alibabacloud/dg/model/StopGatewayResult.h b/dg/include/alibabacloud/dg/model/StopGatewayResult.h new file mode 100644 index 000000000..7d3226435 --- /dev/null +++ b/dg/include/alibabacloud/dg/model/StopGatewayResult.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_DG_MODEL_STOPGATEWAYRESULT_H_ +#define ALIBABACLOUD_DG_MODEL_STOPGATEWAYRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Dg + { + namespace Model + { + class ALIBABACLOUD_DG_EXPORT StopGatewayResult : public ServiceResult + { + public: + + + StopGatewayResult(); + explicit StopGatewayResult(const std::string &payload); + ~StopGatewayResult(); + std::string getErrorMsg()const; + std::string getData()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + std::string errorMsg_; + std::string data_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_DG_MODEL_STOPGATEWAYRESULT_H_ \ No newline at end of file diff --git a/dg/src/DgClient.cc b/dg/src/DgClient.cc new file mode 100644 index 000000000..d4c909814 --- /dev/null +++ b/dg/src/DgClient.cc @@ -0,0 +1,809 @@ +/* + * 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::Dg; +using namespace AlibabaCloud::Dg::Model; + +namespace +{ + const std::string SERVICE_NAME = "dg"; +} + +DgClient::DgClient(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, "dg"); +} + +DgClient::DgClient(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, "dg"); +} + +DgClient::DgClient(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, "dg"); +} + +DgClient::~DgClient() +{} + +DgClient::AddDatabaseOutcome DgClient::addDatabase(const AddDatabaseRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return AddDatabaseOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return AddDatabaseOutcome(AddDatabaseResult(outcome.result())); + else + return AddDatabaseOutcome(outcome.error()); +} + +void DgClient::addDatabaseAsync(const AddDatabaseRequest& request, const AddDatabaseAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, addDatabase(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::AddDatabaseOutcomeCallable DgClient::addDatabaseCallable(const AddDatabaseRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->addDatabase(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::AddDatabaseListOutcome DgClient::addDatabaseList(const AddDatabaseListRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return AddDatabaseListOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return AddDatabaseListOutcome(AddDatabaseListResult(outcome.result())); + else + return AddDatabaseListOutcome(outcome.error()); +} + +void DgClient::addDatabaseListAsync(const AddDatabaseListRequest& request, const AddDatabaseListAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, addDatabaseList(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::AddDatabaseListOutcomeCallable DgClient::addDatabaseListCallable(const AddDatabaseListRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->addDatabaseList(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::ConnectDatabaseOutcome DgClient::connectDatabase(const ConnectDatabaseRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ConnectDatabaseOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ConnectDatabaseOutcome(ConnectDatabaseResult(outcome.result())); + else + return ConnectDatabaseOutcome(outcome.error()); +} + +void DgClient::connectDatabaseAsync(const ConnectDatabaseRequest& request, const ConnectDatabaseAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, connectDatabase(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::ConnectDatabaseOutcomeCallable DgClient::connectDatabaseCallable(const ConnectDatabaseRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->connectDatabase(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::CreateDatabaseAccessPointOutcome DgClient::createDatabaseAccessPoint(const CreateDatabaseAccessPointRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateDatabaseAccessPointOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateDatabaseAccessPointOutcome(CreateDatabaseAccessPointResult(outcome.result())); + else + return CreateDatabaseAccessPointOutcome(outcome.error()); +} + +void DgClient::createDatabaseAccessPointAsync(const CreateDatabaseAccessPointRequest& request, const CreateDatabaseAccessPointAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createDatabaseAccessPoint(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::CreateDatabaseAccessPointOutcomeCallable DgClient::createDatabaseAccessPointCallable(const CreateDatabaseAccessPointRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createDatabaseAccessPoint(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::CreateGatewayOutcome DgClient::createGateway(const CreateGatewayRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateGatewayOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateGatewayOutcome(CreateGatewayResult(outcome.result())); + else + return CreateGatewayOutcome(outcome.error()); +} + +void DgClient::createGatewayAsync(const CreateGatewayRequest& request, const CreateGatewayAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createGateway(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::CreateGatewayOutcomeCallable DgClient::createGatewayCallable(const CreateGatewayRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createGateway(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::CreateGatewayVerifyCodeOutcome DgClient::createGatewayVerifyCode(const CreateGatewayVerifyCodeRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateGatewayVerifyCodeOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateGatewayVerifyCodeOutcome(CreateGatewayVerifyCodeResult(outcome.result())); + else + return CreateGatewayVerifyCodeOutcome(outcome.error()); +} + +void DgClient::createGatewayVerifyCodeAsync(const CreateGatewayVerifyCodeRequest& request, const CreateGatewayVerifyCodeAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createGatewayVerifyCode(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::CreateGatewayVerifyCodeOutcomeCallable DgClient::createGatewayVerifyCodeCallable(const CreateGatewayVerifyCodeRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createGatewayVerifyCode(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::DeleteDatabaseOutcome DgClient::deleteDatabase(const DeleteDatabaseRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteDatabaseOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteDatabaseOutcome(DeleteDatabaseResult(outcome.result())); + else + return DeleteDatabaseOutcome(outcome.error()); +} + +void DgClient::deleteDatabaseAsync(const DeleteDatabaseRequest& request, const DeleteDatabaseAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteDatabase(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::DeleteDatabaseOutcomeCallable DgClient::deleteDatabaseCallable(const DeleteDatabaseRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteDatabase(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::DeleteDatabaseAccessPointOutcome DgClient::deleteDatabaseAccessPoint(const DeleteDatabaseAccessPointRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteDatabaseAccessPointOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteDatabaseAccessPointOutcome(DeleteDatabaseAccessPointResult(outcome.result())); + else + return DeleteDatabaseAccessPointOutcome(outcome.error()); +} + +void DgClient::deleteDatabaseAccessPointAsync(const DeleteDatabaseAccessPointRequest& request, const DeleteDatabaseAccessPointAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteDatabaseAccessPoint(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::DeleteDatabaseAccessPointOutcomeCallable DgClient::deleteDatabaseAccessPointCallable(const DeleteDatabaseAccessPointRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteDatabaseAccessPoint(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::DeleteGatewayOutcome DgClient::deleteGateway(const DeleteGatewayRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteGatewayOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteGatewayOutcome(DeleteGatewayResult(outcome.result())); + else + return DeleteGatewayOutcome(outcome.error()); +} + +void DgClient::deleteGatewayAsync(const DeleteGatewayRequest& request, const DeleteGatewayAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteGateway(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::DeleteGatewayOutcomeCallable DgClient::deleteGatewayCallable(const DeleteGatewayRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteGateway(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::DeleteGatewayInstanceOutcome DgClient::deleteGatewayInstance(const DeleteGatewayInstanceRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteGatewayInstanceOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteGatewayInstanceOutcome(DeleteGatewayInstanceResult(outcome.result())); + else + return DeleteGatewayInstanceOutcome(outcome.error()); +} + +void DgClient::deleteGatewayInstanceAsync(const DeleteGatewayInstanceRequest& request, const DeleteGatewayInstanceAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteGatewayInstance(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::DeleteGatewayInstanceOutcomeCallable DgClient::deleteGatewayInstanceCallable(const DeleteGatewayInstanceRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteGatewayInstance(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::DescribeRegionsOutcome DgClient::describeRegions(const DescribeRegionsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeRegionsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeRegionsOutcome(DescribeRegionsResult(outcome.result())); + else + return DescribeRegionsOutcome(outcome.error()); +} + +void DgClient::describeRegionsAsync(const DescribeRegionsRequest& request, const DescribeRegionsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeRegions(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::DescribeRegionsOutcomeCallable DgClient::describeRegionsCallable(const DescribeRegionsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeRegions(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::DownloadGatewayProgramOutcome DgClient::downloadGatewayProgram(const DownloadGatewayProgramRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DownloadGatewayProgramOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DownloadGatewayProgramOutcome(DownloadGatewayProgramResult(outcome.result())); + else + return DownloadGatewayProgramOutcome(outcome.error()); +} + +void DgClient::downloadGatewayProgramAsync(const DownloadGatewayProgramRequest& request, const DownloadGatewayProgramAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, downloadGatewayProgram(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::DownloadGatewayProgramOutcomeCallable DgClient::downloadGatewayProgramCallable(const DownloadGatewayProgramRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->downloadGatewayProgram(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::FindUserGatewayByIdOutcome DgClient::findUserGatewayById(const FindUserGatewayByIdRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return FindUserGatewayByIdOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return FindUserGatewayByIdOutcome(FindUserGatewayByIdResult(outcome.result())); + else + return FindUserGatewayByIdOutcome(outcome.error()); +} + +void DgClient::findUserGatewayByIdAsync(const FindUserGatewayByIdRequest& request, const FindUserGatewayByIdAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, findUserGatewayById(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::FindUserGatewayByIdOutcomeCallable DgClient::findUserGatewayByIdCallable(const FindUserGatewayByIdRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->findUserGatewayById(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::GetUserDatabasesOutcome DgClient::getUserDatabases(const GetUserDatabasesRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetUserDatabasesOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetUserDatabasesOutcome(GetUserDatabasesResult(outcome.result())); + else + return GetUserDatabasesOutcome(outcome.error()); +} + +void DgClient::getUserDatabasesAsync(const GetUserDatabasesRequest& request, const GetUserDatabasesAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getUserDatabases(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::GetUserDatabasesOutcomeCallable DgClient::getUserDatabasesCallable(const GetUserDatabasesRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getUserDatabases(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::GetUserGatewayInstancesOutcome DgClient::getUserGatewayInstances(const GetUserGatewayInstancesRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetUserGatewayInstancesOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetUserGatewayInstancesOutcome(GetUserGatewayInstancesResult(outcome.result())); + else + return GetUserGatewayInstancesOutcome(outcome.error()); +} + +void DgClient::getUserGatewayInstancesAsync(const GetUserGatewayInstancesRequest& request, const GetUserGatewayInstancesAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getUserGatewayInstances(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::GetUserGatewayInstancesOutcomeCallable DgClient::getUserGatewayInstancesCallable(const GetUserGatewayInstancesRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getUserGatewayInstances(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::GetUserGatewaysOutcome DgClient::getUserGateways(const GetUserGatewaysRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetUserGatewaysOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetUserGatewaysOutcome(GetUserGatewaysResult(outcome.result())); + else + return GetUserGatewaysOutcome(outcome.error()); +} + +void DgClient::getUserGatewaysAsync(const GetUserGatewaysRequest& request, const GetUserGatewaysAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getUserGateways(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::GetUserGatewaysOutcomeCallable DgClient::getUserGatewaysCallable(const GetUserGatewaysRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getUserGateways(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::ListDatabaseAccessPointOutcome DgClient::listDatabaseAccessPoint(const ListDatabaseAccessPointRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListDatabaseAccessPointOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListDatabaseAccessPointOutcome(ListDatabaseAccessPointResult(outcome.result())); + else + return ListDatabaseAccessPointOutcome(outcome.error()); +} + +void DgClient::listDatabaseAccessPointAsync(const ListDatabaseAccessPointRequest& request, const ListDatabaseAccessPointAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listDatabaseAccessPoint(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::ListDatabaseAccessPointOutcomeCallable DgClient::listDatabaseAccessPointCallable(const ListDatabaseAccessPointRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listDatabaseAccessPoint(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::ModifyDatabaseOutcome DgClient::modifyDatabase(const ModifyDatabaseRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ModifyDatabaseOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ModifyDatabaseOutcome(ModifyDatabaseResult(outcome.result())); + else + return ModifyDatabaseOutcome(outcome.error()); +} + +void DgClient::modifyDatabaseAsync(const ModifyDatabaseRequest& request, const ModifyDatabaseAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, modifyDatabase(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::ModifyDatabaseOutcomeCallable DgClient::modifyDatabaseCallable(const ModifyDatabaseRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->modifyDatabase(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::ModifyGatewayOutcome DgClient::modifyGateway(const ModifyGatewayRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ModifyGatewayOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ModifyGatewayOutcome(ModifyGatewayResult(outcome.result())); + else + return ModifyGatewayOutcome(outcome.error()); +} + +void DgClient::modifyGatewayAsync(const ModifyGatewayRequest& request, const ModifyGatewayAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, modifyGateway(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::ModifyGatewayOutcomeCallable DgClient::modifyGatewayCallable(const ModifyGatewayRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->modifyGateway(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::RetryDatabaseOutcome DgClient::retryDatabase(const RetryDatabaseRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return RetryDatabaseOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return RetryDatabaseOutcome(RetryDatabaseResult(outcome.result())); + else + return RetryDatabaseOutcome(outcome.error()); +} + +void DgClient::retryDatabaseAsync(const RetryDatabaseRequest& request, const RetryDatabaseAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, retryDatabase(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::RetryDatabaseOutcomeCallable DgClient::retryDatabaseCallable(const RetryDatabaseRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->retryDatabase(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +DgClient::StopGatewayOutcome DgClient::stopGateway(const StopGatewayRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return StopGatewayOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return StopGatewayOutcome(StopGatewayResult(outcome.result())); + else + return StopGatewayOutcome(outcome.error()); +} + +void DgClient::stopGatewayAsync(const StopGatewayRequest& request, const StopGatewayAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, stopGateway(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +DgClient::StopGatewayOutcomeCallable DgClient::stopGatewayCallable(const StopGatewayRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->stopGateway(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + diff --git a/dg/src/model/AddDatabaseListRequest.cc b/dg/src/model/AddDatabaseListRequest.cc new file mode 100644 index 000000000..d5f3e998a --- /dev/null +++ b/dg/src/model/AddDatabaseListRequest.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 + +using AlibabaCloud::Dg::Model::AddDatabaseListRequest; + +AddDatabaseListRequest::AddDatabaseListRequest() : + RpcServiceRequest("dg", "2019-03-27", "AddDatabaseList") +{ + setMethod(HttpRequest::Method::Post); +} + +AddDatabaseListRequest::~AddDatabaseListRequest() +{} + +std::string AddDatabaseListRequest::getDatabaseString()const +{ + return databaseString_; +} + +void AddDatabaseListRequest::setDatabaseString(const std::string& databaseString) +{ + databaseString_ = databaseString; + setBodyParameter("DatabaseString", databaseString); +} + +std::string AddDatabaseListRequest::getClientToken()const +{ + return clientToken_; +} + +void AddDatabaseListRequest::setClientToken(const std::string& clientToken) +{ + clientToken_ = clientToken; + setBodyParameter("ClientToken", clientToken); +} + diff --git a/dg/src/model/AddDatabaseListResult.cc b/dg/src/model/AddDatabaseListResult.cc new file mode 100644 index 000000000..5a332a68b --- /dev/null +++ b/dg/src/model/AddDatabaseListResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +AddDatabaseListResult::AddDatabaseListResult() : + ServiceResult() +{} + +AddDatabaseListResult::AddDatabaseListResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +AddDatabaseListResult::~AddDatabaseListResult() +{} + +void AddDatabaseListResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string AddDatabaseListResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string AddDatabaseListResult::getData()const +{ + return data_; +} + +std::string AddDatabaseListResult::getCode()const +{ + return code_; +} + +bool AddDatabaseListResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/AddDatabaseRequest.cc b/dg/src/model/AddDatabaseRequest.cc new file mode 100644 index 000000000..57d606135 --- /dev/null +++ b/dg/src/model/AddDatabaseRequest.cc @@ -0,0 +1,139 @@ +/* + * 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::Dg::Model::AddDatabaseRequest; + +AddDatabaseRequest::AddDatabaseRequest() : + RpcServiceRequest("dg", "2019-03-27", "AddDatabase") +{ + setMethod(HttpRequest::Method::Post); +} + +AddDatabaseRequest::~AddDatabaseRequest() +{} + +std::string AddDatabaseRequest::getClientToken()const +{ + return clientToken_; +} + +void AddDatabaseRequest::setClientToken(const std::string& clientToken) +{ + clientToken_ = clientToken; + setBodyParameter("ClientToken", clientToken); +} + +std::string AddDatabaseRequest::getRegionId()const +{ + return regionId_; +} + +void AddDatabaseRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string AddDatabaseRequest::getHost()const +{ + return host_; +} + +void AddDatabaseRequest::setHost(const std::string& host) +{ + host_ = host; + setBodyParameter("Host", host); +} + +std::string AddDatabaseRequest::getDbUserName()const +{ + return dbUserName_; +} + +void AddDatabaseRequest::setDbUserName(const std::string& dbUserName) +{ + dbUserName_ = dbUserName; + setBodyParameter("DbUserName", dbUserName); +} + +std::string AddDatabaseRequest::getDbDescription()const +{ + return dbDescription_; +} + +void AddDatabaseRequest::setDbDescription(const std::string& dbDescription) +{ + dbDescription_ = dbDescription; + setBodyParameter("DbDescription", dbDescription); +} + +std::string AddDatabaseRequest::getGatewayId()const +{ + return gatewayId_; +} + +void AddDatabaseRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + +std::string AddDatabaseRequest::getDbName()const +{ + return dbName_; +} + +void AddDatabaseRequest::setDbName(const std::string& dbName) +{ + dbName_ = dbName; + setBodyParameter("DbName", dbName); +} + +int AddDatabaseRequest::getPort()const +{ + return port_; +} + +void AddDatabaseRequest::setPort(int port) +{ + port_ = port; + setBodyParameter("Port", std::to_string(port)); +} + +std::string AddDatabaseRequest::getDbPassword()const +{ + return dbPassword_; +} + +void AddDatabaseRequest::setDbPassword(const std::string& dbPassword) +{ + dbPassword_ = dbPassword; + setBodyParameter("DbPassword", dbPassword); +} + +std::string AddDatabaseRequest::getDbType()const +{ + return dbType_; +} + +void AddDatabaseRequest::setDbType(const std::string& dbType) +{ + dbType_ = dbType; + setBodyParameter("DbType", dbType); +} + diff --git a/dg/src/model/AddDatabaseResult.cc b/dg/src/model/AddDatabaseResult.cc new file mode 100644 index 000000000..05b92153c --- /dev/null +++ b/dg/src/model/AddDatabaseResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +AddDatabaseResult::AddDatabaseResult() : + ServiceResult() +{} + +AddDatabaseResult::AddDatabaseResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +AddDatabaseResult::~AddDatabaseResult() +{} + +void AddDatabaseResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string AddDatabaseResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string AddDatabaseResult::getData()const +{ + return data_; +} + +std::string AddDatabaseResult::getCode()const +{ + return code_; +} + +bool AddDatabaseResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/ConnectDatabaseRequest.cc b/dg/src/model/ConnectDatabaseRequest.cc new file mode 100644 index 000000000..75dcd8568 --- /dev/null +++ b/dg/src/model/ConnectDatabaseRequest.cc @@ -0,0 +1,106 @@ +/* + * 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::Dg::Model::ConnectDatabaseRequest; + +ConnectDatabaseRequest::ConnectDatabaseRequest() : + RpcServiceRequest("dg", "2019-03-27", "ConnectDatabase") +{ + setMethod(HttpRequest::Method::Post); +} + +ConnectDatabaseRequest::~ConnectDatabaseRequest() +{} + +std::string ConnectDatabaseRequest::getDbName()const +{ + return dbName_; +} + +void ConnectDatabaseRequest::setDbName(const std::string& dbName) +{ + dbName_ = dbName; + setBodyParameter("DbName", dbName); +} + +int ConnectDatabaseRequest::getPort()const +{ + return port_; +} + +void ConnectDatabaseRequest::setPort(int port) +{ + port_ = port; + setBodyParameter("Port", std::to_string(port)); +} + +std::string ConnectDatabaseRequest::getDbPassword()const +{ + return dbPassword_; +} + +void ConnectDatabaseRequest::setDbPassword(const std::string& dbPassword) +{ + dbPassword_ = dbPassword; + setBodyParameter("DbPassword", dbPassword); +} + +std::string ConnectDatabaseRequest::getHost()const +{ + return host_; +} + +void ConnectDatabaseRequest::setHost(const std::string& host) +{ + host_ = host; + setBodyParameter("Host", host); +} + +std::string ConnectDatabaseRequest::getDbType()const +{ + return dbType_; +} + +void ConnectDatabaseRequest::setDbType(const std::string& dbType) +{ + dbType_ = dbType; + setBodyParameter("DbType", dbType); +} + +std::string ConnectDatabaseRequest::getDbUserName()const +{ + return dbUserName_; +} + +void ConnectDatabaseRequest::setDbUserName(const std::string& dbUserName) +{ + dbUserName_ = dbUserName; + setBodyParameter("DbUserName", dbUserName); +} + +std::string ConnectDatabaseRequest::getGatewayId()const +{ + return gatewayId_; +} + +void ConnectDatabaseRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/ConnectDatabaseResult.cc b/dg/src/model/ConnectDatabaseResult.cc new file mode 100644 index 000000000..c2f6f3ad0 --- /dev/null +++ b/dg/src/model/ConnectDatabaseResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +ConnectDatabaseResult::ConnectDatabaseResult() : + ServiceResult() +{} + +ConnectDatabaseResult::ConnectDatabaseResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ConnectDatabaseResult::~ConnectDatabaseResult() +{} + +void ConnectDatabaseResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string ConnectDatabaseResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string ConnectDatabaseResult::getData()const +{ + return data_; +} + +std::string ConnectDatabaseResult::getCode()const +{ + return code_; +} + +bool ConnectDatabaseResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/CreateDatabaseAccessPointRequest.cc b/dg/src/model/CreateDatabaseAccessPointRequest.cc new file mode 100644 index 000000000..49401c5dd --- /dev/null +++ b/dg/src/model/CreateDatabaseAccessPointRequest.cc @@ -0,0 +1,106 @@ +/* + * 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::Dg::Model::CreateDatabaseAccessPointRequest; + +CreateDatabaseAccessPointRequest::CreateDatabaseAccessPointRequest() : + RpcServiceRequest("dg", "2019-03-27", "CreateDatabaseAccessPoint") +{ + setMethod(HttpRequest::Method::Post); +} + +CreateDatabaseAccessPointRequest::~CreateDatabaseAccessPointRequest() +{} + +std::string CreateDatabaseAccessPointRequest::getVpcAZone()const +{ + return vpcAZone_; +} + +void CreateDatabaseAccessPointRequest::setVpcAZone(const std::string& vpcAZone) +{ + vpcAZone_ = vpcAZone; + setBodyParameter("VpcAZone", vpcAZone); +} + +std::string CreateDatabaseAccessPointRequest::getClientToken()const +{ + return clientToken_; +} + +void CreateDatabaseAccessPointRequest::setClientToken(const std::string& clientToken) +{ + clientToken_ = clientToken; + setBodyParameter("ClientToken", clientToken); +} + +std::string CreateDatabaseAccessPointRequest::getRegionId()const +{ + return regionId_; +} + +void CreateDatabaseAccessPointRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string CreateDatabaseAccessPointRequest::getDbInstanceId()const +{ + return dbInstanceId_; +} + +void CreateDatabaseAccessPointRequest::setDbInstanceId(const std::string& dbInstanceId) +{ + dbInstanceId_ = dbInstanceId; + setBodyParameter("DbInstanceId", dbInstanceId); +} + +std::string CreateDatabaseAccessPointRequest::getVpcRegionId()const +{ + return vpcRegionId_; +} + +void CreateDatabaseAccessPointRequest::setVpcRegionId(const std::string& vpcRegionId) +{ + vpcRegionId_ = vpcRegionId; + setBodyParameter("VpcRegionId", vpcRegionId); +} + +std::string CreateDatabaseAccessPointRequest::getVSwitchId()const +{ + return vSwitchId_; +} + +void CreateDatabaseAccessPointRequest::setVSwitchId(const std::string& vSwitchId) +{ + vSwitchId_ = vSwitchId; + setBodyParameter("VSwitchId", vSwitchId); +} + +std::string CreateDatabaseAccessPointRequest::getVpcId()const +{ + return vpcId_; +} + +void CreateDatabaseAccessPointRequest::setVpcId(const std::string& vpcId) +{ + vpcId_ = vpcId; + setBodyParameter("VpcId", vpcId); +} + diff --git a/dg/src/model/CreateDatabaseAccessPointResult.cc b/dg/src/model/CreateDatabaseAccessPointResult.cc new file mode 100644 index 000000000..2a3c81f55 --- /dev/null +++ b/dg/src/model/CreateDatabaseAccessPointResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +CreateDatabaseAccessPointResult::CreateDatabaseAccessPointResult() : + ServiceResult() +{} + +CreateDatabaseAccessPointResult::CreateDatabaseAccessPointResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateDatabaseAccessPointResult::~CreateDatabaseAccessPointResult() +{} + +void CreateDatabaseAccessPointResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string CreateDatabaseAccessPointResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string CreateDatabaseAccessPointResult::getData()const +{ + return data_; +} + +std::string CreateDatabaseAccessPointResult::getCode()const +{ + return code_; +} + +bool CreateDatabaseAccessPointResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/CreateGatewayRequest.cc b/dg/src/model/CreateGatewayRequest.cc new file mode 100644 index 000000000..86b5b7ee8 --- /dev/null +++ b/dg/src/model/CreateGatewayRequest.cc @@ -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. + */ + +#include + +using AlibabaCloud::Dg::Model::CreateGatewayRequest; + +CreateGatewayRequest::CreateGatewayRequest() : + RpcServiceRequest("dg", "2019-03-27", "CreateGateway") +{ + setMethod(HttpRequest::Method::Post); +} + +CreateGatewayRequest::~CreateGatewayRequest() +{} + +std::string CreateGatewayRequest::getGatewayDesc()const +{ + return gatewayDesc_; +} + +void CreateGatewayRequest::setGatewayDesc(const std::string& gatewayDesc) +{ + gatewayDesc_ = gatewayDesc; + setBodyParameter("GatewayDesc", gatewayDesc); +} + +std::string CreateGatewayRequest::getRegionId()const +{ + return regionId_; +} + +void CreateGatewayRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string CreateGatewayRequest::getGatewayName()const +{ + return gatewayName_; +} + +void CreateGatewayRequest::setGatewayName(const std::string& gatewayName) +{ + gatewayName_ = gatewayName; + setBodyParameter("GatewayName", gatewayName); +} + diff --git a/dg/src/model/CreateGatewayResult.cc b/dg/src/model/CreateGatewayResult.cc new file mode 100644 index 000000000..4cc44c45a --- /dev/null +++ b/dg/src/model/CreateGatewayResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +CreateGatewayResult::CreateGatewayResult() : + ServiceResult() +{} + +CreateGatewayResult::CreateGatewayResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateGatewayResult::~CreateGatewayResult() +{} + +void CreateGatewayResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string CreateGatewayResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string CreateGatewayResult::getData()const +{ + return data_; +} + +std::string CreateGatewayResult::getCode()const +{ + return code_; +} + +bool CreateGatewayResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/CreateGatewayVerifyCodeRequest.cc b/dg/src/model/CreateGatewayVerifyCodeRequest.cc new file mode 100644 index 000000000..7f09194d6 --- /dev/null +++ b/dg/src/model/CreateGatewayVerifyCodeRequest.cc @@ -0,0 +1,40 @@ +/* + * 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::Dg::Model::CreateGatewayVerifyCodeRequest; + +CreateGatewayVerifyCodeRequest::CreateGatewayVerifyCodeRequest() : + RpcServiceRequest("dg", "2019-03-27", "CreateGatewayVerifyCode") +{ + setMethod(HttpRequest::Method::Post); +} + +CreateGatewayVerifyCodeRequest::~CreateGatewayVerifyCodeRequest() +{} + +std::string CreateGatewayVerifyCodeRequest::getGatewayId()const +{ + return gatewayId_; +} + +void CreateGatewayVerifyCodeRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/CreateGatewayVerifyCodeResult.cc b/dg/src/model/CreateGatewayVerifyCodeResult.cc new file mode 100644 index 000000000..24ca931ea --- /dev/null +++ b/dg/src/model/CreateGatewayVerifyCodeResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +CreateGatewayVerifyCodeResult::CreateGatewayVerifyCodeResult() : + ServiceResult() +{} + +CreateGatewayVerifyCodeResult::CreateGatewayVerifyCodeResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateGatewayVerifyCodeResult::~CreateGatewayVerifyCodeResult() +{} + +void CreateGatewayVerifyCodeResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string CreateGatewayVerifyCodeResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string CreateGatewayVerifyCodeResult::getData()const +{ + return data_; +} + +std::string CreateGatewayVerifyCodeResult::getCode()const +{ + return code_; +} + +bool CreateGatewayVerifyCodeResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/DeleteDatabaseAccessPointRequest.cc b/dg/src/model/DeleteDatabaseAccessPointRequest.cc new file mode 100644 index 000000000..8bc65b582 --- /dev/null +++ b/dg/src/model/DeleteDatabaseAccessPointRequest.cc @@ -0,0 +1,95 @@ +/* + * 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::Dg::Model::DeleteDatabaseAccessPointRequest; + +DeleteDatabaseAccessPointRequest::DeleteDatabaseAccessPointRequest() : + RpcServiceRequest("dg", "2019-03-27", "DeleteDatabaseAccessPoint") +{ + setMethod(HttpRequest::Method::Post); +} + +DeleteDatabaseAccessPointRequest::~DeleteDatabaseAccessPointRequest() +{} + +std::string DeleteDatabaseAccessPointRequest::getVpcAZone()const +{ + return vpcAZone_; +} + +void DeleteDatabaseAccessPointRequest::setVpcAZone(const std::string& vpcAZone) +{ + vpcAZone_ = vpcAZone; + setBodyParameter("VpcAZone", vpcAZone); +} + +std::string DeleteDatabaseAccessPointRequest::getVpcRegionId()const +{ + return vpcRegionId_; +} + +void DeleteDatabaseAccessPointRequest::setVpcRegionId(const std::string& vpcRegionId) +{ + vpcRegionId_ = vpcRegionId; + setBodyParameter("VpcRegionId", vpcRegionId); +} + +std::string DeleteDatabaseAccessPointRequest::getVSwitchId()const +{ + return vSwitchId_; +} + +void DeleteDatabaseAccessPointRequest::setVSwitchId(const std::string& vSwitchId) +{ + vSwitchId_ = vSwitchId; + setBodyParameter("VSwitchId", vSwitchId); +} + +std::string DeleteDatabaseAccessPointRequest::getRegionId()const +{ + return regionId_; +} + +void DeleteDatabaseAccessPointRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string DeleteDatabaseAccessPointRequest::getVpcId()const +{ + return vpcId_; +} + +void DeleteDatabaseAccessPointRequest::setVpcId(const std::string& vpcId) +{ + vpcId_ = vpcId; + setBodyParameter("VpcId", vpcId); +} + +std::string DeleteDatabaseAccessPointRequest::getDbInstanceId()const +{ + return dbInstanceId_; +} + +void DeleteDatabaseAccessPointRequest::setDbInstanceId(const std::string& dbInstanceId) +{ + dbInstanceId_ = dbInstanceId; + setBodyParameter("DbInstanceId", dbInstanceId); +} + diff --git a/dg/src/model/DeleteDatabaseAccessPointResult.cc b/dg/src/model/DeleteDatabaseAccessPointResult.cc new file mode 100644 index 000000000..8dfd48173 --- /dev/null +++ b/dg/src/model/DeleteDatabaseAccessPointResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +DeleteDatabaseAccessPointResult::DeleteDatabaseAccessPointResult() : + ServiceResult() +{} + +DeleteDatabaseAccessPointResult::DeleteDatabaseAccessPointResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteDatabaseAccessPointResult::~DeleteDatabaseAccessPointResult() +{} + +void DeleteDatabaseAccessPointResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string DeleteDatabaseAccessPointResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string DeleteDatabaseAccessPointResult::getData()const +{ + return data_; +} + +std::string DeleteDatabaseAccessPointResult::getCode()const +{ + return code_; +} + +bool DeleteDatabaseAccessPointResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/DeleteDatabaseRequest.cc b/dg/src/model/DeleteDatabaseRequest.cc new file mode 100644 index 000000000..a63e000f0 --- /dev/null +++ b/dg/src/model/DeleteDatabaseRequest.cc @@ -0,0 +1,40 @@ +/* + * 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::Dg::Model::DeleteDatabaseRequest; + +DeleteDatabaseRequest::DeleteDatabaseRequest() : + RpcServiceRequest("dg", "2019-03-27", "DeleteDatabase") +{ + setMethod(HttpRequest::Method::Post); +} + +DeleteDatabaseRequest::~DeleteDatabaseRequest() +{} + +std::string DeleteDatabaseRequest::getInstanceId()const +{ + return instanceId_; +} + +void DeleteDatabaseRequest::setInstanceId(const std::string& instanceId) +{ + instanceId_ = instanceId; + setBodyParameter("InstanceId", instanceId); +} + diff --git a/dg/src/model/DeleteDatabaseResult.cc b/dg/src/model/DeleteDatabaseResult.cc new file mode 100644 index 000000000..e439726fa --- /dev/null +++ b/dg/src/model/DeleteDatabaseResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +DeleteDatabaseResult::DeleteDatabaseResult() : + ServiceResult() +{} + +DeleteDatabaseResult::DeleteDatabaseResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteDatabaseResult::~DeleteDatabaseResult() +{} + +void DeleteDatabaseResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string DeleteDatabaseResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string DeleteDatabaseResult::getData()const +{ + return data_; +} + +std::string DeleteDatabaseResult::getCode()const +{ + return code_; +} + +bool DeleteDatabaseResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/DeleteGatewayInstanceRequest.cc b/dg/src/model/DeleteGatewayInstanceRequest.cc new file mode 100644 index 000000000..5a810636f --- /dev/null +++ b/dg/src/model/DeleteGatewayInstanceRequest.cc @@ -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. + */ + +#include + +using AlibabaCloud::Dg::Model::DeleteGatewayInstanceRequest; + +DeleteGatewayInstanceRequest::DeleteGatewayInstanceRequest() : + RpcServiceRequest("dg", "2019-03-27", "DeleteGatewayInstance") +{ + setMethod(HttpRequest::Method::Post); +} + +DeleteGatewayInstanceRequest::~DeleteGatewayInstanceRequest() +{} + +std::string DeleteGatewayInstanceRequest::getGatewayInstanceId()const +{ + return gatewayInstanceId_; +} + +void DeleteGatewayInstanceRequest::setGatewayInstanceId(const std::string& gatewayInstanceId) +{ + gatewayInstanceId_ = gatewayInstanceId; + setBodyParameter("GatewayInstanceId", gatewayInstanceId); +} + +std::string DeleteGatewayInstanceRequest::getRegionId()const +{ + return regionId_; +} + +void DeleteGatewayInstanceRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string DeleteGatewayInstanceRequest::getGatewayId()const +{ + return gatewayId_; +} + +void DeleteGatewayInstanceRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/DeleteGatewayInstanceResult.cc b/dg/src/model/DeleteGatewayInstanceResult.cc new file mode 100644 index 000000000..f81318c2a --- /dev/null +++ b/dg/src/model/DeleteGatewayInstanceResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +DeleteGatewayInstanceResult::DeleteGatewayInstanceResult() : + ServiceResult() +{} + +DeleteGatewayInstanceResult::DeleteGatewayInstanceResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteGatewayInstanceResult::~DeleteGatewayInstanceResult() +{} + +void DeleteGatewayInstanceResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string DeleteGatewayInstanceResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string DeleteGatewayInstanceResult::getData()const +{ + return data_; +} + +std::string DeleteGatewayInstanceResult::getCode()const +{ + return code_; +} + +bool DeleteGatewayInstanceResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/DeleteGatewayRequest.cc b/dg/src/model/DeleteGatewayRequest.cc new file mode 100644 index 000000000..020d92fa0 --- /dev/null +++ b/dg/src/model/DeleteGatewayRequest.cc @@ -0,0 +1,40 @@ +/* + * 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::Dg::Model::DeleteGatewayRequest; + +DeleteGatewayRequest::DeleteGatewayRequest() : + RpcServiceRequest("dg", "2019-03-27", "DeleteGateway") +{ + setMethod(HttpRequest::Method::Post); +} + +DeleteGatewayRequest::~DeleteGatewayRequest() +{} + +std::string DeleteGatewayRequest::getGatewayId()const +{ + return gatewayId_; +} + +void DeleteGatewayRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/DeleteGatewayResult.cc b/dg/src/model/DeleteGatewayResult.cc new file mode 100644 index 000000000..2593bbd48 --- /dev/null +++ b/dg/src/model/DeleteGatewayResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +DeleteGatewayResult::DeleteGatewayResult() : + ServiceResult() +{} + +DeleteGatewayResult::DeleteGatewayResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteGatewayResult::~DeleteGatewayResult() +{} + +void DeleteGatewayResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string DeleteGatewayResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string DeleteGatewayResult::getData()const +{ + return data_; +} + +std::string DeleteGatewayResult::getCode()const +{ + return code_; +} + +bool DeleteGatewayResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/DescribeRegionsRequest.cc b/dg/src/model/DescribeRegionsRequest.cc new file mode 100644 index 000000000..11e934dde --- /dev/null +++ b/dg/src/model/DescribeRegionsRequest.cc @@ -0,0 +1,40 @@ +/* + * 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::Dg::Model::DescribeRegionsRequest; + +DescribeRegionsRequest::DescribeRegionsRequest() : + RpcServiceRequest("dg", "2019-03-27", "DescribeRegions") +{ + setMethod(HttpRequest::Method::Post); +} + +DescribeRegionsRequest::~DescribeRegionsRequest() +{} + +std::string DescribeRegionsRequest::getRegionId()const +{ + return regionId_; +} + +void DescribeRegionsRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + diff --git a/dg/src/model/DescribeRegionsResult.cc b/dg/src/model/DescribeRegionsResult.cc new file mode 100644 index 000000000..d0c823f1b --- /dev/null +++ b/dg/src/model/DescribeRegionsResult.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::Dg; +using namespace AlibabaCloud::Dg::Model; + +DescribeRegionsResult::DescribeRegionsResult() : + ServiceResult() +{} + +DescribeRegionsResult::DescribeRegionsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeRegionsResult::~DescribeRegionsResult() +{} + +void DescribeRegionsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allRegionsNode = value["Regions"]["Region"]; + for (auto valueRegionsRegion : allRegionsNode) + { + Region regionsObject; + if(!valueRegionsRegion["RegionId"].isNull()) + regionsObject.regionId = valueRegionsRegion["RegionId"].asString(); + if(!valueRegionsRegion["LocalName"].isNull()) + regionsObject.localName = valueRegionsRegion["LocalName"].asString(); + if(!valueRegionsRegion["RegionEndpoint"].isNull()) + regionsObject.regionEndpoint = valueRegionsRegion["RegionEndpoint"].asString(); + regions_.push_back(regionsObject); + } + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + +} + +std::string DescribeRegionsResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::vector DescribeRegionsResult::getRegions()const +{ + return regions_; +} + +std::string DescribeRegionsResult::getCode()const +{ + return code_; +} + +bool DescribeRegionsResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/DownloadGatewayProgramRequest.cc b/dg/src/model/DownloadGatewayProgramRequest.cc new file mode 100644 index 000000000..280a7749b --- /dev/null +++ b/dg/src/model/DownloadGatewayProgramRequest.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 + +using AlibabaCloud::Dg::Model::DownloadGatewayProgramRequest; + +DownloadGatewayProgramRequest::DownloadGatewayProgramRequest() : + RpcServiceRequest("dg", "2019-03-27", "DownloadGatewayProgram") +{ + setMethod(HttpRequest::Method::Post); +} + +DownloadGatewayProgramRequest::~DownloadGatewayProgramRequest() +{} + +std::string DownloadGatewayProgramRequest::getUserOS()const +{ + return userOS_; +} + +void DownloadGatewayProgramRequest::setUserOS(const std::string& userOS) +{ + userOS_ = userOS; + setBodyParameter("UserOS", userOS); +} + +std::string DownloadGatewayProgramRequest::getDgVersion()const +{ + return dgVersion_; +} + +void DownloadGatewayProgramRequest::setDgVersion(const std::string& dgVersion) +{ + dgVersion_ = dgVersion; + setBodyParameter("DgVersion", dgVersion); +} + diff --git a/dg/src/model/DownloadGatewayProgramResult.cc b/dg/src/model/DownloadGatewayProgramResult.cc new file mode 100644 index 000000000..9436eb380 --- /dev/null +++ b/dg/src/model/DownloadGatewayProgramResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +DownloadGatewayProgramResult::DownloadGatewayProgramResult() : + ServiceResult() +{} + +DownloadGatewayProgramResult::DownloadGatewayProgramResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DownloadGatewayProgramResult::~DownloadGatewayProgramResult() +{} + +void DownloadGatewayProgramResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string DownloadGatewayProgramResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string DownloadGatewayProgramResult::getData()const +{ + return data_; +} + +std::string DownloadGatewayProgramResult::getCode()const +{ + return code_; +} + +bool DownloadGatewayProgramResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/FindUserGatewayByIdRequest.cc b/dg/src/model/FindUserGatewayByIdRequest.cc new file mode 100644 index 000000000..a4ab90c3b --- /dev/null +++ b/dg/src/model/FindUserGatewayByIdRequest.cc @@ -0,0 +1,40 @@ +/* + * 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::Dg::Model::FindUserGatewayByIdRequest; + +FindUserGatewayByIdRequest::FindUserGatewayByIdRequest() : + RpcServiceRequest("dg", "2019-03-27", "FindUserGatewayById") +{ + setMethod(HttpRequest::Method::Post); +} + +FindUserGatewayByIdRequest::~FindUserGatewayByIdRequest() +{} + +std::string FindUserGatewayByIdRequest::getGatewayId()const +{ + return gatewayId_; +} + +void FindUserGatewayByIdRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/FindUserGatewayByIdResult.cc b/dg/src/model/FindUserGatewayByIdResult.cc new file mode 100644 index 000000000..74a24fcf9 --- /dev/null +++ b/dg/src/model/FindUserGatewayByIdResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +FindUserGatewayByIdResult::FindUserGatewayByIdResult() : + ServiceResult() +{} + +FindUserGatewayByIdResult::FindUserGatewayByIdResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +FindUserGatewayByIdResult::~FindUserGatewayByIdResult() +{} + +void FindUserGatewayByIdResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string FindUserGatewayByIdResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string FindUserGatewayByIdResult::getData()const +{ + return data_; +} + +std::string FindUserGatewayByIdResult::getCode()const +{ + return code_; +} + +bool FindUserGatewayByIdResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/GetUserDatabasesRequest.cc b/dg/src/model/GetUserDatabasesRequest.cc new file mode 100644 index 000000000..859424b63 --- /dev/null +++ b/dg/src/model/GetUserDatabasesRequest.cc @@ -0,0 +1,128 @@ +/* + * 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::Dg::Model::GetUserDatabasesRequest; + +GetUserDatabasesRequest::GetUserDatabasesRequest() : + RpcServiceRequest("dg", "2019-03-27", "GetUserDatabases") +{ + setMethod(HttpRequest::Method::Post); +} + +GetUserDatabasesRequest::~GetUserDatabasesRequest() +{} + +std::string GetUserDatabasesRequest::getSearchKey()const +{ + return searchKey_; +} + +void GetUserDatabasesRequest::setSearchKey(const std::string& searchKey) +{ + searchKey_ = searchKey; + setBodyParameter("SearchKey", searchKey); +} + +std::string GetUserDatabasesRequest::getPageNumber()const +{ + return pageNumber_; +} + +void GetUserDatabasesRequest::setPageNumber(const std::string& pageNumber) +{ + pageNumber_ = pageNumber; + setBodyParameter("PageNumber", pageNumber); +} + +std::string GetUserDatabasesRequest::getRegionId()const +{ + return regionId_; +} + +void GetUserDatabasesRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string GetUserDatabasesRequest::getPageSize()const +{ + return pageSize_; +} + +void GetUserDatabasesRequest::setPageSize(const std::string& pageSize) +{ + pageSize_ = pageSize; + setBodyParameter("PageSize", pageSize); +} + +std::string GetUserDatabasesRequest::getHost()const +{ + return host_; +} + +void GetUserDatabasesRequest::setHost(const std::string& host) +{ + host_ = host; + setBodyParameter("Host", host); +} + +std::string GetUserDatabasesRequest::getGatewayId()const +{ + return gatewayId_; +} + +void GetUserDatabasesRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + +std::string GetUserDatabasesRequest::getInstanceId()const +{ + return instanceId_; +} + +void GetUserDatabasesRequest::setInstanceId(const std::string& instanceId) +{ + instanceId_ = instanceId; + setBodyParameter("InstanceId", instanceId); +} + +int GetUserDatabasesRequest::getPort()const +{ + return port_; +} + +void GetUserDatabasesRequest::setPort(int port) +{ + port_ = port; + setBodyParameter("Port", std::to_string(port)); +} + +std::string GetUserDatabasesRequest::getDbType()const +{ + return dbType_; +} + +void GetUserDatabasesRequest::setDbType(const std::string& dbType) +{ + dbType_ = dbType; + setBodyParameter("DbType", dbType); +} + diff --git a/dg/src/model/GetUserDatabasesResult.cc b/dg/src/model/GetUserDatabasesResult.cc new file mode 100644 index 000000000..e52ace201 --- /dev/null +++ b/dg/src/model/GetUserDatabasesResult.cc @@ -0,0 +1,79 @@ +/* + * 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::Dg; +using namespace AlibabaCloud::Dg::Model; + +GetUserDatabasesResult::GetUserDatabasesResult() : + ServiceResult() +{} + +GetUserDatabasesResult::GetUserDatabasesResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetUserDatabasesResult::~GetUserDatabasesResult() +{} + +void GetUserDatabasesResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString(); + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + if(!value["Count"].isNull()) + count_ = std::stoi(value["Count"].asString()); + +} + +std::string GetUserDatabasesResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string GetUserDatabasesResult::getData()const +{ + return data_; +} + +int GetUserDatabasesResult::getCount()const +{ + return count_; +} + +std::string GetUserDatabasesResult::getCode()const +{ + return code_; +} + +std::string GetUserDatabasesResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/GetUserGatewayInstancesRequest.cc b/dg/src/model/GetUserGatewayInstancesRequest.cc new file mode 100644 index 000000000..e0839fc7b --- /dev/null +++ b/dg/src/model/GetUserGatewayInstancesRequest.cc @@ -0,0 +1,40 @@ +/* + * 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::Dg::Model::GetUserGatewayInstancesRequest; + +GetUserGatewayInstancesRequest::GetUserGatewayInstancesRequest() : + RpcServiceRequest("dg", "2019-03-27", "GetUserGatewayInstances") +{ + setMethod(HttpRequest::Method::Post); +} + +GetUserGatewayInstancesRequest::~GetUserGatewayInstancesRequest() +{} + +std::string GetUserGatewayInstancesRequest::getGatewayId()const +{ + return gatewayId_; +} + +void GetUserGatewayInstancesRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/GetUserGatewayInstancesResult.cc b/dg/src/model/GetUserGatewayInstancesResult.cc new file mode 100644 index 000000000..479ee608a --- /dev/null +++ b/dg/src/model/GetUserGatewayInstancesResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +GetUserGatewayInstancesResult::GetUserGatewayInstancesResult() : + ServiceResult() +{} + +GetUserGatewayInstancesResult::GetUserGatewayInstancesResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetUserGatewayInstancesResult::~GetUserGatewayInstancesResult() +{} + +void GetUserGatewayInstancesResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string GetUserGatewayInstancesResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string GetUserGatewayInstancesResult::getData()const +{ + return data_; +} + +std::string GetUserGatewayInstancesResult::getCode()const +{ + return code_; +} + +bool GetUserGatewayInstancesResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/GetUserGatewaysRequest.cc b/dg/src/model/GetUserGatewaysRequest.cc new file mode 100644 index 000000000..e2be47530 --- /dev/null +++ b/dg/src/model/GetUserGatewaysRequest.cc @@ -0,0 +1,73 @@ +/* + * 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::Dg::Model::GetUserGatewaysRequest; + +GetUserGatewaysRequest::GetUserGatewaysRequest() : + RpcServiceRequest("dg", "2019-03-27", "GetUserGateways") +{ + setMethod(HttpRequest::Method::Post); +} + +GetUserGatewaysRequest::~GetUserGatewaysRequest() +{} + +std::string GetUserGatewaysRequest::getSearchKey()const +{ + return searchKey_; +} + +void GetUserGatewaysRequest::setSearchKey(const std::string& searchKey) +{ + searchKey_ = searchKey; + setBodyParameter("SearchKey", searchKey); +} + +int GetUserGatewaysRequest::getPageNumber()const +{ + return pageNumber_; +} + +void GetUserGatewaysRequest::setPageNumber(int pageNumber) +{ + pageNumber_ = pageNumber; + setBodyParameter("PageNumber", std::to_string(pageNumber)); +} + +std::string GetUserGatewaysRequest::getRegionId()const +{ + return regionId_; +} + +void GetUserGatewaysRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +int GetUserGatewaysRequest::getPageSize()const +{ + return pageSize_; +} + +void GetUserGatewaysRequest::setPageSize(int pageSize) +{ + pageSize_ = pageSize; + setBodyParameter("PageSize", std::to_string(pageSize)); +} + diff --git a/dg/src/model/GetUserGatewaysResult.cc b/dg/src/model/GetUserGatewaysResult.cc new file mode 100644 index 000000000..5fb921564 --- /dev/null +++ b/dg/src/model/GetUserGatewaysResult.cc @@ -0,0 +1,79 @@ +/* + * 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::Dg; +using namespace AlibabaCloud::Dg::Model; + +GetUserGatewaysResult::GetUserGatewaysResult() : + ServiceResult() +{} + +GetUserGatewaysResult::GetUserGatewaysResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetUserGatewaysResult::~GetUserGatewaysResult() +{} + +void GetUserGatewaysResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + if(!value["Count"].isNull()) + count_ = std::stoi(value["Count"].asString()); + +} + +std::string GetUserGatewaysResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string GetUserGatewaysResult::getData()const +{ + return data_; +} + +int GetUserGatewaysResult::getCount()const +{ + return count_; +} + +std::string GetUserGatewaysResult::getCode()const +{ + return code_; +} + +bool GetUserGatewaysResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/ListDatabaseAccessPointRequest.cc b/dg/src/model/ListDatabaseAccessPointRequest.cc new file mode 100644 index 000000000..62b614b23 --- /dev/null +++ b/dg/src/model/ListDatabaseAccessPointRequest.cc @@ -0,0 +1,128 @@ +/* + * 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::Dg::Model::ListDatabaseAccessPointRequest; + +ListDatabaseAccessPointRequest::ListDatabaseAccessPointRequest() : + RpcServiceRequest("dg", "2019-03-27", "ListDatabaseAccessPoint") +{ + setMethod(HttpRequest::Method::Post); +} + +ListDatabaseAccessPointRequest::~ListDatabaseAccessPointRequest() +{} + +std::string ListDatabaseAccessPointRequest::getSearchKey()const +{ + return searchKey_; +} + +void ListDatabaseAccessPointRequest::setSearchKey(const std::string& searchKey) +{ + searchKey_ = searchKey; + setBodyParameter("SearchKey", searchKey); +} + +std::string ListDatabaseAccessPointRequest::getPageNumber()const +{ + return pageNumber_; +} + +void ListDatabaseAccessPointRequest::setPageNumber(const std::string& pageNumber) +{ + pageNumber_ = pageNumber; + setBodyParameter("PageNumber", pageNumber); +} + +std::string ListDatabaseAccessPointRequest::getRegionId()const +{ + return regionId_; +} + +void ListDatabaseAccessPointRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string ListDatabaseAccessPointRequest::getPageSize()const +{ + return pageSize_; +} + +void ListDatabaseAccessPointRequest::setPageSize(const std::string& pageSize) +{ + pageSize_ = pageSize; + setBodyParameter("PageSize", pageSize); +} + +std::string ListDatabaseAccessPointRequest::getHost()const +{ + return host_; +} + +void ListDatabaseAccessPointRequest::setHost(const std::string& host) +{ + host_ = host; + setBodyParameter("Host", host); +} + +std::string ListDatabaseAccessPointRequest::getDbInstanceId()const +{ + return dbInstanceId_; +} + +void ListDatabaseAccessPointRequest::setDbInstanceId(const std::string& dbInstanceId) +{ + dbInstanceId_ = dbInstanceId; + setBodyParameter("DbInstanceId", dbInstanceId); +} + +std::string ListDatabaseAccessPointRequest::getGatewayId()const +{ + return gatewayId_; +} + +void ListDatabaseAccessPointRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + +int ListDatabaseAccessPointRequest::getPort()const +{ + return port_; +} + +void ListDatabaseAccessPointRequest::setPort(int port) +{ + port_ = port; + setBodyParameter("Port", std::to_string(port)); +} + +std::string ListDatabaseAccessPointRequest::getVpcId()const +{ + return vpcId_; +} + +void ListDatabaseAccessPointRequest::setVpcId(const std::string& vpcId) +{ + vpcId_ = vpcId; + setBodyParameter("VpcId", vpcId); +} + diff --git a/dg/src/model/ListDatabaseAccessPointResult.cc b/dg/src/model/ListDatabaseAccessPointResult.cc new file mode 100644 index 000000000..c58b2ab57 --- /dev/null +++ b/dg/src/model/ListDatabaseAccessPointResult.cc @@ -0,0 +1,79 @@ +/* + * 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::Dg; +using namespace AlibabaCloud::Dg::Model; + +ListDatabaseAccessPointResult::ListDatabaseAccessPointResult() : + ServiceResult() +{} + +ListDatabaseAccessPointResult::ListDatabaseAccessPointResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListDatabaseAccessPointResult::~ListDatabaseAccessPointResult() +{} + +void ListDatabaseAccessPointResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString(); + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + if(!value["Count"].isNull()) + count_ = std::stoi(value["Count"].asString()); + +} + +std::string ListDatabaseAccessPointResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string ListDatabaseAccessPointResult::getData()const +{ + return data_; +} + +int ListDatabaseAccessPointResult::getCount()const +{ + return count_; +} + +std::string ListDatabaseAccessPointResult::getCode()const +{ + return code_; +} + +std::string ListDatabaseAccessPointResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/ModifyDatabaseRequest.cc b/dg/src/model/ModifyDatabaseRequest.cc new file mode 100644 index 000000000..82e9386a0 --- /dev/null +++ b/dg/src/model/ModifyDatabaseRequest.cc @@ -0,0 +1,117 @@ +/* + * 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::Dg::Model::ModifyDatabaseRequest; + +ModifyDatabaseRequest::ModifyDatabaseRequest() : + RpcServiceRequest("dg", "2019-03-27", "ModifyDatabase") +{ + setMethod(HttpRequest::Method::Post); +} + +ModifyDatabaseRequest::~ModifyDatabaseRequest() +{} + +std::string ModifyDatabaseRequest::getHost()const +{ + return host_; +} + +void ModifyDatabaseRequest::setHost(const std::string& host) +{ + host_ = host; + setBodyParameter("Host", host); +} + +std::string ModifyDatabaseRequest::getDbUserName()const +{ + return dbUserName_; +} + +void ModifyDatabaseRequest::setDbUserName(const std::string& dbUserName) +{ + dbUserName_ = dbUserName; + setBodyParameter("DbUserName", dbUserName); +} + +std::string ModifyDatabaseRequest::getDbDescription()const +{ + return dbDescription_; +} + +void ModifyDatabaseRequest::setDbDescription(const std::string& dbDescription) +{ + dbDescription_ = dbDescription; + setBodyParameter("DbDescription", dbDescription); +} + +std::string ModifyDatabaseRequest::getInstanceId()const +{ + return instanceId_; +} + +void ModifyDatabaseRequest::setInstanceId(const std::string& instanceId) +{ + instanceId_ = instanceId; + setBodyParameter("InstanceId", instanceId); +} + +std::string ModifyDatabaseRequest::getDbName()const +{ + return dbName_; +} + +void ModifyDatabaseRequest::setDbName(const std::string& dbName) +{ + dbName_ = dbName; + setBodyParameter("DbName", dbName); +} + +int ModifyDatabaseRequest::getPort()const +{ + return port_; +} + +void ModifyDatabaseRequest::setPort(int port) +{ + port_ = port; + setBodyParameter("Port", std::to_string(port)); +} + +std::string ModifyDatabaseRequest::getDbPassword()const +{ + return dbPassword_; +} + +void ModifyDatabaseRequest::setDbPassword(const std::string& dbPassword) +{ + dbPassword_ = dbPassword; + setBodyParameter("DbPassword", dbPassword); +} + +std::string ModifyDatabaseRequest::getDbType()const +{ + return dbType_; +} + +void ModifyDatabaseRequest::setDbType(const std::string& dbType) +{ + dbType_ = dbType; + setBodyParameter("DbType", dbType); +} + diff --git a/dg/src/model/ModifyDatabaseResult.cc b/dg/src/model/ModifyDatabaseResult.cc new file mode 100644 index 000000000..6f95e033a --- /dev/null +++ b/dg/src/model/ModifyDatabaseResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +ModifyDatabaseResult::ModifyDatabaseResult() : + ServiceResult() +{} + +ModifyDatabaseResult::ModifyDatabaseResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ModifyDatabaseResult::~ModifyDatabaseResult() +{} + +void ModifyDatabaseResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string ModifyDatabaseResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string ModifyDatabaseResult::getData()const +{ + return data_; +} + +std::string ModifyDatabaseResult::getCode()const +{ + return code_; +} + +bool ModifyDatabaseResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/ModifyGatewayRequest.cc b/dg/src/model/ModifyGatewayRequest.cc new file mode 100644 index 000000000..4e2af8d9d --- /dev/null +++ b/dg/src/model/ModifyGatewayRequest.cc @@ -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. + */ + +#include + +using AlibabaCloud::Dg::Model::ModifyGatewayRequest; + +ModifyGatewayRequest::ModifyGatewayRequest() : + RpcServiceRequest("dg", "2019-03-27", "ModifyGateway") +{ + setMethod(HttpRequest::Method::Post); +} + +ModifyGatewayRequest::~ModifyGatewayRequest() +{} + +std::string ModifyGatewayRequest::getGatewayDesc()const +{ + return gatewayDesc_; +} + +void ModifyGatewayRequest::setGatewayDesc(const std::string& gatewayDesc) +{ + gatewayDesc_ = gatewayDesc; + setBodyParameter("GatewayDesc", gatewayDesc); +} + +std::string ModifyGatewayRequest::getGatewayName()const +{ + return gatewayName_; +} + +void ModifyGatewayRequest::setGatewayName(const std::string& gatewayName) +{ + gatewayName_ = gatewayName; + setBodyParameter("GatewayName", gatewayName); +} + +std::string ModifyGatewayRequest::getGatewayId()const +{ + return gatewayId_; +} + +void ModifyGatewayRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/ModifyGatewayResult.cc b/dg/src/model/ModifyGatewayResult.cc new file mode 100644 index 000000000..fafc0a383 --- /dev/null +++ b/dg/src/model/ModifyGatewayResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +ModifyGatewayResult::ModifyGatewayResult() : + ServiceResult() +{} + +ModifyGatewayResult::ModifyGatewayResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ModifyGatewayResult::~ModifyGatewayResult() +{} + +void ModifyGatewayResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string ModifyGatewayResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string ModifyGatewayResult::getData()const +{ + return data_; +} + +std::string ModifyGatewayResult::getCode()const +{ + return code_; +} + +bool ModifyGatewayResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/RetryDatabaseRequest.cc b/dg/src/model/RetryDatabaseRequest.cc new file mode 100644 index 000000000..203153b8c --- /dev/null +++ b/dg/src/model/RetryDatabaseRequest.cc @@ -0,0 +1,139 @@ +/* + * 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::Dg::Model::RetryDatabaseRequest; + +RetryDatabaseRequest::RetryDatabaseRequest() : + RpcServiceRequest("dg", "2019-03-27", "RetryDatabase") +{ + setMethod(HttpRequest::Method::Post); +} + +RetryDatabaseRequest::~RetryDatabaseRequest() +{} + +std::string RetryDatabaseRequest::getClientToken()const +{ + return clientToken_; +} + +void RetryDatabaseRequest::setClientToken(const std::string& clientToken) +{ + clientToken_ = clientToken; + setBodyParameter("ClientToken", clientToken); +} + +std::string RetryDatabaseRequest::getRegionId()const +{ + return regionId_; +} + +void RetryDatabaseRequest::setRegionId(const std::string& regionId) +{ + regionId_ = regionId; + setBodyParameter("RegionId", regionId); +} + +std::string RetryDatabaseRequest::getHost()const +{ + return host_; +} + +void RetryDatabaseRequest::setHost(const std::string& host) +{ + host_ = host; + setBodyParameter("Host", host); +} + +std::string RetryDatabaseRequest::getDbUserName()const +{ + return dbUserName_; +} + +void RetryDatabaseRequest::setDbUserName(const std::string& dbUserName) +{ + dbUserName_ = dbUserName; + setBodyParameter("DbUserName", dbUserName); +} + +std::string RetryDatabaseRequest::getDbDescription()const +{ + return dbDescription_; +} + +void RetryDatabaseRequest::setDbDescription(const std::string& dbDescription) +{ + dbDescription_ = dbDescription; + setBodyParameter("DbDescription", dbDescription); +} + +std::string RetryDatabaseRequest::getGatewayId()const +{ + return gatewayId_; +} + +void RetryDatabaseRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + +std::string RetryDatabaseRequest::getDbName()const +{ + return dbName_; +} + +void RetryDatabaseRequest::setDbName(const std::string& dbName) +{ + dbName_ = dbName; + setBodyParameter("DbName", dbName); +} + +int RetryDatabaseRequest::getPort()const +{ + return port_; +} + +void RetryDatabaseRequest::setPort(int port) +{ + port_ = port; + setBodyParameter("Port", std::to_string(port)); +} + +std::string RetryDatabaseRequest::getDbPassword()const +{ + return dbPassword_; +} + +void RetryDatabaseRequest::setDbPassword(const std::string& dbPassword) +{ + dbPassword_ = dbPassword; + setBodyParameter("DbPassword", dbPassword); +} + +std::string RetryDatabaseRequest::getDbType()const +{ + return dbType_; +} + +void RetryDatabaseRequest::setDbType(const std::string& dbType) +{ + dbType_ = dbType; + setBodyParameter("DbType", dbType); +} + diff --git a/dg/src/model/RetryDatabaseResult.cc b/dg/src/model/RetryDatabaseResult.cc new file mode 100644 index 000000000..9ffa19882 --- /dev/null +++ b/dg/src/model/RetryDatabaseResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +RetryDatabaseResult::RetryDatabaseResult() : + ServiceResult() +{} + +RetryDatabaseResult::RetryDatabaseResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +RetryDatabaseResult::~RetryDatabaseResult() +{} + +void RetryDatabaseResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string RetryDatabaseResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string RetryDatabaseResult::getData()const +{ + return data_; +} + +std::string RetryDatabaseResult::getCode()const +{ + return code_; +} + +bool RetryDatabaseResult::getSuccess()const +{ + return success_; +} + diff --git a/dg/src/model/StopGatewayRequest.cc b/dg/src/model/StopGatewayRequest.cc new file mode 100644 index 000000000..a63e53cbc --- /dev/null +++ b/dg/src/model/StopGatewayRequest.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 + +using AlibabaCloud::Dg::Model::StopGatewayRequest; + +StopGatewayRequest::StopGatewayRequest() : + RpcServiceRequest("dg", "2019-03-27", "StopGateway") +{ + setMethod(HttpRequest::Method::Post); +} + +StopGatewayRequest::~StopGatewayRequest() +{} + +std::string StopGatewayRequest::getGatewayInstanceId()const +{ + return gatewayInstanceId_; +} + +void StopGatewayRequest::setGatewayInstanceId(const std::string& gatewayInstanceId) +{ + gatewayInstanceId_ = gatewayInstanceId; + setBodyParameter("GatewayInstanceId", gatewayInstanceId); +} + +std::string StopGatewayRequest::getGatewayId()const +{ + return gatewayId_; +} + +void StopGatewayRequest::setGatewayId(const std::string& gatewayId) +{ + gatewayId_ = gatewayId; + setBodyParameter("GatewayId", gatewayId); +} + diff --git a/dg/src/model/StopGatewayResult.cc b/dg/src/model/StopGatewayResult.cc new file mode 100644 index 000000000..d1bc82fc0 --- /dev/null +++ b/dg/src/model/StopGatewayResult.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 +#include + +using namespace AlibabaCloud::Dg; +using namespace AlibabaCloud::Dg::Model; + +StopGatewayResult::StopGatewayResult() : + ServiceResult() +{} + +StopGatewayResult::StopGatewayResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +StopGatewayResult::~StopGatewayResult() +{} + +void StopGatewayResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["Data"].isNull()) + data_ = value["Data"].asString(); + +} + +std::string StopGatewayResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string StopGatewayResult::getData()const +{ + return data_; +} + +std::string StopGatewayResult::getCode()const +{ + return code_; +} + +bool StopGatewayResult::getSuccess()const +{ + return success_; +} +