Gwlb Open API released.

This commit is contained in:
sdk-team
2024-10-16 09:41:04 +00:00
parent 9c795d127b
commit a7841818f4
105 changed files with 7914 additions and 1 deletions

View File

@@ -1 +1 @@
1.36.1999
1.36.2000

182
gwlb/CMakeLists.txt Normal file
View File

@@ -0,0 +1,182 @@
#
# 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(gwlb_public_header
include/alibabacloud/gwlb/GwlbClient.h
include/alibabacloud/gwlb/GwlbExport.h )
set(gwlb_public_header_model
include/alibabacloud/gwlb/model/AddServersToServerGroupRequest.h
include/alibabacloud/gwlb/model/AddServersToServerGroupResult.h
include/alibabacloud/gwlb/model/CreateListenerRequest.h
include/alibabacloud/gwlb/model/CreateListenerResult.h
include/alibabacloud/gwlb/model/CreateLoadBalancerRequest.h
include/alibabacloud/gwlb/model/CreateLoadBalancerResult.h
include/alibabacloud/gwlb/model/CreateServerGroupRequest.h
include/alibabacloud/gwlb/model/CreateServerGroupResult.h
include/alibabacloud/gwlb/model/DeleteListenerRequest.h
include/alibabacloud/gwlb/model/DeleteListenerResult.h
include/alibabacloud/gwlb/model/DeleteLoadBalancerRequest.h
include/alibabacloud/gwlb/model/DeleteLoadBalancerResult.h
include/alibabacloud/gwlb/model/DeleteServerGroupRequest.h
include/alibabacloud/gwlb/model/DeleteServerGroupResult.h
include/alibabacloud/gwlb/model/DescribeRegionsRequest.h
include/alibabacloud/gwlb/model/DescribeRegionsResult.h
include/alibabacloud/gwlb/model/DescribeZonesRequest.h
include/alibabacloud/gwlb/model/DescribeZonesResult.h
include/alibabacloud/gwlb/model/GetListenerAttributeRequest.h
include/alibabacloud/gwlb/model/GetListenerAttributeResult.h
include/alibabacloud/gwlb/model/GetListenerHealthStatusRequest.h
include/alibabacloud/gwlb/model/GetListenerHealthStatusResult.h
include/alibabacloud/gwlb/model/GetLoadBalancerAttributeRequest.h
include/alibabacloud/gwlb/model/GetLoadBalancerAttributeResult.h
include/alibabacloud/gwlb/model/ListListenersRequest.h
include/alibabacloud/gwlb/model/ListListenersResult.h
include/alibabacloud/gwlb/model/ListLoadBalancersRequest.h
include/alibabacloud/gwlb/model/ListLoadBalancersResult.h
include/alibabacloud/gwlb/model/ListServerGroupServersRequest.h
include/alibabacloud/gwlb/model/ListServerGroupServersResult.h
include/alibabacloud/gwlb/model/ListServerGroupsRequest.h
include/alibabacloud/gwlb/model/ListServerGroupsResult.h
include/alibabacloud/gwlb/model/ListTagResourcesRequest.h
include/alibabacloud/gwlb/model/ListTagResourcesResult.h
include/alibabacloud/gwlb/model/MoveResourceGroupRequest.h
include/alibabacloud/gwlb/model/MoveResourceGroupResult.h
include/alibabacloud/gwlb/model/RemoveServersFromServerGroupRequest.h
include/alibabacloud/gwlb/model/RemoveServersFromServerGroupResult.h
include/alibabacloud/gwlb/model/TagResourcesRequest.h
include/alibabacloud/gwlb/model/TagResourcesResult.h
include/alibabacloud/gwlb/model/UntagResourcesRequest.h
include/alibabacloud/gwlb/model/UntagResourcesResult.h
include/alibabacloud/gwlb/model/UpdateListenerAttributeRequest.h
include/alibabacloud/gwlb/model/UpdateListenerAttributeResult.h
include/alibabacloud/gwlb/model/UpdateLoadBalancerAttributeRequest.h
include/alibabacloud/gwlb/model/UpdateLoadBalancerAttributeResult.h
include/alibabacloud/gwlb/model/UpdateLoadBalancerZonesRequest.h
include/alibabacloud/gwlb/model/UpdateLoadBalancerZonesResult.h
include/alibabacloud/gwlb/model/UpdateServerGroupAttributeRequest.h
include/alibabacloud/gwlb/model/UpdateServerGroupAttributeResult.h )
set(gwlb_src
src/GwlbClient.cc
src/model/AddServersToServerGroupRequest.cc
src/model/AddServersToServerGroupResult.cc
src/model/CreateListenerRequest.cc
src/model/CreateListenerResult.cc
src/model/CreateLoadBalancerRequest.cc
src/model/CreateLoadBalancerResult.cc
src/model/CreateServerGroupRequest.cc
src/model/CreateServerGroupResult.cc
src/model/DeleteListenerRequest.cc
src/model/DeleteListenerResult.cc
src/model/DeleteLoadBalancerRequest.cc
src/model/DeleteLoadBalancerResult.cc
src/model/DeleteServerGroupRequest.cc
src/model/DeleteServerGroupResult.cc
src/model/DescribeRegionsRequest.cc
src/model/DescribeRegionsResult.cc
src/model/DescribeZonesRequest.cc
src/model/DescribeZonesResult.cc
src/model/GetListenerAttributeRequest.cc
src/model/GetListenerAttributeResult.cc
src/model/GetListenerHealthStatusRequest.cc
src/model/GetListenerHealthStatusResult.cc
src/model/GetLoadBalancerAttributeRequest.cc
src/model/GetLoadBalancerAttributeResult.cc
src/model/ListListenersRequest.cc
src/model/ListListenersResult.cc
src/model/ListLoadBalancersRequest.cc
src/model/ListLoadBalancersResult.cc
src/model/ListServerGroupServersRequest.cc
src/model/ListServerGroupServersResult.cc
src/model/ListServerGroupsRequest.cc
src/model/ListServerGroupsResult.cc
src/model/ListTagResourcesRequest.cc
src/model/ListTagResourcesResult.cc
src/model/MoveResourceGroupRequest.cc
src/model/MoveResourceGroupResult.cc
src/model/RemoveServersFromServerGroupRequest.cc
src/model/RemoveServersFromServerGroupResult.cc
src/model/TagResourcesRequest.cc
src/model/TagResourcesResult.cc
src/model/UntagResourcesRequest.cc
src/model/UntagResourcesResult.cc
src/model/UpdateListenerAttributeRequest.cc
src/model/UpdateListenerAttributeResult.cc
src/model/UpdateLoadBalancerAttributeRequest.cc
src/model/UpdateLoadBalancerAttributeResult.cc
src/model/UpdateLoadBalancerZonesRequest.cc
src/model/UpdateLoadBalancerZonesResult.cc
src/model/UpdateServerGroupAttributeRequest.cc
src/model/UpdateServerGroupAttributeResult.cc )
add_library(gwlb ${LIB_TYPE}
${gwlb_public_header}
${gwlb_public_header_model}
${gwlb_src})
set_target_properties(gwlb
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}gwlb
)
if(${LIB_TYPE} STREQUAL "SHARED")
set_target_properties(gwlb
PROPERTIES
DEFINE_SYMBOL ALIBABACLOUD_GWLB_LIBRARY)
endif()
target_include_directories(gwlb
PRIVATE include
${CMAKE_SOURCE_DIR}/core/include
)
target_link_libraries(gwlb
core)
if(CMAKE_HOST_WIN32)
ExternalProject_Get_Property(jsoncpp INSTALL_DIR)
set(jsoncpp_install_dir ${INSTALL_DIR})
add_dependencies(gwlb
jsoncpp)
target_include_directories(gwlb
PRIVATE ${jsoncpp_install_dir}/include)
target_link_libraries(gwlb
${jsoncpp_install_dir}/lib/jsoncpp.lib)
set_target_properties(gwlb
PROPERTIES
COMPILE_OPTIONS "/bigobj")
else()
target_include_directories(gwlb
PRIVATE /usr/include/jsoncpp)
target_link_libraries(gwlb
jsoncpp)
endif()
install(FILES ${gwlb_public_header}
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/gwlb)
install(FILES ${gwlb_public_header_model}
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/gwlb/model)
install(TARGETS gwlb
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
)

View File

@@ -0,0 +1,246 @@
/*
* 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_GWLB_GWLBCLIENT_H_
#define ALIBABACLOUD_GWLB_GWLBCLIENT_H_
#include <future>
#include <alibabacloud/core/AsyncCallerContext.h>
#include <alibabacloud/core/EndpointProvider.h>
#include <alibabacloud/core/RpcServiceClient.h>
#include "GwlbExport.h"
#include "model/AddServersToServerGroupRequest.h"
#include "model/AddServersToServerGroupResult.h"
#include "model/CreateListenerRequest.h"
#include "model/CreateListenerResult.h"
#include "model/CreateLoadBalancerRequest.h"
#include "model/CreateLoadBalancerResult.h"
#include "model/CreateServerGroupRequest.h"
#include "model/CreateServerGroupResult.h"
#include "model/DeleteListenerRequest.h"
#include "model/DeleteListenerResult.h"
#include "model/DeleteLoadBalancerRequest.h"
#include "model/DeleteLoadBalancerResult.h"
#include "model/DeleteServerGroupRequest.h"
#include "model/DeleteServerGroupResult.h"
#include "model/DescribeRegionsRequest.h"
#include "model/DescribeRegionsResult.h"
#include "model/DescribeZonesRequest.h"
#include "model/DescribeZonesResult.h"
#include "model/GetListenerAttributeRequest.h"
#include "model/GetListenerAttributeResult.h"
#include "model/GetListenerHealthStatusRequest.h"
#include "model/GetListenerHealthStatusResult.h"
#include "model/GetLoadBalancerAttributeRequest.h"
#include "model/GetLoadBalancerAttributeResult.h"
#include "model/ListListenersRequest.h"
#include "model/ListListenersResult.h"
#include "model/ListLoadBalancersRequest.h"
#include "model/ListLoadBalancersResult.h"
#include "model/ListServerGroupServersRequest.h"
#include "model/ListServerGroupServersResult.h"
#include "model/ListServerGroupsRequest.h"
#include "model/ListServerGroupsResult.h"
#include "model/ListTagResourcesRequest.h"
#include "model/ListTagResourcesResult.h"
#include "model/MoveResourceGroupRequest.h"
#include "model/MoveResourceGroupResult.h"
#include "model/RemoveServersFromServerGroupRequest.h"
#include "model/RemoveServersFromServerGroupResult.h"
#include "model/TagResourcesRequest.h"
#include "model/TagResourcesResult.h"
#include "model/UntagResourcesRequest.h"
#include "model/UntagResourcesResult.h"
#include "model/UpdateListenerAttributeRequest.h"
#include "model/UpdateListenerAttributeResult.h"
#include "model/UpdateLoadBalancerAttributeRequest.h"
#include "model/UpdateLoadBalancerAttributeResult.h"
#include "model/UpdateLoadBalancerZonesRequest.h"
#include "model/UpdateLoadBalancerZonesResult.h"
#include "model/UpdateServerGroupAttributeRequest.h"
#include "model/UpdateServerGroupAttributeResult.h"
namespace AlibabaCloud
{
namespace Gwlb
{
class ALIBABACLOUD_GWLB_EXPORT GwlbClient : public RpcServiceClient
{
public:
typedef Outcome<Error, Model::AddServersToServerGroupResult> AddServersToServerGroupOutcome;
typedef std::future<AddServersToServerGroupOutcome> AddServersToServerGroupOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::AddServersToServerGroupRequest&, const AddServersToServerGroupOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> AddServersToServerGroupAsyncHandler;
typedef Outcome<Error, Model::CreateListenerResult> CreateListenerOutcome;
typedef std::future<CreateListenerOutcome> CreateListenerOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::CreateListenerRequest&, const CreateListenerOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateListenerAsyncHandler;
typedef Outcome<Error, Model::CreateLoadBalancerResult> CreateLoadBalancerOutcome;
typedef std::future<CreateLoadBalancerOutcome> CreateLoadBalancerOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::CreateLoadBalancerRequest&, const CreateLoadBalancerOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateLoadBalancerAsyncHandler;
typedef Outcome<Error, Model::CreateServerGroupResult> CreateServerGroupOutcome;
typedef std::future<CreateServerGroupOutcome> CreateServerGroupOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::CreateServerGroupRequest&, const CreateServerGroupOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateServerGroupAsyncHandler;
typedef Outcome<Error, Model::DeleteListenerResult> DeleteListenerOutcome;
typedef std::future<DeleteListenerOutcome> DeleteListenerOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::DeleteListenerRequest&, const DeleteListenerOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteListenerAsyncHandler;
typedef Outcome<Error, Model::DeleteLoadBalancerResult> DeleteLoadBalancerOutcome;
typedef std::future<DeleteLoadBalancerOutcome> DeleteLoadBalancerOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::DeleteLoadBalancerRequest&, const DeleteLoadBalancerOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteLoadBalancerAsyncHandler;
typedef Outcome<Error, Model::DeleteServerGroupResult> DeleteServerGroupOutcome;
typedef std::future<DeleteServerGroupOutcome> DeleteServerGroupOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::DeleteServerGroupRequest&, const DeleteServerGroupOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteServerGroupAsyncHandler;
typedef Outcome<Error, Model::DescribeRegionsResult> DescribeRegionsOutcome;
typedef std::future<DescribeRegionsOutcome> DescribeRegionsOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::DescribeRegionsRequest&, const DescribeRegionsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeRegionsAsyncHandler;
typedef Outcome<Error, Model::DescribeZonesResult> DescribeZonesOutcome;
typedef std::future<DescribeZonesOutcome> DescribeZonesOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::DescribeZonesRequest&, const DescribeZonesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeZonesAsyncHandler;
typedef Outcome<Error, Model::GetListenerAttributeResult> GetListenerAttributeOutcome;
typedef std::future<GetListenerAttributeOutcome> GetListenerAttributeOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::GetListenerAttributeRequest&, const GetListenerAttributeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetListenerAttributeAsyncHandler;
typedef Outcome<Error, Model::GetListenerHealthStatusResult> GetListenerHealthStatusOutcome;
typedef std::future<GetListenerHealthStatusOutcome> GetListenerHealthStatusOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::GetListenerHealthStatusRequest&, const GetListenerHealthStatusOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetListenerHealthStatusAsyncHandler;
typedef Outcome<Error, Model::GetLoadBalancerAttributeResult> GetLoadBalancerAttributeOutcome;
typedef std::future<GetLoadBalancerAttributeOutcome> GetLoadBalancerAttributeOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::GetLoadBalancerAttributeRequest&, const GetLoadBalancerAttributeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetLoadBalancerAttributeAsyncHandler;
typedef Outcome<Error, Model::ListListenersResult> ListListenersOutcome;
typedef std::future<ListListenersOutcome> ListListenersOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::ListListenersRequest&, const ListListenersOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListListenersAsyncHandler;
typedef Outcome<Error, Model::ListLoadBalancersResult> ListLoadBalancersOutcome;
typedef std::future<ListLoadBalancersOutcome> ListLoadBalancersOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::ListLoadBalancersRequest&, const ListLoadBalancersOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListLoadBalancersAsyncHandler;
typedef Outcome<Error, Model::ListServerGroupServersResult> ListServerGroupServersOutcome;
typedef std::future<ListServerGroupServersOutcome> ListServerGroupServersOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::ListServerGroupServersRequest&, const ListServerGroupServersOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListServerGroupServersAsyncHandler;
typedef Outcome<Error, Model::ListServerGroupsResult> ListServerGroupsOutcome;
typedef std::future<ListServerGroupsOutcome> ListServerGroupsOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::ListServerGroupsRequest&, const ListServerGroupsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListServerGroupsAsyncHandler;
typedef Outcome<Error, Model::ListTagResourcesResult> ListTagResourcesOutcome;
typedef std::future<ListTagResourcesOutcome> ListTagResourcesOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::ListTagResourcesRequest&, const ListTagResourcesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListTagResourcesAsyncHandler;
typedef Outcome<Error, Model::MoveResourceGroupResult> MoveResourceGroupOutcome;
typedef std::future<MoveResourceGroupOutcome> MoveResourceGroupOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::MoveResourceGroupRequest&, const MoveResourceGroupOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> MoveResourceGroupAsyncHandler;
typedef Outcome<Error, Model::RemoveServersFromServerGroupResult> RemoveServersFromServerGroupOutcome;
typedef std::future<RemoveServersFromServerGroupOutcome> RemoveServersFromServerGroupOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::RemoveServersFromServerGroupRequest&, const RemoveServersFromServerGroupOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RemoveServersFromServerGroupAsyncHandler;
typedef Outcome<Error, Model::TagResourcesResult> TagResourcesOutcome;
typedef std::future<TagResourcesOutcome> TagResourcesOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::TagResourcesRequest&, const TagResourcesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> TagResourcesAsyncHandler;
typedef Outcome<Error, Model::UntagResourcesResult> UntagResourcesOutcome;
typedef std::future<UntagResourcesOutcome> UntagResourcesOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::UntagResourcesRequest&, const UntagResourcesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> UntagResourcesAsyncHandler;
typedef Outcome<Error, Model::UpdateListenerAttributeResult> UpdateListenerAttributeOutcome;
typedef std::future<UpdateListenerAttributeOutcome> UpdateListenerAttributeOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::UpdateListenerAttributeRequest&, const UpdateListenerAttributeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> UpdateListenerAttributeAsyncHandler;
typedef Outcome<Error, Model::UpdateLoadBalancerAttributeResult> UpdateLoadBalancerAttributeOutcome;
typedef std::future<UpdateLoadBalancerAttributeOutcome> UpdateLoadBalancerAttributeOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::UpdateLoadBalancerAttributeRequest&, const UpdateLoadBalancerAttributeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> UpdateLoadBalancerAttributeAsyncHandler;
typedef Outcome<Error, Model::UpdateLoadBalancerZonesResult> UpdateLoadBalancerZonesOutcome;
typedef std::future<UpdateLoadBalancerZonesOutcome> UpdateLoadBalancerZonesOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::UpdateLoadBalancerZonesRequest&, const UpdateLoadBalancerZonesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> UpdateLoadBalancerZonesAsyncHandler;
typedef Outcome<Error, Model::UpdateServerGroupAttributeResult> UpdateServerGroupAttributeOutcome;
typedef std::future<UpdateServerGroupAttributeOutcome> UpdateServerGroupAttributeOutcomeCallable;
typedef std::function<void(const GwlbClient*, const Model::UpdateServerGroupAttributeRequest&, const UpdateServerGroupAttributeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> UpdateServerGroupAttributeAsyncHandler;
GwlbClient(const Credentials &credentials, const ClientConfiguration &configuration);
GwlbClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
GwlbClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
~GwlbClient();
AddServersToServerGroupOutcome addServersToServerGroup(const Model::AddServersToServerGroupRequest &request)const;
void addServersToServerGroupAsync(const Model::AddServersToServerGroupRequest& request, const AddServersToServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
AddServersToServerGroupOutcomeCallable addServersToServerGroupCallable(const Model::AddServersToServerGroupRequest& request) const;
CreateListenerOutcome createListener(const Model::CreateListenerRequest &request)const;
void createListenerAsync(const Model::CreateListenerRequest& request, const CreateListenerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CreateListenerOutcomeCallable createListenerCallable(const Model::CreateListenerRequest& request) const;
CreateLoadBalancerOutcome createLoadBalancer(const Model::CreateLoadBalancerRequest &request)const;
void createLoadBalancerAsync(const Model::CreateLoadBalancerRequest& request, const CreateLoadBalancerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CreateLoadBalancerOutcomeCallable createLoadBalancerCallable(const Model::CreateLoadBalancerRequest& request) const;
CreateServerGroupOutcome createServerGroup(const Model::CreateServerGroupRequest &request)const;
void createServerGroupAsync(const Model::CreateServerGroupRequest& request, const CreateServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
CreateServerGroupOutcomeCallable createServerGroupCallable(const Model::CreateServerGroupRequest& request) const;
DeleteListenerOutcome deleteListener(const Model::DeleteListenerRequest &request)const;
void deleteListenerAsync(const Model::DeleteListenerRequest& request, const DeleteListenerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DeleteListenerOutcomeCallable deleteListenerCallable(const Model::DeleteListenerRequest& request) const;
DeleteLoadBalancerOutcome deleteLoadBalancer(const Model::DeleteLoadBalancerRequest &request)const;
void deleteLoadBalancerAsync(const Model::DeleteLoadBalancerRequest& request, const DeleteLoadBalancerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DeleteLoadBalancerOutcomeCallable deleteLoadBalancerCallable(const Model::DeleteLoadBalancerRequest& request) const;
DeleteServerGroupOutcome deleteServerGroup(const Model::DeleteServerGroupRequest &request)const;
void deleteServerGroupAsync(const Model::DeleteServerGroupRequest& request, const DeleteServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DeleteServerGroupOutcomeCallable deleteServerGroupCallable(const Model::DeleteServerGroupRequest& request) const;
DescribeRegionsOutcome describeRegions(const Model::DescribeRegionsRequest &request)const;
void describeRegionsAsync(const Model::DescribeRegionsRequest& request, const DescribeRegionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeRegionsOutcomeCallable describeRegionsCallable(const Model::DescribeRegionsRequest& request) const;
DescribeZonesOutcome describeZones(const Model::DescribeZonesRequest &request)const;
void describeZonesAsync(const Model::DescribeZonesRequest& request, const DescribeZonesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
DescribeZonesOutcomeCallable describeZonesCallable(const Model::DescribeZonesRequest& request) const;
GetListenerAttributeOutcome getListenerAttribute(const Model::GetListenerAttributeRequest &request)const;
void getListenerAttributeAsync(const Model::GetListenerAttributeRequest& request, const GetListenerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
GetListenerAttributeOutcomeCallable getListenerAttributeCallable(const Model::GetListenerAttributeRequest& request) const;
GetListenerHealthStatusOutcome getListenerHealthStatus(const Model::GetListenerHealthStatusRequest &request)const;
void getListenerHealthStatusAsync(const Model::GetListenerHealthStatusRequest& request, const GetListenerHealthStatusAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
GetListenerHealthStatusOutcomeCallable getListenerHealthStatusCallable(const Model::GetListenerHealthStatusRequest& request) const;
GetLoadBalancerAttributeOutcome getLoadBalancerAttribute(const Model::GetLoadBalancerAttributeRequest &request)const;
void getLoadBalancerAttributeAsync(const Model::GetLoadBalancerAttributeRequest& request, const GetLoadBalancerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
GetLoadBalancerAttributeOutcomeCallable getLoadBalancerAttributeCallable(const Model::GetLoadBalancerAttributeRequest& request) const;
ListListenersOutcome listListeners(const Model::ListListenersRequest &request)const;
void listListenersAsync(const Model::ListListenersRequest& request, const ListListenersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ListListenersOutcomeCallable listListenersCallable(const Model::ListListenersRequest& request) const;
ListLoadBalancersOutcome listLoadBalancers(const Model::ListLoadBalancersRequest &request)const;
void listLoadBalancersAsync(const Model::ListLoadBalancersRequest& request, const ListLoadBalancersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ListLoadBalancersOutcomeCallable listLoadBalancersCallable(const Model::ListLoadBalancersRequest& request) const;
ListServerGroupServersOutcome listServerGroupServers(const Model::ListServerGroupServersRequest &request)const;
void listServerGroupServersAsync(const Model::ListServerGroupServersRequest& request, const ListServerGroupServersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ListServerGroupServersOutcomeCallable listServerGroupServersCallable(const Model::ListServerGroupServersRequest& request) const;
ListServerGroupsOutcome listServerGroups(const Model::ListServerGroupsRequest &request)const;
void listServerGroupsAsync(const Model::ListServerGroupsRequest& request, const ListServerGroupsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ListServerGroupsOutcomeCallable listServerGroupsCallable(const Model::ListServerGroupsRequest& request) const;
ListTagResourcesOutcome listTagResources(const Model::ListTagResourcesRequest &request)const;
void listTagResourcesAsync(const Model::ListTagResourcesRequest& request, const ListTagResourcesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
ListTagResourcesOutcomeCallable listTagResourcesCallable(const Model::ListTagResourcesRequest& request) const;
MoveResourceGroupOutcome moveResourceGroup(const Model::MoveResourceGroupRequest &request)const;
void moveResourceGroupAsync(const Model::MoveResourceGroupRequest& request, const MoveResourceGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
MoveResourceGroupOutcomeCallable moveResourceGroupCallable(const Model::MoveResourceGroupRequest& request) const;
RemoveServersFromServerGroupOutcome removeServersFromServerGroup(const Model::RemoveServersFromServerGroupRequest &request)const;
void removeServersFromServerGroupAsync(const Model::RemoveServersFromServerGroupRequest& request, const RemoveServersFromServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
RemoveServersFromServerGroupOutcomeCallable removeServersFromServerGroupCallable(const Model::RemoveServersFromServerGroupRequest& request) const;
TagResourcesOutcome tagResources(const Model::TagResourcesRequest &request)const;
void tagResourcesAsync(const Model::TagResourcesRequest& request, const TagResourcesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
TagResourcesOutcomeCallable tagResourcesCallable(const Model::TagResourcesRequest& request) const;
UntagResourcesOutcome untagResources(const Model::UntagResourcesRequest &request)const;
void untagResourcesAsync(const Model::UntagResourcesRequest& request, const UntagResourcesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
UntagResourcesOutcomeCallable untagResourcesCallable(const Model::UntagResourcesRequest& request) const;
UpdateListenerAttributeOutcome updateListenerAttribute(const Model::UpdateListenerAttributeRequest &request)const;
void updateListenerAttributeAsync(const Model::UpdateListenerAttributeRequest& request, const UpdateListenerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
UpdateListenerAttributeOutcomeCallable updateListenerAttributeCallable(const Model::UpdateListenerAttributeRequest& request) const;
UpdateLoadBalancerAttributeOutcome updateLoadBalancerAttribute(const Model::UpdateLoadBalancerAttributeRequest &request)const;
void updateLoadBalancerAttributeAsync(const Model::UpdateLoadBalancerAttributeRequest& request, const UpdateLoadBalancerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
UpdateLoadBalancerAttributeOutcomeCallable updateLoadBalancerAttributeCallable(const Model::UpdateLoadBalancerAttributeRequest& request) const;
UpdateLoadBalancerZonesOutcome updateLoadBalancerZones(const Model::UpdateLoadBalancerZonesRequest &request)const;
void updateLoadBalancerZonesAsync(const Model::UpdateLoadBalancerZonesRequest& request, const UpdateLoadBalancerZonesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
UpdateLoadBalancerZonesOutcomeCallable updateLoadBalancerZonesCallable(const Model::UpdateLoadBalancerZonesRequest& request) const;
UpdateServerGroupAttributeOutcome updateServerGroupAttribute(const Model::UpdateServerGroupAttributeRequest &request)const;
void updateServerGroupAttributeAsync(const Model::UpdateServerGroupAttributeRequest& request, const UpdateServerGroupAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
UpdateServerGroupAttributeOutcomeCallable updateServerGroupAttributeCallable(const Model::UpdateServerGroupAttributeRequest& request) const;
private:
std::shared_ptr<EndpointProvider> endpointProvider_;
};
}
}
#endif // !ALIBABACLOUD_GWLB_GWLBCLIENT_H_

View File

@@ -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_GWLB_GWLBEXPORT_H_
#define ALIBABACLOUD_GWLB_GWLBEXPORT_H_
#include <alibabacloud/core/Global.h>
#if defined(ALIBABACLOUD_SHARED)
# if defined(ALIBABACLOUD_GWLB_LIBRARY)
# define ALIBABACLOUD_GWLB_EXPORT ALIBABACLOUD_DECL_EXPORT
# else
# define ALIBABACLOUD_GWLB_EXPORT ALIBABACLOUD_DECL_IMPORT
# endif
#else
# define ALIBABACLOUD_GWLB_EXPORT
#endif
#endif // !ALIBABACLOUD_GWLB_GWLBEXPORT_H_

View File

@@ -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_GWLB_MODEL_ADDSERVERSTOSERVERGROUPREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_ADDSERVERSTOSERVERGROUPREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT AddServersToServerGroupRequest : public RpcServiceRequest {
public:
struct Servers {
int port;
std::string serverId;
std::string serverIp;
std::string serverType;
};
AddServersToServerGroupRequest();
~AddServersToServerGroupRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getServerGroupId() const;
void setServerGroupId(const std::string &serverGroupId);
std::vector<Servers> getServers() const;
void setServers(const std::vector<Servers> &servers);
bool getDryRun() const;
void setDryRun(bool dryRun);
private:
std::string clientToken_;
std::string serverGroupId_;
std::vector<Servers> servers_;
bool dryRun_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_ADDSERVERSTOSERVERGROUPREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_ADDSERVERSTOSERVERGROUPRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_ADDSERVERSTOSERVERGROUPRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT AddServersToServerGroupResult : public ServiceResult
{
public:
AddServersToServerGroupResult();
explicit AddServersToServerGroupResult(const std::string &payload);
~AddServersToServerGroupResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_ADDSERVERSTOSERVERGROUPRESULT_H_

View File

@@ -0,0 +1,61 @@
/*
* 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_GWLB_MODEL_CREATELISTENERREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_CREATELISTENERREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT CreateListenerRequest : public RpcServiceRequest {
public:
struct Tag {
std::string key;
std::string value;
};
CreateListenerRequest();
~CreateListenerRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getServerGroupId() const;
void setServerGroupId(const std::string &serverGroupId);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::string getLoadBalancerId() const;
void setLoadBalancerId(const std::string &loadBalancerId);
std::string getListenerDescription() const;
void setListenerDescription(const std::string &listenerDescription);
private:
std::string clientToken_;
std::string serverGroupId_;
std::vector<Tag> tag_;
bool dryRun_;
std::string loadBalancerId_;
std::string listenerDescription_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_CREATELISTENERREQUEST_H_

View File

@@ -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_GWLB_MODEL_CREATELISTENERRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_CREATELISTENERRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT CreateListenerResult : public ServiceResult
{
public:
CreateListenerResult();
explicit CreateListenerResult(const std::string &payload);
~CreateListenerResult();
std::string getListenerId()const;
protected:
void parse(const std::string &payload);
private:
std::string listenerId_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_CREATELISTENERRESULT_H_

View File

@@ -0,0 +1,74 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_CREATELOADBALANCERREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_CREATELOADBALANCERREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT CreateLoadBalancerRequest : public RpcServiceRequest {
public:
struct Tag {
std::string key;
std::string value;
};
struct ZoneMappings {
std::string vSwitchId;
std::string zoneId;
};
CreateLoadBalancerRequest();
~CreateLoadBalancerRequest();
bool getCrossZoneEnabled() const;
void setCrossZoneEnabled(bool crossZoneEnabled);
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getAddressIpVersion() const;
void setAddressIpVersion(const std::string &addressIpVersion);
std::string getResourceGroupId() const;
void setResourceGroupId(const std::string &resourceGroupId);
std::string getLoadBalancerName() const;
void setLoadBalancerName(const std::string &loadBalancerName);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::vector<ZoneMappings> getZoneMappings() const;
void setZoneMappings(const std::vector<ZoneMappings> &zoneMappings);
std::string getVpcId() const;
void setVpcId(const std::string &vpcId);
private:
bool crossZoneEnabled_;
std::string clientToken_;
std::string addressIpVersion_;
std::string resourceGroupId_;
std::string loadBalancerName_;
std::vector<Tag> tag_;
bool dryRun_;
std::vector<ZoneMappings> zoneMappings_;
std::string vpcId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_CREATELOADBALANCERREQUEST_H_

View File

@@ -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_GWLB_MODEL_CREATELOADBALANCERRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_CREATELOADBALANCERRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT CreateLoadBalancerResult : public ServiceResult
{
public:
CreateLoadBalancerResult();
explicit CreateLoadBalancerResult(const std::string &payload);
~CreateLoadBalancerResult();
std::string getLoadBalancerId()const;
protected:
void parse(const std::string &payload);
private:
std::string loadBalancerId_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_CREATELOADBALANCERRESULT_H_

View File

@@ -0,0 +1,93 @@
/*
* 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_GWLB_MODEL_CREATESERVERGROUPREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_CREATESERVERGROUPREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT CreateServerGroupRequest : public RpcServiceRequest {
public:
struct HealthCheckConfig {
int healthCheckConnectPort;
int healthCheckConnectTimeout;
std::string healthCheckDomain;
bool healthCheckEnabled;
std::string string;
std::vector<std::string> healthCheckHttpCode;
int healthCheckInterval;
std::string healthCheckPath;
std::string healthCheckProtocol;
int healthyThreshold;
int unhealthyThreshold;
};
struct Tag {
std::string key;
std::string value;
};
struct ConnectionDrainConfig {
bool connectionDrainEnabled;
int connectionDrainTimeout;
};
CreateServerGroupRequest();
~CreateServerGroupRequest();
std::string getServerGroupName() const;
void setServerGroupName(const std::string &serverGroupName);
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
HealthCheckConfig getHealthCheckConfig() const;
void setHealthCheckConfig(const HealthCheckConfig &healthCheckConfig);
std::string getScheduler() const;
void setScheduler(const std::string &scheduler);
std::string getResourceGroupId() const;
void setResourceGroupId(const std::string &resourceGroupId);
std::string getProtocol() const;
void setProtocol(const std::string &protocol);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
bool getDryRun() const;
void setDryRun(bool dryRun);
ConnectionDrainConfig getConnectionDrainConfig() const;
void setConnectionDrainConfig(const ConnectionDrainConfig &connectionDrainConfig);
std::string getServerGroupType() const;
void setServerGroupType(const std::string &serverGroupType);
std::string getVpcId() const;
void setVpcId(const std::string &vpcId);
private:
std::string serverGroupName_;
std::string clientToken_;
HealthCheckConfig healthCheckConfig_;
std::string scheduler_;
std::string resourceGroupId_;
std::string protocol_;
std::vector<Tag> tag_;
bool dryRun_;
ConnectionDrainConfig connectionDrainConfig_;
std::string serverGroupType_;
std::string vpcId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_CREATESERVERGROUPREQUEST_H_

View File

@@ -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_GWLB_MODEL_CREATESERVERGROUPRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_CREATESERVERGROUPRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT CreateServerGroupResult : public ServiceResult
{
public:
CreateServerGroupResult();
explicit CreateServerGroupResult(const std::string &payload);
~CreateServerGroupResult();
std::string getServerGroupId()const;
protected:
void parse(const std::string &payload);
private:
std::string serverGroupId_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_CREATESERVERGROUPRESULT_H_

View File

@@ -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_GWLB_MODEL_DELETELISTENERREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_DELETELISTENERREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT DeleteListenerRequest : public RpcServiceRequest {
public:
DeleteListenerRequest();
~DeleteListenerRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getListenerId() const;
void setListenerId(const std::string &listenerId);
bool getDryRun() const;
void setDryRun(bool dryRun);
private:
std::string clientToken_;
std::string listenerId_;
bool dryRun_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_DELETELISTENERREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_DELETELISTENERRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_DELETELISTENERRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT DeleteListenerResult : public ServiceResult
{
public:
DeleteListenerResult();
explicit DeleteListenerResult(const std::string &payload);
~DeleteListenerResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_DELETELISTENERRESULT_H_

View File

@@ -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_GWLB_MODEL_DELETELOADBALANCERREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_DELETELOADBALANCERREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT DeleteLoadBalancerRequest : public RpcServiceRequest {
public:
DeleteLoadBalancerRequest();
~DeleteLoadBalancerRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::string getLoadBalancerId() const;
void setLoadBalancerId(const std::string &loadBalancerId);
private:
std::string clientToken_;
bool dryRun_;
std::string loadBalancerId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_DELETELOADBALANCERREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_DELETELOADBALANCERRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_DELETELOADBALANCERRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT DeleteLoadBalancerResult : public ServiceResult
{
public:
DeleteLoadBalancerResult();
explicit DeleteLoadBalancerResult(const std::string &payload);
~DeleteLoadBalancerResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_DELETELOADBALANCERRESULT_H_

View File

@@ -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_GWLB_MODEL_DELETESERVERGROUPREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_DELETESERVERGROUPREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT DeleteServerGroupRequest : public RpcServiceRequest {
public:
DeleteServerGroupRequest();
~DeleteServerGroupRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getServerGroupId() const;
void setServerGroupId(const std::string &serverGroupId);
bool getDryRun() const;
void setDryRun(bool dryRun);
private:
std::string clientToken_;
std::string serverGroupId_;
bool dryRun_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_DELETESERVERGROUPREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_DELETESERVERGROUPRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_DELETESERVERGROUPRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT DeleteServerGroupResult : public ServiceResult
{
public:
DeleteServerGroupResult();
explicit DeleteServerGroupResult(const std::string &payload);
~DeleteServerGroupResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_DELETESERVERGROUPRESULT_H_

View File

@@ -0,0 +1,42 @@
/*
* 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_GWLB_MODEL_DESCRIBEREGIONSREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_DESCRIBEREGIONSREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT DescribeRegionsRequest : public RpcServiceRequest {
public:
DescribeRegionsRequest();
~DescribeRegionsRequest();
std::string getAcceptLanguage() const;
void setAcceptLanguage(const std::string &acceptLanguage);
private:
std::string acceptLanguage_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_DESCRIBEREGIONSREQUEST_H_

View File

@@ -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_GWLB_MODEL_DESCRIBEREGIONSRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_DESCRIBEREGIONSRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT DescribeRegionsResult : public ServiceResult
{
public:
struct Data
{
std::string regionId;
std::string regionEndpoint;
std::string localName;
};
DescribeRegionsResult();
explicit DescribeRegionsResult(const std::string &payload);
~DescribeRegionsResult();
std::vector<Data> getRegions()const;
protected:
void parse(const std::string &payload);
private:
std::vector<Data> regions_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_DESCRIBEREGIONSRESULT_H_

View File

@@ -0,0 +1,42 @@
/*
* 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_GWLB_MODEL_DESCRIBEZONESREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_DESCRIBEZONESREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT DescribeZonesRequest : public RpcServiceRequest {
public:
DescribeZonesRequest();
~DescribeZonesRequest();
std::string getAcceptLanguage() const;
void setAcceptLanguage(const std::string &acceptLanguage);
private:
std::string acceptLanguage_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_DESCRIBEZONESREQUEST_H_

View File

@@ -0,0 +1,56 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_DESCRIBEZONESRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_DESCRIBEZONESRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT DescribeZonesResult : public ServiceResult
{
public:
struct Data
{
std::string zoneId;
std::string localName;
};
DescribeZonesResult();
explicit DescribeZonesResult(const std::string &payload);
~DescribeZonesResult();
std::vector<Data> getZones()const;
protected:
void parse(const std::string &payload);
private:
std::vector<Data> zones_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_DESCRIBEZONESRESULT_H_

View File

@@ -0,0 +1,42 @@
/*
* 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_GWLB_MODEL_GETLISTENERATTRIBUTEREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_GETLISTENERATTRIBUTEREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT GetListenerAttributeRequest : public RpcServiceRequest {
public:
GetListenerAttributeRequest();
~GetListenerAttributeRequest();
std::string getListenerId() const;
void setListenerId(const std::string &listenerId);
private:
std::string listenerId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_GETLISTENERATTRIBUTEREQUEST_H_

View File

@@ -0,0 +1,68 @@
/*
* 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_GWLB_MODEL_GETLISTENERATTRIBUTERESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_GETLISTENERATTRIBUTERESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT GetListenerAttributeResult : public ServiceResult
{
public:
struct TagModel
{
std::string value;
std::string key;
};
GetListenerAttributeResult();
explicit GetListenerAttributeResult(const std::string &payload);
~GetListenerAttributeResult();
std::string getListenerStatus()const;
std::string getListenerDescription()const;
std::string getServerGroupId()const;
std::string getLoadBalancerId()const;
std::string getRegionId()const;
std::vector<TagModel> getTags()const;
std::string getListenerId()const;
protected:
void parse(const std::string &payload);
private:
std::string listenerStatus_;
std::string listenerDescription_;
std::string serverGroupId_;
std::string loadBalancerId_;
std::string regionId_;
std::vector<TagModel> tags_;
std::string listenerId_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_GETLISTENERATTRIBUTERESULT_H_

View File

@@ -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_GWLB_MODEL_GETLISTENERHEALTHSTATUSREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_GETLISTENERHEALTHSTATUSREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT GetListenerHealthStatusRequest : public RpcServiceRequest {
public:
struct Filter {
std::string name;
std::string string;
std::vector<std::string> values;
};
GetListenerHealthStatusRequest();
~GetListenerHealthStatusRequest();
int getSkip() const;
void setSkip(int skip);
std::string getListenerId() const;
void setListenerId(const std::string &listenerId);
std::string getNextToken() const;
void setNextToken(const std::string &nextToken);
std::vector<Filter> getFilter() const;
void setFilter(const std::vector<Filter> &filter);
int getMaxResults() const;
void setMaxResults(int maxResults);
private:
int skip_;
std::string listenerId_;
std::string nextToken_;
std::vector<Filter> filter_;
int maxResults_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_GETLISTENERHEALTHSTATUSREQUEST_H_

View File

@@ -0,0 +1,80 @@
/*
* 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_GWLB_MODEL_GETLISTENERHEALTHSTATUSRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_GETLISTENERHEALTHSTATUSRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT GetListenerHealthStatusResult : public ServiceResult
{
public:
struct ListenerHealthStatusItem
{
struct ServerGroupInfo
{
struct Server
{
struct Reason
{
std::string reasonCode;
};
std::string status;
std::string serverId;
int port;
std::string serverIp;
Reason reason;
};
std::string serverGroupId;
std::vector<ServerGroupInfo::Server> servers;
bool healthCheckEnabled;
};
std::vector<ListenerHealthStatusItem::ServerGroupInfo> serverGroupInfos;
std::string listenerId;
};
GetListenerHealthStatusResult();
explicit GetListenerHealthStatusResult(const std::string &payload);
~GetListenerHealthStatusResult();
std::vector<ListenerHealthStatusItem> getListenerHealthStatus()const;
int getTotalCount()const;
std::string getNextToken()const;
int getMaxResults()const;
protected:
void parse(const std::string &payload);
private:
std::vector<ListenerHealthStatusItem> listenerHealthStatus_;
int totalCount_;
std::string nextToken_;
int maxResults_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_GETLISTENERHEALTHSTATUSRESULT_H_

View File

@@ -0,0 +1,42 @@
/*
* 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_GWLB_MODEL_GETLOADBALANCERATTRIBUTEREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_GETLOADBALANCERATTRIBUTEREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT GetLoadBalancerAttributeRequest : public RpcServiceRequest {
public:
GetLoadBalancerAttributeRequest();
~GetLoadBalancerAttributeRequest();
std::string getLoadBalancerId() const;
void setLoadBalancerId(const std::string &loadBalancerId);
private:
std::string loadBalancerId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_GETLOADBALANCERATTRIBUTEREQUEST_H_

View File

@@ -0,0 +1,87 @@
/*
* 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_GWLB_MODEL_GETLOADBALANCERATTRIBUTERESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_GETLOADBALANCERATTRIBUTERESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT GetLoadBalancerAttributeResult : public ServiceResult
{
public:
struct TagModel
{
std::string value;
std::string key;
};
struct ZoneEniModel
{
struct EniModels
{
std::string eniId;
std::string privateIpv4Address;
};
std::string zoneId;
std::string vSwitchId;
std::vector<ZoneEniModel::EniModels> loadBalancerAddresses;
};
GetLoadBalancerAttributeResult();
explicit GetLoadBalancerAttributeResult(const std::string &payload);
~GetLoadBalancerAttributeResult();
std::string getLoadBalancerName()const;
std::string getAddressIpVersion()const;
std::string getResourceGroupId()const;
std::string getVpcId()const;
std::string getCreateTime()const;
std::string getLoadBalancerId()const;
std::vector<ZoneEniModel> getZoneMappings()const;
std::string getLoadBalancerBusinessStatus()const;
std::string getLoadBalancerStatus()const;
std::vector<TagModel> getTags()const;
bool getCrossZoneEnabled()const;
protected:
void parse(const std::string &payload);
private:
std::string loadBalancerName_;
std::string addressIpVersion_;
std::string resourceGroupId_;
std::string vpcId_;
std::string createTime_;
std::string loadBalancerId_;
std::vector<ZoneEniModel> zoneMappings_;
std::string loadBalancerBusinessStatus_;
std::string loadBalancerStatus_;
std::vector<TagModel> tags_;
bool crossZoneEnabled_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_GETLOADBALANCERATTRIBUTERESULT_H_

View File

@@ -0,0 +1,61 @@
/*
* 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_GWLB_MODEL_LISTLISTENERSREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTLISTENERSREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT ListListenersRequest : public RpcServiceRequest {
public:
struct Tag {
std::string key;
std::string value;
};
ListListenersRequest();
~ListListenersRequest();
std::vector<std::string> getLoadBalancerIds() const;
void setLoadBalancerIds(const std::vector<std::string> &loadBalancerIds);
long getSkip() const;
void setSkip(long skip);
std::string getNextToken() const;
void setNextToken(const std::string &nextToken);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
std::vector<std::string> getListenerIds() const;
void setListenerIds(const std::vector<std::string> &listenerIds);
int getMaxResults() const;
void setMaxResults(int maxResults);
private:
std::vector<std::string> loadBalancerIds_;
long skip_;
std::string nextToken_;
std::vector<Tag> tag_;
std::vector<std::string> listenerIds_;
int maxResults_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTLISTENERSREQUEST_H_

View File

@@ -0,0 +1,71 @@
/*
* 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_GWLB_MODEL_LISTLISTENERSRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTLISTENERSRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT ListListenersResult : public ServiceResult
{
public:
struct Listener
{
struct TagModel
{
std::string value;
std::string key;
};
std::string listenerStatus;
std::string listenerDescription;
std::string serverGroupId;
std::string loadBalancerId;
std::vector<Listener::TagModel> tags;
std::string listenerId;
};
ListListenersResult();
explicit ListListenersResult(const std::string &payload);
~ListListenersResult();
std::vector<Listener> getListeners()const;
int getTotalCount()const;
std::string getNextToken()const;
int getMaxResults()const;
protected:
void parse(const std::string &payload);
private:
std::vector<Listener> listeners_;
int totalCount_;
std::string nextToken_;
int maxResults_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTLISTENERSRESULT_H_

View File

@@ -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.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_LISTLOADBALANCERSREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTLOADBALANCERSREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT ListLoadBalancersRequest : public RpcServiceRequest {
public:
struct Tag {
std::string key;
std::string value;
};
ListLoadBalancersRequest();
~ListLoadBalancersRequest();
std::vector<std::string> getLoadBalancerNames() const;
void setLoadBalancerNames(const std::vector<std::string> &loadBalancerNames);
std::vector<std::string> getLoadBalancerIds() const;
void setLoadBalancerIds(const std::vector<std::string> &loadBalancerIds);
int getSkip() const;
void setSkip(int skip);
std::string getAddressIpVersion() const;
void setAddressIpVersion(const std::string &addressIpVersion);
std::string getResourceGroupId() const;
void setResourceGroupId(const std::string &resourceGroupId);
std::vector<std::string> getZoneIds() const;
void setZoneIds(const std::vector<std::string> &zoneIds);
std::string getNextToken() const;
void setNextToken(const std::string &nextToken);
std::vector<std::string> getVpcIds() const;
void setVpcIds(const std::vector<std::string> &vpcIds);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
std::string getLoadBalancerBusinessStatus() const;
void setLoadBalancerBusinessStatus(const std::string &loadBalancerBusinessStatus);
std::string getLoadBalancerStatus() const;
void setLoadBalancerStatus(const std::string &loadBalancerStatus);
int getMaxResults() const;
void setMaxResults(int maxResults);
private:
std::vector<std::string> loadBalancerNames_;
std::vector<std::string> loadBalancerIds_;
int skip_;
std::string addressIpVersion_;
std::string resourceGroupId_;
std::vector<std::string> zoneIds_;
std::string nextToken_;
std::vector<std::string> vpcIds_;
std::vector<Tag> tag_;
std::string loadBalancerBusinessStatus_;
std::string loadBalancerStatus_;
int maxResults_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTLOADBALANCERSREQUEST_H_

View File

@@ -0,0 +1,87 @@
/*
* 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_GWLB_MODEL_LISTLOADBALANCERSRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTLOADBALANCERSRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT ListLoadBalancersResult : public ServiceResult
{
public:
struct Data
{
struct TagModel
{
std::string value;
std::string key;
};
struct ZoneEniModel
{
struct EniModels
{
std::string eniId;
std::string privateIpv4Address;
};
std::string zoneId;
std::string vSwitchId;
std::vector<ZoneEniModel::EniModels> loadBalancerAddresses;
};
std::string loadBalancerName;
std::string addressIpVersion;
std::string resourceGroupId;
std::string vpcId;
std::string createTime;
std::string loadBalancerId;
std::vector<Data::ZoneEniModel> zoneMappings;
std::string loadBalancerBusinessStatus;
std::string loadBalancerStatus;
std::vector<Data::TagModel> tags;
bool crossZoneEnabled;
};
ListLoadBalancersResult();
explicit ListLoadBalancersResult(const std::string &payload);
~ListLoadBalancersResult();
int getTotalCount()const;
std::string getNextToken()const;
int getMaxResults()const;
std::vector<Data> getLoadBalancers()const;
protected:
void parse(const std::string &payload);
private:
int totalCount_;
std::string nextToken_;
int maxResults_;
std::vector<Data> loadBalancers_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTLOADBALANCERSRESULT_H_

View File

@@ -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_GWLB_MODEL_LISTSERVERGROUPSERVERSREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSERVERSREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT ListServerGroupServersRequest : public RpcServiceRequest {
public:
ListServerGroupServersRequest();
~ListServerGroupServersRequest();
int getSkip() const;
void setSkip(int skip);
std::string getServerGroupId() const;
void setServerGroupId(const std::string &serverGroupId);
std::string getNextToken() const;
void setNextToken(const std::string &nextToken);
std::vector<std::string> getServerIds() const;
void setServerIds(const std::vector<std::string> &serverIds);
std::vector<std::string> getServerIps() const;
void setServerIps(const std::vector<std::string> &serverIps);
int getMaxResults() const;
void setMaxResults(int maxResults);
private:
int skip_;
std::string serverGroupId_;
std::string nextToken_;
std::vector<std::string> serverIds_;
std::vector<std::string> serverIps_;
int maxResults_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSERVERSREQUEST_H_

View File

@@ -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_GWLB_MODEL_LISTSERVERGROUPSERVERSRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSERVERSRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT ListServerGroupServersResult : public ServiceResult
{
public:
struct Server
{
std::string status;
std::string serverType;
std::string serverId;
int port;
std::string serverIp;
std::string serverGroupId;
};
ListServerGroupServersResult();
explicit ListServerGroupServersResult(const std::string &payload);
~ListServerGroupServersResult();
int getTotalCount()const;
std::string getNextToken()const;
int getMaxResults()const;
std::vector<Server> getServers()const;
protected:
void parse(const std::string &payload);
private:
int totalCount_;
std::string nextToken_;
int maxResults_;
std::vector<Server> servers_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSERVERSRESULT_H_

View File

@@ -0,0 +1,70 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT ListServerGroupsRequest : public RpcServiceRequest {
public:
struct Tag {
std::string key;
std::string value;
};
ListServerGroupsRequest();
~ListServerGroupsRequest();
std::vector<std::string> getServerGroupNames() const;
void setServerGroupNames(const std::vector<std::string> &serverGroupNames);
int getSkip() const;
void setSkip(int skip);
std::string getResourceGroupId() const;
void setResourceGroupId(const std::string &resourceGroupId);
std::string getNextToken() const;
void setNextToken(const std::string &nextToken);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
std::vector<std::string> getServerGroupIds() const;
void setServerGroupIds(const std::vector<std::string> &serverGroupIds);
std::string getServerGroupType() const;
void setServerGroupType(const std::string &serverGroupType);
std::string getVpcId() const;
void setVpcId(const std::string &vpcId);
int getMaxResults() const;
void setMaxResults(int maxResults);
private:
std::vector<std::string> serverGroupNames_;
int skip_;
std::string resourceGroupId_;
std::string nextToken_;
std::vector<Tag> tag_;
std::vector<std::string> serverGroupIds_;
std::string serverGroupType_;
std::string vpcId_;
int maxResults_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSREQUEST_H_

View File

@@ -0,0 +1,97 @@
/*
* 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_GWLB_MODEL_LISTSERVERGROUPSRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT ListServerGroupsResult : public ServiceResult
{
public:
struct ServerGroup
{
struct ConnectionDrainConfig
{
bool connectionDrainEnabled;
int connectionDrainTimeout;
};
struct HealthCheckConfig
{
int healthCheckInterval;
int healthCheckConnectPort;
int unhealthyThreshold;
std::string healthCheckPath;
int healthyThreshold;
int healthCheckConnectTimeout;
std::string healthCheckProtocol;
std::string healthCheckDomain;
bool healthCheckEnabled;
std::vector<std::string> healthCheckHttpCode;
};
struct TagModel
{
std::string value;
std::string key;
};
ConnectionDrainConfig connectionDrainConfig;
std::vector<std::string> relatedLoadBalancerIds;
std::string resourceGroupId;
std::string scheduler;
std::string createTime;
int serverCount;
std::string serverGroupId;
std::string serverGroupType;
std::string serverGroupStatus;
std::string vpcId;
HealthCheckConfig healthCheckConfig;
std::string protocol;
std::vector<ServerGroup::TagModel> tags;
std::string serverGroupName;
};
ListServerGroupsResult();
explicit ListServerGroupsResult(const std::string &payload);
~ListServerGroupsResult();
int getTotalCount()const;
std::string getNextToken()const;
std::vector<ServerGroup> getServerGroups()const;
int getMaxResults()const;
protected:
void parse(const std::string &payload);
private:
int totalCount_;
std::string nextToken_;
std::vector<ServerGroup> serverGroups_;
int maxResults_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTSERVERGROUPSRESULT_H_

View File

@@ -0,0 +1,58 @@
/*
* 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_GWLB_MODEL_LISTTAGRESOURCESREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTTAGRESOURCESREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT ListTagResourcesRequest : public RpcServiceRequest {
public:
struct Tag {
std::string key;
std::string value;
};
ListTagResourcesRequest();
~ListTagResourcesRequest();
std::string getNextToken() const;
void setNextToken(const std::string &nextToken);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
std::vector<std::string> getResourceId() const;
void setResourceId(const std::vector<std::string> &resourceId);
std::string getResourceType() const;
void setResourceType(const std::string &resourceType);
int getMaxResults() const;
void setMaxResults(int maxResults);
private:
std::string nextToken_;
std::vector<Tag> tag_;
std::vector<std::string> resourceId_;
std::string resourceType_;
int maxResults_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTTAGRESOURCESREQUEST_H_

View File

@@ -0,0 +1,60 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_LISTTAGRESOURCESRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_LISTTAGRESOURCESRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT ListTagResourcesResult : public ServiceResult
{
public:
struct TagResource
{
std::string resourceId;
std::string tagKey;
std::string resourceType;
std::string tagValue;
};
ListTagResourcesResult();
explicit ListTagResourcesResult(const std::string &payload);
~ListTagResourcesResult();
std::string getNextToken()const;
std::vector<TagResource> getTagResources()const;
protected:
void parse(const std::string &payload);
private:
std::string nextToken_;
std::vector<TagResource> tagResources_;
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_LISTTAGRESOURCESRESULT_H_

View File

@@ -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_GWLB_MODEL_MOVERESOURCEGROUPREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_MOVERESOURCEGROUPREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT MoveResourceGroupRequest : public RpcServiceRequest {
public:
MoveResourceGroupRequest();
~MoveResourceGroupRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getResourceId() const;
void setResourceId(const std::string &resourceId);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::string getResourceType() const;
void setResourceType(const std::string &resourceType);
std::string getNewResourceGroupId() const;
void setNewResourceGroupId(const std::string &newResourceGroupId);
private:
std::string clientToken_;
std::string resourceId_;
bool dryRun_;
std::string resourceType_;
std::string newResourceGroupId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_MOVERESOURCEGROUPREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_MOVERESOURCEGROUPRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_MOVERESOURCEGROUPRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT MoveResourceGroupResult : public ServiceResult
{
public:
MoveResourceGroupResult();
explicit MoveResourceGroupResult(const std::string &payload);
~MoveResourceGroupResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_MOVERESOURCEGROUPRESULT_H_

View File

@@ -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_GWLB_MODEL_REMOVESERVERSFROMSERVERGROUPREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_REMOVESERVERSFROMSERVERGROUPREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT RemoveServersFromServerGroupRequest : public RpcServiceRequest {
public:
struct Servers {
int port;
std::string serverId;
std::string serverIp;
std::string serverType;
};
RemoveServersFromServerGroupRequest();
~RemoveServersFromServerGroupRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getServerGroupId() const;
void setServerGroupId(const std::string &serverGroupId);
std::vector<Servers> getServers() const;
void setServers(const std::vector<Servers> &servers);
bool getDryRun() const;
void setDryRun(bool dryRun);
private:
std::string clientToken_;
std::string serverGroupId_;
std::vector<Servers> servers_;
bool dryRun_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_REMOVESERVERSFROMSERVERGROUPREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_REMOVESERVERSFROMSERVERGROUPRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_REMOVESERVERSFROMSERVERGROUPRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT RemoveServersFromServerGroupResult : public ServiceResult
{
public:
RemoveServersFromServerGroupResult();
explicit RemoveServersFromServerGroupResult(const std::string &payload);
~RemoveServersFromServerGroupResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_REMOVESERVERSFROMSERVERGROUPRESULT_H_

View File

@@ -0,0 +1,58 @@
/*
* 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_GWLB_MODEL_TAGRESOURCESREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_TAGRESOURCESREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT TagResourcesRequest : public RpcServiceRequest {
public:
struct Tag {
std::string key;
std::string value;
};
TagResourcesRequest();
~TagResourcesRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
std::vector<std::string> getResourceId() const;
void setResourceId(const std::vector<std::string> &resourceId);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::string getResourceType() const;
void setResourceType(const std::string &resourceType);
private:
std::string clientToken_;
std::vector<Tag> tag_;
std::vector<std::string> resourceId_;
bool dryRun_;
std::string resourceType_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_TAGRESOURCESREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_TAGRESOURCESRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_TAGRESOURCESRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT TagResourcesResult : public ServiceResult
{
public:
TagResourcesResult();
explicit TagResourcesResult(const std::string &payload);
~TagResourcesResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_TAGRESOURCESRESULT_H_

View File

@@ -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_GWLB_MODEL_UNTAGRESOURCESREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_UNTAGRESOURCESREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT UntagResourcesRequest : public RpcServiceRequest {
public:
UntagResourcesRequest();
~UntagResourcesRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
bool getAll() const;
void setAll(bool all);
std::vector<std::string> getResourceId() const;
void setResourceId(const std::vector<std::string> &resourceId);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::string getResourceType() const;
void setResourceType(const std::string &resourceType);
std::vector<std::string> getTagKey() const;
void setTagKey(const std::vector<std::string> &tagKey);
private:
std::string clientToken_;
bool all_;
std::vector<std::string> resourceId_;
bool dryRun_;
std::string resourceType_;
std::vector<std::string> tagKey_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_UNTAGRESOURCESREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_UNTAGRESOURCESRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_UNTAGRESOURCESRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT UntagResourcesResult : public ServiceResult
{
public:
UntagResourcesResult();
explicit UntagResourcesResult(const std::string &payload);
~UntagResourcesResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_UNTAGRESOURCESRESULT_H_

View File

@@ -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_GWLB_MODEL_UPDATELISTENERATTRIBUTEREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATELISTENERATTRIBUTEREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT UpdateListenerAttributeRequest : public RpcServiceRequest {
public:
UpdateListenerAttributeRequest();
~UpdateListenerAttributeRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getServerGroupId() const;
void setServerGroupId(const std::string &serverGroupId);
std::string getListenerId() const;
void setListenerId(const std::string &listenerId);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::string getListenerDescription() const;
void setListenerDescription(const std::string &listenerDescription);
private:
std::string clientToken_;
std::string serverGroupId_;
std::string listenerId_;
bool dryRun_;
std::string listenerDescription_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATELISTENERATTRIBUTEREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_UPDATELISTENERATTRIBUTERESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATELISTENERATTRIBUTERESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT UpdateListenerAttributeResult : public ServiceResult
{
public:
UpdateListenerAttributeResult();
explicit UpdateListenerAttributeResult(const std::string &payload);
~UpdateListenerAttributeResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATELISTENERATTRIBUTERESULT_H_

View File

@@ -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_GWLB_MODEL_UPDATELOADBALANCERATTRIBUTEREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERATTRIBUTEREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT UpdateLoadBalancerAttributeRequest : public RpcServiceRequest {
public:
UpdateLoadBalancerAttributeRequest();
~UpdateLoadBalancerAttributeRequest();
bool getCrossZoneEnabled() const;
void setCrossZoneEnabled(bool crossZoneEnabled);
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
std::string getLoadBalancerName() const;
void setLoadBalancerName(const std::string &loadBalancerName);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::string getLoadBalancerId() const;
void setLoadBalancerId(const std::string &loadBalancerId);
private:
bool crossZoneEnabled_;
std::string clientToken_;
std::string loadBalancerName_;
bool dryRun_;
std::string loadBalancerId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERATTRIBUTEREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERATTRIBUTERESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERATTRIBUTERESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT UpdateLoadBalancerAttributeResult : public ServiceResult
{
public:
UpdateLoadBalancerAttributeResult();
explicit UpdateLoadBalancerAttributeResult(const std::string &payload);
~UpdateLoadBalancerAttributeResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERATTRIBUTERESULT_H_

View File

@@ -0,0 +1,55 @@
/*
* 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_GWLB_MODEL_UPDATELOADBALANCERZONESREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERZONESREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT UpdateLoadBalancerZonesRequest : public RpcServiceRequest {
public:
struct ZoneMappings {
std::string vSwitchId;
std::string zoneId;
};
UpdateLoadBalancerZonesRequest();
~UpdateLoadBalancerZonesRequest();
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
bool getDryRun() const;
void setDryRun(bool dryRun);
std::vector<ZoneMappings> getZoneMappings() const;
void setZoneMappings(const std::vector<ZoneMappings> &zoneMappings);
std::string getLoadBalancerId() const;
void setLoadBalancerId(const std::string &loadBalancerId);
private:
std::string clientToken_;
bool dryRun_;
std::vector<ZoneMappings> zoneMappings_;
std::string loadBalancerId_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERZONESREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERZONESRESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERZONESRESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT UpdateLoadBalancerZonesResult : public ServiceResult
{
public:
UpdateLoadBalancerZonesResult();
explicit UpdateLoadBalancerZonesResult(const std::string &payload);
~UpdateLoadBalancerZonesResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATELOADBALANCERZONESRESULT_H_

View File

@@ -0,0 +1,77 @@
/*
* 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_GWLB_MODEL_UPDATESERVERGROUPATTRIBUTEREQUEST_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATESERVERGROUPATTRIBUTEREQUEST_H_
#include <alibabacloud/gwlb/GwlbExport.h>
#include <alibabacloud/core/RpcServiceRequest.h>
#include <string>
#include <vector>
#include <map>
namespace AlibabaCloud {
namespace Gwlb {
namespace Model {
class ALIBABACLOUD_GWLB_EXPORT UpdateServerGroupAttributeRequest : public RpcServiceRequest {
public:
struct HealthCheckConfig {
int healthCheckConnectPort;
int healthCheckConnectTimeout;
std::string healthCheckDomain;
bool healthCheckEnabled;
std::string string;
std::vector<std::string> healthCheckHttpCode;
int healthCheckInterval;
std::string healthCheckPath;
std::string healthCheckProtocol;
int healthyThreshold;
int unhealthyThreshold;
};
struct ConnectionDrainConfig {
bool connectionDrainEnabled;
int connectionDrainTimeout;
};
UpdateServerGroupAttributeRequest();
~UpdateServerGroupAttributeRequest();
std::string getServerGroupName() const;
void setServerGroupName(const std::string &serverGroupName);
std::string getClientToken() const;
void setClientToken(const std::string &clientToken);
HealthCheckConfig getHealthCheckConfig() const;
void setHealthCheckConfig(const HealthCheckConfig &healthCheckConfig);
std::string getServerGroupId() const;
void setServerGroupId(const std::string &serverGroupId);
std::string getScheduler() const;
void setScheduler(const std::string &scheduler);
bool getDryRun() const;
void setDryRun(bool dryRun);
ConnectionDrainConfig getConnectionDrainConfig() const;
void setConnectionDrainConfig(const ConnectionDrainConfig &connectionDrainConfig);
private:
std::string serverGroupName_;
std::string clientToken_;
HealthCheckConfig healthCheckConfig_;
std::string serverGroupId_;
std::string scheduler_;
bool dryRun_;
ConnectionDrainConfig connectionDrainConfig_;
};
} // namespace Model
} // namespace Gwlb
} // namespace AlibabaCloud
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATESERVERGROUPATTRIBUTEREQUEST_H_

View File

@@ -0,0 +1,49 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef ALIBABACLOUD_GWLB_MODEL_UPDATESERVERGROUPATTRIBUTERESULT_H_
#define ALIBABACLOUD_GWLB_MODEL_UPDATESERVERGROUPATTRIBUTERESULT_H_
#include <string>
#include <vector>
#include <utility>
#include <alibabacloud/core/ServiceResult.h>
#include <alibabacloud/gwlb/GwlbExport.h>
namespace AlibabaCloud
{
namespace Gwlb
{
namespace Model
{
class ALIBABACLOUD_GWLB_EXPORT UpdateServerGroupAttributeResult : public ServiceResult
{
public:
UpdateServerGroupAttributeResult();
explicit UpdateServerGroupAttributeResult(const std::string &payload);
~UpdateServerGroupAttributeResult();
protected:
void parse(const std::string &payload);
private:
};
}
}
}
#endif // !ALIBABACLOUD_GWLB_MODEL_UPDATESERVERGROUPATTRIBUTERESULT_H_

953
gwlb/src/GwlbClient.cc Normal file
View File

@@ -0,0 +1,953 @@
/*
* 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 <alibabacloud/gwlb/GwlbClient.h>
#include <alibabacloud/core/SimpleCredentialsProvider.h>
using namespace AlibabaCloud;
using namespace AlibabaCloud::Location;
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
namespace
{
const std::string SERVICE_NAME = "Gwlb";
}
GwlbClient::GwlbClient(const Credentials &credentials, const ClientConfiguration &configuration) :
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(credentials), configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentials, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
}
GwlbClient::GwlbClient(const std::shared_ptr<CredentialsProvider>& credentialsProvider, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentialsProvider, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
}
GwlbClient::GwlbClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(accessKeyId, accessKeySecret), configuration)
{
auto locationClient = std::make_shared<LocationClient>(accessKeyId, accessKeySecret, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
}
GwlbClient::~GwlbClient()
{}
GwlbClient::AddServersToServerGroupOutcome GwlbClient::addServersToServerGroup(const AddServersToServerGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return AddServersToServerGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return AddServersToServerGroupOutcome(AddServersToServerGroupResult(outcome.result()));
else
return AddServersToServerGroupOutcome(outcome.error());
}
void GwlbClient::addServersToServerGroupAsync(const AddServersToServerGroupRequest& request, const AddServersToServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, addServersToServerGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::AddServersToServerGroupOutcomeCallable GwlbClient::addServersToServerGroupCallable(const AddServersToServerGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<AddServersToServerGroupOutcome()>>(
[this, request]()
{
return this->addServersToServerGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::CreateListenerOutcome GwlbClient::createListener(const CreateListenerRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return CreateListenerOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return CreateListenerOutcome(CreateListenerResult(outcome.result()));
else
return CreateListenerOutcome(outcome.error());
}
void GwlbClient::createListenerAsync(const CreateListenerRequest& request, const CreateListenerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, createListener(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::CreateListenerOutcomeCallable GwlbClient::createListenerCallable(const CreateListenerRequest &request) const
{
auto task = std::make_shared<std::packaged_task<CreateListenerOutcome()>>(
[this, request]()
{
return this->createListener(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::CreateLoadBalancerOutcome GwlbClient::createLoadBalancer(const CreateLoadBalancerRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return CreateLoadBalancerOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return CreateLoadBalancerOutcome(CreateLoadBalancerResult(outcome.result()));
else
return CreateLoadBalancerOutcome(outcome.error());
}
void GwlbClient::createLoadBalancerAsync(const CreateLoadBalancerRequest& request, const CreateLoadBalancerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, createLoadBalancer(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::CreateLoadBalancerOutcomeCallable GwlbClient::createLoadBalancerCallable(const CreateLoadBalancerRequest &request) const
{
auto task = std::make_shared<std::packaged_task<CreateLoadBalancerOutcome()>>(
[this, request]()
{
return this->createLoadBalancer(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::CreateServerGroupOutcome GwlbClient::createServerGroup(const CreateServerGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return CreateServerGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return CreateServerGroupOutcome(CreateServerGroupResult(outcome.result()));
else
return CreateServerGroupOutcome(outcome.error());
}
void GwlbClient::createServerGroupAsync(const CreateServerGroupRequest& request, const CreateServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, createServerGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::CreateServerGroupOutcomeCallable GwlbClient::createServerGroupCallable(const CreateServerGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<CreateServerGroupOutcome()>>(
[this, request]()
{
return this->createServerGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::DeleteListenerOutcome GwlbClient::deleteListener(const DeleteListenerRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DeleteListenerOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DeleteListenerOutcome(DeleteListenerResult(outcome.result()));
else
return DeleteListenerOutcome(outcome.error());
}
void GwlbClient::deleteListenerAsync(const DeleteListenerRequest& request, const DeleteListenerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, deleteListener(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::DeleteListenerOutcomeCallable GwlbClient::deleteListenerCallable(const DeleteListenerRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DeleteListenerOutcome()>>(
[this, request]()
{
return this->deleteListener(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::DeleteLoadBalancerOutcome GwlbClient::deleteLoadBalancer(const DeleteLoadBalancerRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DeleteLoadBalancerOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DeleteLoadBalancerOutcome(DeleteLoadBalancerResult(outcome.result()));
else
return DeleteLoadBalancerOutcome(outcome.error());
}
void GwlbClient::deleteLoadBalancerAsync(const DeleteLoadBalancerRequest& request, const DeleteLoadBalancerAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, deleteLoadBalancer(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::DeleteLoadBalancerOutcomeCallable GwlbClient::deleteLoadBalancerCallable(const DeleteLoadBalancerRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DeleteLoadBalancerOutcome()>>(
[this, request]()
{
return this->deleteLoadBalancer(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::DeleteServerGroupOutcome GwlbClient::deleteServerGroup(const DeleteServerGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DeleteServerGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DeleteServerGroupOutcome(DeleteServerGroupResult(outcome.result()));
else
return DeleteServerGroupOutcome(outcome.error());
}
void GwlbClient::deleteServerGroupAsync(const DeleteServerGroupRequest& request, const DeleteServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, deleteServerGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::DeleteServerGroupOutcomeCallable GwlbClient::deleteServerGroupCallable(const DeleteServerGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DeleteServerGroupOutcome()>>(
[this, request]()
{
return this->deleteServerGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::DescribeRegionsOutcome GwlbClient::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 GwlbClient::describeRegionsAsync(const DescribeRegionsRequest& request, const DescribeRegionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeRegions(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::DescribeRegionsOutcomeCallable GwlbClient::describeRegionsCallable(const DescribeRegionsRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeRegionsOutcome()>>(
[this, request]()
{
return this->describeRegions(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::DescribeZonesOutcome GwlbClient::describeZones(const DescribeZonesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeZonesOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeZonesOutcome(DescribeZonesResult(outcome.result()));
else
return DescribeZonesOutcome(outcome.error());
}
void GwlbClient::describeZonesAsync(const DescribeZonesRequest& request, const DescribeZonesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeZones(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::DescribeZonesOutcomeCallable GwlbClient::describeZonesCallable(const DescribeZonesRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeZonesOutcome()>>(
[this, request]()
{
return this->describeZones(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::GetListenerAttributeOutcome GwlbClient::getListenerAttribute(const GetListenerAttributeRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return GetListenerAttributeOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return GetListenerAttributeOutcome(GetListenerAttributeResult(outcome.result()));
else
return GetListenerAttributeOutcome(outcome.error());
}
void GwlbClient::getListenerAttributeAsync(const GetListenerAttributeRequest& request, const GetListenerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, getListenerAttribute(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::GetListenerAttributeOutcomeCallable GwlbClient::getListenerAttributeCallable(const GetListenerAttributeRequest &request) const
{
auto task = std::make_shared<std::packaged_task<GetListenerAttributeOutcome()>>(
[this, request]()
{
return this->getListenerAttribute(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::GetListenerHealthStatusOutcome GwlbClient::getListenerHealthStatus(const GetListenerHealthStatusRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return GetListenerHealthStatusOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return GetListenerHealthStatusOutcome(GetListenerHealthStatusResult(outcome.result()));
else
return GetListenerHealthStatusOutcome(outcome.error());
}
void GwlbClient::getListenerHealthStatusAsync(const GetListenerHealthStatusRequest& request, const GetListenerHealthStatusAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, getListenerHealthStatus(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::GetListenerHealthStatusOutcomeCallable GwlbClient::getListenerHealthStatusCallable(const GetListenerHealthStatusRequest &request) const
{
auto task = std::make_shared<std::packaged_task<GetListenerHealthStatusOutcome()>>(
[this, request]()
{
return this->getListenerHealthStatus(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::GetLoadBalancerAttributeOutcome GwlbClient::getLoadBalancerAttribute(const GetLoadBalancerAttributeRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return GetLoadBalancerAttributeOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return GetLoadBalancerAttributeOutcome(GetLoadBalancerAttributeResult(outcome.result()));
else
return GetLoadBalancerAttributeOutcome(outcome.error());
}
void GwlbClient::getLoadBalancerAttributeAsync(const GetLoadBalancerAttributeRequest& request, const GetLoadBalancerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, getLoadBalancerAttribute(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::GetLoadBalancerAttributeOutcomeCallable GwlbClient::getLoadBalancerAttributeCallable(const GetLoadBalancerAttributeRequest &request) const
{
auto task = std::make_shared<std::packaged_task<GetLoadBalancerAttributeOutcome()>>(
[this, request]()
{
return this->getLoadBalancerAttribute(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::ListListenersOutcome GwlbClient::listListeners(const ListListenersRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListListenersOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListListenersOutcome(ListListenersResult(outcome.result()));
else
return ListListenersOutcome(outcome.error());
}
void GwlbClient::listListenersAsync(const ListListenersRequest& request, const ListListenersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listListeners(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::ListListenersOutcomeCallable GwlbClient::listListenersCallable(const ListListenersRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListListenersOutcome()>>(
[this, request]()
{
return this->listListeners(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::ListLoadBalancersOutcome GwlbClient::listLoadBalancers(const ListLoadBalancersRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListLoadBalancersOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListLoadBalancersOutcome(ListLoadBalancersResult(outcome.result()));
else
return ListLoadBalancersOutcome(outcome.error());
}
void GwlbClient::listLoadBalancersAsync(const ListLoadBalancersRequest& request, const ListLoadBalancersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listLoadBalancers(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::ListLoadBalancersOutcomeCallable GwlbClient::listLoadBalancersCallable(const ListLoadBalancersRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListLoadBalancersOutcome()>>(
[this, request]()
{
return this->listLoadBalancers(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::ListServerGroupServersOutcome GwlbClient::listServerGroupServers(const ListServerGroupServersRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListServerGroupServersOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListServerGroupServersOutcome(ListServerGroupServersResult(outcome.result()));
else
return ListServerGroupServersOutcome(outcome.error());
}
void GwlbClient::listServerGroupServersAsync(const ListServerGroupServersRequest& request, const ListServerGroupServersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listServerGroupServers(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::ListServerGroupServersOutcomeCallable GwlbClient::listServerGroupServersCallable(const ListServerGroupServersRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListServerGroupServersOutcome()>>(
[this, request]()
{
return this->listServerGroupServers(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::ListServerGroupsOutcome GwlbClient::listServerGroups(const ListServerGroupsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListServerGroupsOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListServerGroupsOutcome(ListServerGroupsResult(outcome.result()));
else
return ListServerGroupsOutcome(outcome.error());
}
void GwlbClient::listServerGroupsAsync(const ListServerGroupsRequest& request, const ListServerGroupsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listServerGroups(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::ListServerGroupsOutcomeCallable GwlbClient::listServerGroupsCallable(const ListServerGroupsRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListServerGroupsOutcome()>>(
[this, request]()
{
return this->listServerGroups(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::ListTagResourcesOutcome GwlbClient::listTagResources(const ListTagResourcesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListTagResourcesOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListTagResourcesOutcome(ListTagResourcesResult(outcome.result()));
else
return ListTagResourcesOutcome(outcome.error());
}
void GwlbClient::listTagResourcesAsync(const ListTagResourcesRequest& request, const ListTagResourcesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listTagResources(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::ListTagResourcesOutcomeCallable GwlbClient::listTagResourcesCallable(const ListTagResourcesRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListTagResourcesOutcome()>>(
[this, request]()
{
return this->listTagResources(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::MoveResourceGroupOutcome GwlbClient::moveResourceGroup(const MoveResourceGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return MoveResourceGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return MoveResourceGroupOutcome(MoveResourceGroupResult(outcome.result()));
else
return MoveResourceGroupOutcome(outcome.error());
}
void GwlbClient::moveResourceGroupAsync(const MoveResourceGroupRequest& request, const MoveResourceGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, moveResourceGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::MoveResourceGroupOutcomeCallable GwlbClient::moveResourceGroupCallable(const MoveResourceGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<MoveResourceGroupOutcome()>>(
[this, request]()
{
return this->moveResourceGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::RemoveServersFromServerGroupOutcome GwlbClient::removeServersFromServerGroup(const RemoveServersFromServerGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return RemoveServersFromServerGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return RemoveServersFromServerGroupOutcome(RemoveServersFromServerGroupResult(outcome.result()));
else
return RemoveServersFromServerGroupOutcome(outcome.error());
}
void GwlbClient::removeServersFromServerGroupAsync(const RemoveServersFromServerGroupRequest& request, const RemoveServersFromServerGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, removeServersFromServerGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::RemoveServersFromServerGroupOutcomeCallable GwlbClient::removeServersFromServerGroupCallable(const RemoveServersFromServerGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<RemoveServersFromServerGroupOutcome()>>(
[this, request]()
{
return this->removeServersFromServerGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::TagResourcesOutcome GwlbClient::tagResources(const TagResourcesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return TagResourcesOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return TagResourcesOutcome(TagResourcesResult(outcome.result()));
else
return TagResourcesOutcome(outcome.error());
}
void GwlbClient::tagResourcesAsync(const TagResourcesRequest& request, const TagResourcesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, tagResources(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::TagResourcesOutcomeCallable GwlbClient::tagResourcesCallable(const TagResourcesRequest &request) const
{
auto task = std::make_shared<std::packaged_task<TagResourcesOutcome()>>(
[this, request]()
{
return this->tagResources(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::UntagResourcesOutcome GwlbClient::untagResources(const UntagResourcesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return UntagResourcesOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return UntagResourcesOutcome(UntagResourcesResult(outcome.result()));
else
return UntagResourcesOutcome(outcome.error());
}
void GwlbClient::untagResourcesAsync(const UntagResourcesRequest& request, const UntagResourcesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, untagResources(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::UntagResourcesOutcomeCallable GwlbClient::untagResourcesCallable(const UntagResourcesRequest &request) const
{
auto task = std::make_shared<std::packaged_task<UntagResourcesOutcome()>>(
[this, request]()
{
return this->untagResources(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::UpdateListenerAttributeOutcome GwlbClient::updateListenerAttribute(const UpdateListenerAttributeRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return UpdateListenerAttributeOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return UpdateListenerAttributeOutcome(UpdateListenerAttributeResult(outcome.result()));
else
return UpdateListenerAttributeOutcome(outcome.error());
}
void GwlbClient::updateListenerAttributeAsync(const UpdateListenerAttributeRequest& request, const UpdateListenerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, updateListenerAttribute(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::UpdateListenerAttributeOutcomeCallable GwlbClient::updateListenerAttributeCallable(const UpdateListenerAttributeRequest &request) const
{
auto task = std::make_shared<std::packaged_task<UpdateListenerAttributeOutcome()>>(
[this, request]()
{
return this->updateListenerAttribute(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::UpdateLoadBalancerAttributeOutcome GwlbClient::updateLoadBalancerAttribute(const UpdateLoadBalancerAttributeRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return UpdateLoadBalancerAttributeOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return UpdateLoadBalancerAttributeOutcome(UpdateLoadBalancerAttributeResult(outcome.result()));
else
return UpdateLoadBalancerAttributeOutcome(outcome.error());
}
void GwlbClient::updateLoadBalancerAttributeAsync(const UpdateLoadBalancerAttributeRequest& request, const UpdateLoadBalancerAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, updateLoadBalancerAttribute(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::UpdateLoadBalancerAttributeOutcomeCallable GwlbClient::updateLoadBalancerAttributeCallable(const UpdateLoadBalancerAttributeRequest &request) const
{
auto task = std::make_shared<std::packaged_task<UpdateLoadBalancerAttributeOutcome()>>(
[this, request]()
{
return this->updateLoadBalancerAttribute(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::UpdateLoadBalancerZonesOutcome GwlbClient::updateLoadBalancerZones(const UpdateLoadBalancerZonesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return UpdateLoadBalancerZonesOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return UpdateLoadBalancerZonesOutcome(UpdateLoadBalancerZonesResult(outcome.result()));
else
return UpdateLoadBalancerZonesOutcome(outcome.error());
}
void GwlbClient::updateLoadBalancerZonesAsync(const UpdateLoadBalancerZonesRequest& request, const UpdateLoadBalancerZonesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, updateLoadBalancerZones(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::UpdateLoadBalancerZonesOutcomeCallable GwlbClient::updateLoadBalancerZonesCallable(const UpdateLoadBalancerZonesRequest &request) const
{
auto task = std::make_shared<std::packaged_task<UpdateLoadBalancerZonesOutcome()>>(
[this, request]()
{
return this->updateLoadBalancerZones(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
GwlbClient::UpdateServerGroupAttributeOutcome GwlbClient::updateServerGroupAttribute(const UpdateServerGroupAttributeRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return UpdateServerGroupAttributeOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return UpdateServerGroupAttributeOutcome(UpdateServerGroupAttributeResult(outcome.result()));
else
return UpdateServerGroupAttributeOutcome(outcome.error());
}
void GwlbClient::updateServerGroupAttributeAsync(const UpdateServerGroupAttributeRequest& request, const UpdateServerGroupAttributeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, updateServerGroupAttribute(request), context);
};
asyncExecute(new Runnable(fn));
}
GwlbClient::UpdateServerGroupAttributeOutcomeCallable GwlbClient::updateServerGroupAttributeCallable(const UpdateServerGroupAttributeRequest &request) const
{
auto task = std::make_shared<std::packaged_task<UpdateServerGroupAttributeOutcome()>>(
[this, request]()
{
return this->updateServerGroupAttribute(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}

View File

@@ -0,0 +1,68 @@
/*
* 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 <alibabacloud/gwlb/model/AddServersToServerGroupRequest.h>
using AlibabaCloud::Gwlb::Model::AddServersToServerGroupRequest;
AddServersToServerGroupRequest::AddServersToServerGroupRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "AddServersToServerGroup") {
setMethod(HttpRequest::Method::Post);
}
AddServersToServerGroupRequest::~AddServersToServerGroupRequest() {}
std::string AddServersToServerGroupRequest::getClientToken() const {
return clientToken_;
}
void AddServersToServerGroupRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string AddServersToServerGroupRequest::getServerGroupId() const {
return serverGroupId_;
}
void AddServersToServerGroupRequest::setServerGroupId(const std::string &serverGroupId) {
serverGroupId_ = serverGroupId;
setBodyParameter(std::string("ServerGroupId"), serverGroupId);
}
std::vector<AddServersToServerGroupRequest::Servers> AddServersToServerGroupRequest::getServers() const {
return servers_;
}
void AddServersToServerGroupRequest::setServers(const std::vector<AddServersToServerGroupRequest::Servers> &servers) {
servers_ = servers;
for(int dep1 = 0; dep1 != servers.size(); dep1++) {
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".Port", std::to_string(servers[dep1].port));
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".ServerId", servers[dep1].serverId);
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".ServerIp", servers[dep1].serverIp);
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".ServerType", servers[dep1].serverType);
}
}
bool AddServersToServerGroupRequest::getDryRun() const {
return dryRun_;
}
void AddServersToServerGroupRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/AddServersToServerGroupResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
AddServersToServerGroupResult::AddServersToServerGroupResult() :
ServiceResult()
{}
AddServersToServerGroupResult::AddServersToServerGroupResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
AddServersToServerGroupResult::~AddServersToServerGroupResult()
{}
void AddServersToServerGroupResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -0,0 +1,84 @@
/*
* 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 <alibabacloud/gwlb/model/CreateListenerRequest.h>
using AlibabaCloud::Gwlb::Model::CreateListenerRequest;
CreateListenerRequest::CreateListenerRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "CreateListener") {
setMethod(HttpRequest::Method::Post);
}
CreateListenerRequest::~CreateListenerRequest() {}
std::string CreateListenerRequest::getClientToken() const {
return clientToken_;
}
void CreateListenerRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string CreateListenerRequest::getServerGroupId() const {
return serverGroupId_;
}
void CreateListenerRequest::setServerGroupId(const std::string &serverGroupId) {
serverGroupId_ = serverGroupId;
setBodyParameter(std::string("ServerGroupId"), serverGroupId);
}
std::vector<CreateListenerRequest::Tag> CreateListenerRequest::getTag() const {
return tag_;
}
void CreateListenerRequest::setTag(const std::vector<CreateListenerRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
bool CreateListenerRequest::getDryRun() const {
return dryRun_;
}
void CreateListenerRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::string CreateListenerRequest::getLoadBalancerId() const {
return loadBalancerId_;
}
void CreateListenerRequest::setLoadBalancerId(const std::string &loadBalancerId) {
loadBalancerId_ = loadBalancerId;
setBodyParameter(std::string("LoadBalancerId"), loadBalancerId);
}
std::string CreateListenerRequest::getListenerDescription() const {
return listenerDescription_;
}
void CreateListenerRequest::setListenerDescription(const std::string &listenerDescription) {
listenerDescription_ = listenerDescription;
setBodyParameter(std::string("ListenerDescription"), listenerDescription);
}

View File

@@ -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 <alibabacloud/gwlb/model/CreateListenerResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
CreateListenerResult::CreateListenerResult() :
ServiceResult()
{}
CreateListenerResult::CreateListenerResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
CreateListenerResult::~CreateListenerResult()
{}
void CreateListenerResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["ListenerId"].isNull())
listenerId_ = value["ListenerId"].asString();
}
std::string CreateListenerResult::getListenerId()const
{
return listenerId_;
}

View File

@@ -0,0 +1,114 @@
/*
* 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 <alibabacloud/gwlb/model/CreateLoadBalancerRequest.h>
using AlibabaCloud::Gwlb::Model::CreateLoadBalancerRequest;
CreateLoadBalancerRequest::CreateLoadBalancerRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "CreateLoadBalancer") {
setMethod(HttpRequest::Method::Post);
}
CreateLoadBalancerRequest::~CreateLoadBalancerRequest() {}
bool CreateLoadBalancerRequest::getCrossZoneEnabled() const {
return crossZoneEnabled_;
}
void CreateLoadBalancerRequest::setCrossZoneEnabled(bool crossZoneEnabled) {
crossZoneEnabled_ = crossZoneEnabled;
setBodyParameter(std::string("CrossZoneEnabled"), crossZoneEnabled ? "true" : "false");
}
std::string CreateLoadBalancerRequest::getClientToken() const {
return clientToken_;
}
void CreateLoadBalancerRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string CreateLoadBalancerRequest::getAddressIpVersion() const {
return addressIpVersion_;
}
void CreateLoadBalancerRequest::setAddressIpVersion(const std::string &addressIpVersion) {
addressIpVersion_ = addressIpVersion;
setBodyParameter(std::string("AddressIpVersion"), addressIpVersion);
}
std::string CreateLoadBalancerRequest::getResourceGroupId() const {
return resourceGroupId_;
}
void CreateLoadBalancerRequest::setResourceGroupId(const std::string &resourceGroupId) {
resourceGroupId_ = resourceGroupId;
setBodyParameter(std::string("ResourceGroupId"), resourceGroupId);
}
std::string CreateLoadBalancerRequest::getLoadBalancerName() const {
return loadBalancerName_;
}
void CreateLoadBalancerRequest::setLoadBalancerName(const std::string &loadBalancerName) {
loadBalancerName_ = loadBalancerName;
setBodyParameter(std::string("LoadBalancerName"), loadBalancerName);
}
std::vector<CreateLoadBalancerRequest::Tag> CreateLoadBalancerRequest::getTag() const {
return tag_;
}
void CreateLoadBalancerRequest::setTag(const std::vector<CreateLoadBalancerRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
bool CreateLoadBalancerRequest::getDryRun() const {
return dryRun_;
}
void CreateLoadBalancerRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::vector<CreateLoadBalancerRequest::ZoneMappings> CreateLoadBalancerRequest::getZoneMappings() const {
return zoneMappings_;
}
void CreateLoadBalancerRequest::setZoneMappings(const std::vector<CreateLoadBalancerRequest::ZoneMappings> &zoneMappings) {
zoneMappings_ = zoneMappings;
for(int dep1 = 0; dep1 != zoneMappings.size(); dep1++) {
setBodyParameter(std::string("ZoneMappings") + "." + std::to_string(dep1 + 1) + ".VSwitchId", zoneMappings[dep1].vSwitchId);
setBodyParameter(std::string("ZoneMappings") + "." + std::to_string(dep1 + 1) + ".ZoneId", zoneMappings[dep1].zoneId);
}
}
std::string CreateLoadBalancerRequest::getVpcId() const {
return vpcId_;
}
void CreateLoadBalancerRequest::setVpcId(const std::string &vpcId) {
vpcId_ = vpcId;
setBodyParameter(std::string("VpcId"), vpcId);
}

View File

@@ -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 <alibabacloud/gwlb/model/CreateLoadBalancerResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
CreateLoadBalancerResult::CreateLoadBalancerResult() :
ServiceResult()
{}
CreateLoadBalancerResult::CreateLoadBalancerResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
CreateLoadBalancerResult::~CreateLoadBalancerResult()
{}
void CreateLoadBalancerResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["LoadBalancerId"].isNull())
loadBalancerId_ = value["LoadBalancerId"].asString();
}
std::string CreateLoadBalancerResult::getLoadBalancerId()const
{
return loadBalancerId_;
}

View File

@@ -0,0 +1,141 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/CreateServerGroupRequest.h>
using AlibabaCloud::Gwlb::Model::CreateServerGroupRequest;
CreateServerGroupRequest::CreateServerGroupRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "CreateServerGroup") {
setMethod(HttpRequest::Method::Post);
}
CreateServerGroupRequest::~CreateServerGroupRequest() {}
std::string CreateServerGroupRequest::getServerGroupName() const {
return serverGroupName_;
}
void CreateServerGroupRequest::setServerGroupName(const std::string &serverGroupName) {
serverGroupName_ = serverGroupName;
setBodyParameter(std::string("ServerGroupName"), serverGroupName);
}
std::string CreateServerGroupRequest::getClientToken() const {
return clientToken_;
}
void CreateServerGroupRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
CreateServerGroupRequest::HealthCheckConfig CreateServerGroupRequest::getHealthCheckConfig() const {
return healthCheckConfig_;
}
void CreateServerGroupRequest::setHealthCheckConfig(const CreateServerGroupRequest::HealthCheckConfig &healthCheckConfig) {
healthCheckConfig_ = healthCheckConfig;
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckConnectPort", std::to_string(healthCheckConfig.healthCheckConnectPort));
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckConnectTimeout", std::to_string(healthCheckConfig.healthCheckConnectTimeout));
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckDomain", healthCheckConfig.healthCheckDomain);
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckEnabled", healthCheckConfig.healthCheckEnabled ? "true" : "false");
for(int dep1 = 0; dep1 != healthCheckConfig.healthCheckHttpCode.size(); dep1++) {
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckHttpCode." + std::to_string(dep1 + 1), healthCheckConfig.healthCheckHttpCode[dep1]);
}
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckInterval", std::to_string(healthCheckConfig.healthCheckInterval));
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckPath", healthCheckConfig.healthCheckPath);
setBodyParameter(std::string("HealthCheckConfig") + ".HealthCheckProtocol", healthCheckConfig.healthCheckProtocol);
setBodyParameter(std::string("HealthCheckConfig") + ".HealthyThreshold", std::to_string(healthCheckConfig.healthyThreshold));
setBodyParameter(std::string("HealthCheckConfig") + ".UnhealthyThreshold", std::to_string(healthCheckConfig.unhealthyThreshold));
}
std::string CreateServerGroupRequest::getScheduler() const {
return scheduler_;
}
void CreateServerGroupRequest::setScheduler(const std::string &scheduler) {
scheduler_ = scheduler;
setBodyParameter(std::string("Scheduler"), scheduler);
}
std::string CreateServerGroupRequest::getResourceGroupId() const {
return resourceGroupId_;
}
void CreateServerGroupRequest::setResourceGroupId(const std::string &resourceGroupId) {
resourceGroupId_ = resourceGroupId;
setBodyParameter(std::string("ResourceGroupId"), resourceGroupId);
}
std::string CreateServerGroupRequest::getProtocol() const {
return protocol_;
}
void CreateServerGroupRequest::setProtocol(const std::string &protocol) {
protocol_ = protocol;
setBodyParameter(std::string("Protocol"), protocol);
}
std::vector<CreateServerGroupRequest::Tag> CreateServerGroupRequest::getTag() const {
return tag_;
}
void CreateServerGroupRequest::setTag(const std::vector<CreateServerGroupRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
bool CreateServerGroupRequest::getDryRun() const {
return dryRun_;
}
void CreateServerGroupRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
CreateServerGroupRequest::ConnectionDrainConfig CreateServerGroupRequest::getConnectionDrainConfig() const {
return connectionDrainConfig_;
}
void CreateServerGroupRequest::setConnectionDrainConfig(const CreateServerGroupRequest::ConnectionDrainConfig &connectionDrainConfig) {
connectionDrainConfig_ = connectionDrainConfig;
setBodyParameter(std::string("ConnectionDrainConfig") + ".ConnectionDrainEnabled", connectionDrainConfig.connectionDrainEnabled ? "true" : "false");
setBodyParameter(std::string("ConnectionDrainConfig") + ".ConnectionDrainTimeout", std::to_string(connectionDrainConfig.connectionDrainTimeout));
}
std::string CreateServerGroupRequest::getServerGroupType() const {
return serverGroupType_;
}
void CreateServerGroupRequest::setServerGroupType(const std::string &serverGroupType) {
serverGroupType_ = serverGroupType;
setBodyParameter(std::string("ServerGroupType"), serverGroupType);
}
std::string CreateServerGroupRequest::getVpcId() const {
return vpcId_;
}
void CreateServerGroupRequest::setVpcId(const std::string &vpcId) {
vpcId_ = vpcId;
setBodyParameter(std::string("VpcId"), vpcId);
}

View File

@@ -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 <alibabacloud/gwlb/model/CreateServerGroupResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
CreateServerGroupResult::CreateServerGroupResult() :
ServiceResult()
{}
CreateServerGroupResult::CreateServerGroupResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
CreateServerGroupResult::~CreateServerGroupResult()
{}
void CreateServerGroupResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["ServerGroupId"].isNull())
serverGroupId_ = value["ServerGroupId"].asString();
}
std::string CreateServerGroupResult::getServerGroupId()const
{
return serverGroupId_;
}

View File

@@ -0,0 +1,54 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/DeleteListenerRequest.h>
using AlibabaCloud::Gwlb::Model::DeleteListenerRequest;
DeleteListenerRequest::DeleteListenerRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "DeleteListener") {
setMethod(HttpRequest::Method::Post);
}
DeleteListenerRequest::~DeleteListenerRequest() {}
std::string DeleteListenerRequest::getClientToken() const {
return clientToken_;
}
void DeleteListenerRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string DeleteListenerRequest::getListenerId() const {
return listenerId_;
}
void DeleteListenerRequest::setListenerId(const std::string &listenerId) {
listenerId_ = listenerId;
setBodyParameter(std::string("ListenerId"), listenerId);
}
bool DeleteListenerRequest::getDryRun() const {
return dryRun_;
}
void DeleteListenerRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/DeleteListenerResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
DeleteListenerResult::DeleteListenerResult() :
ServiceResult()
{}
DeleteListenerResult::DeleteListenerResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DeleteListenerResult::~DeleteListenerResult()
{}
void DeleteListenerResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -0,0 +1,54 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/DeleteLoadBalancerRequest.h>
using AlibabaCloud::Gwlb::Model::DeleteLoadBalancerRequest;
DeleteLoadBalancerRequest::DeleteLoadBalancerRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "DeleteLoadBalancer") {
setMethod(HttpRequest::Method::Post);
}
DeleteLoadBalancerRequest::~DeleteLoadBalancerRequest() {}
std::string DeleteLoadBalancerRequest::getClientToken() const {
return clientToken_;
}
void DeleteLoadBalancerRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
bool DeleteLoadBalancerRequest::getDryRun() const {
return dryRun_;
}
void DeleteLoadBalancerRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::string DeleteLoadBalancerRequest::getLoadBalancerId() const {
return loadBalancerId_;
}
void DeleteLoadBalancerRequest::setLoadBalancerId(const std::string &loadBalancerId) {
loadBalancerId_ = loadBalancerId;
setBodyParameter(std::string("LoadBalancerId"), loadBalancerId);
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/DeleteLoadBalancerResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
DeleteLoadBalancerResult::DeleteLoadBalancerResult() :
ServiceResult()
{}
DeleteLoadBalancerResult::DeleteLoadBalancerResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DeleteLoadBalancerResult::~DeleteLoadBalancerResult()
{}
void DeleteLoadBalancerResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -0,0 +1,54 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/DeleteServerGroupRequest.h>
using AlibabaCloud::Gwlb::Model::DeleteServerGroupRequest;
DeleteServerGroupRequest::DeleteServerGroupRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "DeleteServerGroup") {
setMethod(HttpRequest::Method::Post);
}
DeleteServerGroupRequest::~DeleteServerGroupRequest() {}
std::string DeleteServerGroupRequest::getClientToken() const {
return clientToken_;
}
void DeleteServerGroupRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string DeleteServerGroupRequest::getServerGroupId() const {
return serverGroupId_;
}
void DeleteServerGroupRequest::setServerGroupId(const std::string &serverGroupId) {
serverGroupId_ = serverGroupId;
setBodyParameter(std::string("ServerGroupId"), serverGroupId);
}
bool DeleteServerGroupRequest::getDryRun() const {
return dryRun_;
}
void DeleteServerGroupRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/DeleteServerGroupResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
DeleteServerGroupResult::DeleteServerGroupResult() :
ServiceResult()
{}
DeleteServerGroupResult::DeleteServerGroupResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DeleteServerGroupResult::~DeleteServerGroupResult()
{}
void DeleteServerGroupResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -0,0 +1,36 @@
/*
* 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 <alibabacloud/gwlb/model/DescribeRegionsRequest.h>
using AlibabaCloud::Gwlb::Model::DescribeRegionsRequest;
DescribeRegionsRequest::DescribeRegionsRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "DescribeRegions") {
setMethod(HttpRequest::Method::Post);
}
DescribeRegionsRequest::~DescribeRegionsRequest() {}
std::string DescribeRegionsRequest::getAcceptLanguage() const {
return acceptLanguage_;
}
void DescribeRegionsRequest::setAcceptLanguage(const std::string &acceptLanguage) {
acceptLanguage_ = acceptLanguage;
setBodyParameter(std::string("AcceptLanguage"), acceptLanguage);
}

View File

@@ -0,0 +1,61 @@
/*
* 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 <alibabacloud/gwlb/model/DescribeRegionsResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::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"]["Data"];
for (auto valueRegionsData : allRegionsNode)
{
Data regionsObject;
if(!valueRegionsData["LocalName"].isNull())
regionsObject.localName = valueRegionsData["LocalName"].asString();
if(!valueRegionsData["RegionEndpoint"].isNull())
regionsObject.regionEndpoint = valueRegionsData["RegionEndpoint"].asString();
if(!valueRegionsData["RegionId"].isNull())
regionsObject.regionId = valueRegionsData["RegionId"].asString();
regions_.push_back(regionsObject);
}
}
std::vector<DescribeRegionsResult::Data> DescribeRegionsResult::getRegions()const
{
return regions_;
}

View File

@@ -0,0 +1,36 @@
/*
* 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 <alibabacloud/gwlb/model/DescribeZonesRequest.h>
using AlibabaCloud::Gwlb::Model::DescribeZonesRequest;
DescribeZonesRequest::DescribeZonesRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "DescribeZones") {
setMethod(HttpRequest::Method::Post);
}
DescribeZonesRequest::~DescribeZonesRequest() {}
std::string DescribeZonesRequest::getAcceptLanguage() const {
return acceptLanguage_;
}
void DescribeZonesRequest::setAcceptLanguage(const std::string &acceptLanguage) {
acceptLanguage_ = acceptLanguage;
setBodyParameter(std::string("AcceptLanguage"), acceptLanguage);
}

View File

@@ -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.
*/
#include <alibabacloud/gwlb/model/DescribeZonesResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
DescribeZonesResult::DescribeZonesResult() :
ServiceResult()
{}
DescribeZonesResult::DescribeZonesResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeZonesResult::~DescribeZonesResult()
{}
void DescribeZonesResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allZonesNode = value["Zones"]["Data"];
for (auto valueZonesData : allZonesNode)
{
Data zonesObject;
if(!valueZonesData["LocalName"].isNull())
zonesObject.localName = valueZonesData["LocalName"].asString();
if(!valueZonesData["ZoneId"].isNull())
zonesObject.zoneId = valueZonesData["ZoneId"].asString();
zones_.push_back(zonesObject);
}
}
std::vector<DescribeZonesResult::Data> DescribeZonesResult::getZones()const
{
return zones_;
}

View File

@@ -0,0 +1,36 @@
/*
* 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 <alibabacloud/gwlb/model/GetListenerAttributeRequest.h>
using AlibabaCloud::Gwlb::Model::GetListenerAttributeRequest;
GetListenerAttributeRequest::GetListenerAttributeRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "GetListenerAttribute") {
setMethod(HttpRequest::Method::Post);
}
GetListenerAttributeRequest::~GetListenerAttributeRequest() {}
std::string GetListenerAttributeRequest::getListenerId() const {
return listenerId_;
}
void GetListenerAttributeRequest::setListenerId(const std::string &listenerId) {
listenerId_ = listenerId;
setBodyParameter(std::string("ListenerId"), listenerId);
}

View File

@@ -0,0 +1,101 @@
/*
* 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 <alibabacloud/gwlb/model/GetListenerAttributeResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
GetListenerAttributeResult::GetListenerAttributeResult() :
ServiceResult()
{}
GetListenerAttributeResult::GetListenerAttributeResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
GetListenerAttributeResult::~GetListenerAttributeResult()
{}
void GetListenerAttributeResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allTagsNode = value["Tags"]["TagModel"];
for (auto valueTagsTagModel : allTagsNode)
{
TagModel tagsObject;
if(!valueTagsTagModel["Key"].isNull())
tagsObject.key = valueTagsTagModel["Key"].asString();
if(!valueTagsTagModel["Value"].isNull())
tagsObject.value = valueTagsTagModel["Value"].asString();
tags_.push_back(tagsObject);
}
if(!value["ListenerDescription"].isNull())
listenerDescription_ = value["ListenerDescription"].asString();
if(!value["ListenerId"].isNull())
listenerId_ = value["ListenerId"].asString();
if(!value["ListenerStatus"].isNull())
listenerStatus_ = value["ListenerStatus"].asString();
if(!value["LoadBalancerId"].isNull())
loadBalancerId_ = value["LoadBalancerId"].asString();
if(!value["RegionId"].isNull())
regionId_ = value["RegionId"].asString();
if(!value["ServerGroupId"].isNull())
serverGroupId_ = value["ServerGroupId"].asString();
}
std::string GetListenerAttributeResult::getListenerStatus()const
{
return listenerStatus_;
}
std::string GetListenerAttributeResult::getListenerDescription()const
{
return listenerDescription_;
}
std::string GetListenerAttributeResult::getServerGroupId()const
{
return serverGroupId_;
}
std::string GetListenerAttributeResult::getLoadBalancerId()const
{
return loadBalancerId_;
}
std::string GetListenerAttributeResult::getRegionId()const
{
return regionId_;
}
std::vector<GetListenerAttributeResult::TagModel> GetListenerAttributeResult::getTags()const
{
return tags_;
}
std::string GetListenerAttributeResult::getListenerId()const
{
return listenerId_;
}

View File

@@ -0,0 +1,77 @@
/*
* 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 <alibabacloud/gwlb/model/GetListenerHealthStatusRequest.h>
using AlibabaCloud::Gwlb::Model::GetListenerHealthStatusRequest;
GetListenerHealthStatusRequest::GetListenerHealthStatusRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "GetListenerHealthStatus") {
setMethod(HttpRequest::Method::Post);
}
GetListenerHealthStatusRequest::~GetListenerHealthStatusRequest() {}
int GetListenerHealthStatusRequest::getSkip() const {
return skip_;
}
void GetListenerHealthStatusRequest::setSkip(int skip) {
skip_ = skip;
setBodyParameter(std::string("Skip"), std::to_string(skip));
}
std::string GetListenerHealthStatusRequest::getListenerId() const {
return listenerId_;
}
void GetListenerHealthStatusRequest::setListenerId(const std::string &listenerId) {
listenerId_ = listenerId;
setBodyParameter(std::string("ListenerId"), listenerId);
}
std::string GetListenerHealthStatusRequest::getNextToken() const {
return nextToken_;
}
void GetListenerHealthStatusRequest::setNextToken(const std::string &nextToken) {
nextToken_ = nextToken;
setBodyParameter(std::string("NextToken"), nextToken);
}
std::vector<GetListenerHealthStatusRequest::Filter> GetListenerHealthStatusRequest::getFilter() const {
return filter_;
}
void GetListenerHealthStatusRequest::setFilter(const std::vector<GetListenerHealthStatusRequest::Filter> &filter) {
filter_ = filter;
for(int dep1 = 0; dep1 != filter.size(); dep1++) {
setBodyParameter(std::string("Filter") + "." + std::to_string(dep1 + 1) + ".Name", filter[dep1].name);
for(int dep2 = 0; dep2 != filter[dep1].values.size(); dep2++) {
setBodyParameter(std::string("Filter") + "." + std::to_string(dep1 + 1) + ".Values." + std::to_string(dep2 + 1), filter[dep1].values[dep2]);
}
}
}
int GetListenerHealthStatusRequest::getMaxResults() const {
return maxResults_;
}
void GetListenerHealthStatusRequest::setMaxResults(int maxResults) {
maxResults_ = maxResults;
setBodyParameter(std::string("MaxResults"), std::to_string(maxResults));
}

View File

@@ -0,0 +1,105 @@
/*
* 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 <alibabacloud/gwlb/model/GetListenerHealthStatusResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
GetListenerHealthStatusResult::GetListenerHealthStatusResult() :
ServiceResult()
{}
GetListenerHealthStatusResult::GetListenerHealthStatusResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
GetListenerHealthStatusResult::~GetListenerHealthStatusResult()
{}
void GetListenerHealthStatusResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allListenerHealthStatusNode = value["ListenerHealthStatus"]["listenerHealthStatusItem"];
for (auto valueListenerHealthStatuslistenerHealthStatusItem : allListenerHealthStatusNode)
{
ListenerHealthStatusItem listenerHealthStatusObject;
if(!valueListenerHealthStatuslistenerHealthStatusItem["ListenerId"].isNull())
listenerHealthStatusObject.listenerId = valueListenerHealthStatuslistenerHealthStatusItem["ListenerId"].asString();
auto allServerGroupInfosNode = valueListenerHealthStatuslistenerHealthStatusItem["ServerGroupInfos"]["ServerGroupInfo"];
for (auto valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfo : allServerGroupInfosNode)
{
ListenerHealthStatusItem::ServerGroupInfo serverGroupInfosObject;
if(!valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfo["HealthCheckEnabled"].isNull())
serverGroupInfosObject.healthCheckEnabled = valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfo["HealthCheckEnabled"].asString() == "true";
if(!valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfo["ServerGroupId"].isNull())
serverGroupInfosObject.serverGroupId = valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfo["ServerGroupId"].asString();
auto allServersNode = valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfo["Servers"]["server"];
for (auto valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver : allServersNode)
{
ListenerHealthStatusItem::ServerGroupInfo::Server serversObject;
if(!valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["Port"].isNull())
serversObject.port = std::stoi(valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["Port"].asString());
if(!valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["ServerId"].isNull())
serversObject.serverId = valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["ServerId"].asString();
if(!valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["ServerIp"].isNull())
serversObject.serverIp = valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["ServerIp"].asString();
if(!valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["Status"].isNull())
serversObject.status = valueListenerHealthStatuslistenerHealthStatusItemServerGroupInfosServerGroupInfoServersserver["Status"].asString();
auto reasonNode = value["Reason"];
if(!reasonNode["ReasonCode"].isNull())
serversObject.reason.reasonCode = reasonNode["ReasonCode"].asString();
serverGroupInfosObject.servers.push_back(serversObject);
}
listenerHealthStatusObject.serverGroupInfos.push_back(serverGroupInfosObject);
}
listenerHealthStatus_.push_back(listenerHealthStatusObject);
}
if(!value["MaxResults"].isNull())
maxResults_ = std::stoi(value["MaxResults"].asString());
if(!value["NextToken"].isNull())
nextToken_ = value["NextToken"].asString();
if(!value["TotalCount"].isNull())
totalCount_ = std::stoi(value["TotalCount"].asString());
}
std::vector<GetListenerHealthStatusResult::ListenerHealthStatusItem> GetListenerHealthStatusResult::getListenerHealthStatus()const
{
return listenerHealthStatus_;
}
int GetListenerHealthStatusResult::getTotalCount()const
{
return totalCount_;
}
std::string GetListenerHealthStatusResult::getNextToken()const
{
return nextToken_;
}
int GetListenerHealthStatusResult::getMaxResults()const
{
return maxResults_;
}

View File

@@ -0,0 +1,36 @@
/*
* 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 <alibabacloud/gwlb/model/GetLoadBalancerAttributeRequest.h>
using AlibabaCloud::Gwlb::Model::GetLoadBalancerAttributeRequest;
GetLoadBalancerAttributeRequest::GetLoadBalancerAttributeRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "GetLoadBalancerAttribute") {
setMethod(HttpRequest::Method::Post);
}
GetLoadBalancerAttributeRequest::~GetLoadBalancerAttributeRequest() {}
std::string GetLoadBalancerAttributeRequest::getLoadBalancerId() const {
return loadBalancerId_;
}
void GetLoadBalancerAttributeRequest::setLoadBalancerId(const std::string &loadBalancerId) {
loadBalancerId_ = loadBalancerId;
setBodyParameter(std::string("LoadBalancerId"), loadBalancerId);
}

View File

@@ -0,0 +1,147 @@
/*
* 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 <alibabacloud/gwlb/model/GetLoadBalancerAttributeResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
GetLoadBalancerAttributeResult::GetLoadBalancerAttributeResult() :
ServiceResult()
{}
GetLoadBalancerAttributeResult::GetLoadBalancerAttributeResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
GetLoadBalancerAttributeResult::~GetLoadBalancerAttributeResult()
{}
void GetLoadBalancerAttributeResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allTagsNode = value["Tags"]["TagModel"];
for (auto valueTagsTagModel : allTagsNode)
{
TagModel tagsObject;
if(!valueTagsTagModel["Key"].isNull())
tagsObject.key = valueTagsTagModel["Key"].asString();
if(!valueTagsTagModel["Value"].isNull())
tagsObject.value = valueTagsTagModel["Value"].asString();
tags_.push_back(tagsObject);
}
auto allZoneMappingsNode = value["ZoneMappings"]["ZoneEniModel"];
for (auto valueZoneMappingsZoneEniModel : allZoneMappingsNode)
{
ZoneEniModel zoneMappingsObject;
if(!valueZoneMappingsZoneEniModel["VSwitchId"].isNull())
zoneMappingsObject.vSwitchId = valueZoneMappingsZoneEniModel["VSwitchId"].asString();
if(!valueZoneMappingsZoneEniModel["ZoneId"].isNull())
zoneMappingsObject.zoneId = valueZoneMappingsZoneEniModel["ZoneId"].asString();
auto allLoadBalancerAddressesNode = valueZoneMappingsZoneEniModel["LoadBalancerAddresses"]["EniModels"];
for (auto valueZoneMappingsZoneEniModelLoadBalancerAddressesEniModels : allLoadBalancerAddressesNode)
{
ZoneEniModel::EniModels loadBalancerAddressesObject;
if(!valueZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["EniId"].isNull())
loadBalancerAddressesObject.eniId = valueZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["EniId"].asString();
if(!valueZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["PrivateIpv4Address"].isNull())
loadBalancerAddressesObject.privateIpv4Address = valueZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["PrivateIpv4Address"].asString();
zoneMappingsObject.loadBalancerAddresses.push_back(loadBalancerAddressesObject);
}
zoneMappings_.push_back(zoneMappingsObject);
}
if(!value["AddressIpVersion"].isNull())
addressIpVersion_ = value["AddressIpVersion"].asString();
if(!value["CreateTime"].isNull())
createTime_ = value["CreateTime"].asString();
if(!value["CrossZoneEnabled"].isNull())
crossZoneEnabled_ = value["CrossZoneEnabled"].asString() == "true";
if(!value["LoadBalancerBusinessStatus"].isNull())
loadBalancerBusinessStatus_ = value["LoadBalancerBusinessStatus"].asString();
if(!value["LoadBalancerId"].isNull())
loadBalancerId_ = value["LoadBalancerId"].asString();
if(!value["LoadBalancerName"].isNull())
loadBalancerName_ = value["LoadBalancerName"].asString();
if(!value["LoadBalancerStatus"].isNull())
loadBalancerStatus_ = value["LoadBalancerStatus"].asString();
if(!value["ResourceGroupId"].isNull())
resourceGroupId_ = value["ResourceGroupId"].asString();
if(!value["VpcId"].isNull())
vpcId_ = value["VpcId"].asString();
}
std::string GetLoadBalancerAttributeResult::getLoadBalancerName()const
{
return loadBalancerName_;
}
std::string GetLoadBalancerAttributeResult::getAddressIpVersion()const
{
return addressIpVersion_;
}
std::string GetLoadBalancerAttributeResult::getResourceGroupId()const
{
return resourceGroupId_;
}
std::string GetLoadBalancerAttributeResult::getVpcId()const
{
return vpcId_;
}
std::string GetLoadBalancerAttributeResult::getCreateTime()const
{
return createTime_;
}
std::string GetLoadBalancerAttributeResult::getLoadBalancerId()const
{
return loadBalancerId_;
}
std::vector<GetLoadBalancerAttributeResult::ZoneEniModel> GetLoadBalancerAttributeResult::getZoneMappings()const
{
return zoneMappings_;
}
std::string GetLoadBalancerAttributeResult::getLoadBalancerBusinessStatus()const
{
return loadBalancerBusinessStatus_;
}
std::string GetLoadBalancerAttributeResult::getLoadBalancerStatus()const
{
return loadBalancerStatus_;
}
std::vector<GetLoadBalancerAttributeResult::TagModel> GetLoadBalancerAttributeResult::getTags()const
{
return tags_;
}
bool GetLoadBalancerAttributeResult::getCrossZoneEnabled()const
{
return crossZoneEnabled_;
}

View File

@@ -0,0 +1,88 @@
/*
* 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 <alibabacloud/gwlb/model/ListListenersRequest.h>
using AlibabaCloud::Gwlb::Model::ListListenersRequest;
ListListenersRequest::ListListenersRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "ListListeners") {
setMethod(HttpRequest::Method::Post);
}
ListListenersRequest::~ListListenersRequest() {}
std::vector<ListListenersRequest::std::string> ListListenersRequest::getLoadBalancerIds() const {
return loadBalancerIds_;
}
void ListListenersRequest::setLoadBalancerIds(const std::vector<ListListenersRequest::std::string> &loadBalancerIds) {
loadBalancerIds_ = loadBalancerIds;
for(int dep1 = 0; dep1 != loadBalancerIds.size(); dep1++) {
setBodyParameter(std::string("LoadBalancerIds") + "." + std::to_string(dep1 + 1), loadBalancerIds[dep1]);
}
}
long ListListenersRequest::getSkip() const {
return skip_;
}
void ListListenersRequest::setSkip(long skip) {
skip_ = skip;
setBodyParameter(std::string("Skip"), std::to_string(skip));
}
std::string ListListenersRequest::getNextToken() const {
return nextToken_;
}
void ListListenersRequest::setNextToken(const std::string &nextToken) {
nextToken_ = nextToken;
setBodyParameter(std::string("NextToken"), nextToken);
}
std::vector<ListListenersRequest::Tag> ListListenersRequest::getTag() const {
return tag_;
}
void ListListenersRequest::setTag(const std::vector<ListListenersRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
std::vector<ListListenersRequest::std::string> ListListenersRequest::getListenerIds() const {
return listenerIds_;
}
void ListListenersRequest::setListenerIds(const std::vector<ListListenersRequest::std::string> &listenerIds) {
listenerIds_ = listenerIds;
for(int dep1 = 0; dep1 != listenerIds.size(); dep1++) {
setBodyParameter(std::string("ListenerIds") + "." + std::to_string(dep1 + 1), listenerIds[dep1]);
}
}
int ListListenersRequest::getMaxResults() const {
return maxResults_;
}
void ListListenersRequest::setMaxResults(int maxResults) {
maxResults_ = maxResults;
setBodyParameter(std::string("MaxResults"), std::to_string(maxResults));
}

View File

@@ -0,0 +1,96 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/ListListenersResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
ListListenersResult::ListListenersResult() :
ServiceResult()
{}
ListListenersResult::ListListenersResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListListenersResult::~ListListenersResult()
{}
void ListListenersResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allListenersNode = value["Listeners"]["listener"];
for (auto valueListenerslistener : allListenersNode)
{
Listener listenersObject;
if(!valueListenerslistener["ListenerDescription"].isNull())
listenersObject.listenerDescription = valueListenerslistener["ListenerDescription"].asString();
if(!valueListenerslistener["ListenerId"].isNull())
listenersObject.listenerId = valueListenerslistener["ListenerId"].asString();
if(!valueListenerslistener["ListenerStatus"].isNull())
listenersObject.listenerStatus = valueListenerslistener["ListenerStatus"].asString();
if(!valueListenerslistener["LoadBalancerId"].isNull())
listenersObject.loadBalancerId = valueListenerslistener["LoadBalancerId"].asString();
if(!valueListenerslistener["ServerGroupId"].isNull())
listenersObject.serverGroupId = valueListenerslistener["ServerGroupId"].asString();
auto allTagsNode = valueListenerslistener["Tags"]["TagModel"];
for (auto valueListenerslistenerTagsTagModel : allTagsNode)
{
Listener::TagModel tagsObject;
if(!valueListenerslistenerTagsTagModel["Key"].isNull())
tagsObject.key = valueListenerslistenerTagsTagModel["Key"].asString();
if(!valueListenerslistenerTagsTagModel["Value"].isNull())
tagsObject.value = valueListenerslistenerTagsTagModel["Value"].asString();
listenersObject.tags.push_back(tagsObject);
}
listeners_.push_back(listenersObject);
}
if(!value["MaxResults"].isNull())
maxResults_ = std::stoi(value["MaxResults"].asString());
if(!value["NextToken"].isNull())
nextToken_ = value["NextToken"].asString();
if(!value["TotalCount"].isNull())
totalCount_ = std::stoi(value["TotalCount"].asString());
}
std::vector<ListListenersResult::Listener> ListListenersResult::getListeners()const
{
return listeners_;
}
int ListListenersResult::getTotalCount()const
{
return totalCount_;
}
std::string ListListenersResult::getNextToken()const
{
return nextToken_;
}
int ListListenersResult::getMaxResults()const
{
return maxResults_;
}

View File

@@ -0,0 +1,146 @@
/*
* 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 <alibabacloud/gwlb/model/ListLoadBalancersRequest.h>
using AlibabaCloud::Gwlb::Model::ListLoadBalancersRequest;
ListLoadBalancersRequest::ListLoadBalancersRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "ListLoadBalancers") {
setMethod(HttpRequest::Method::Post);
}
ListLoadBalancersRequest::~ListLoadBalancersRequest() {}
std::vector<ListLoadBalancersRequest::std::string> ListLoadBalancersRequest::getLoadBalancerNames() const {
return loadBalancerNames_;
}
void ListLoadBalancersRequest::setLoadBalancerNames(const std::vector<ListLoadBalancersRequest::std::string> &loadBalancerNames) {
loadBalancerNames_ = loadBalancerNames;
for(int dep1 = 0; dep1 != loadBalancerNames.size(); dep1++) {
setBodyParameter(std::string("LoadBalancerNames") + "." + std::to_string(dep1 + 1), loadBalancerNames[dep1]);
}
}
std::vector<ListLoadBalancersRequest::std::string> ListLoadBalancersRequest::getLoadBalancerIds() const {
return loadBalancerIds_;
}
void ListLoadBalancersRequest::setLoadBalancerIds(const std::vector<ListLoadBalancersRequest::std::string> &loadBalancerIds) {
loadBalancerIds_ = loadBalancerIds;
for(int dep1 = 0; dep1 != loadBalancerIds.size(); dep1++) {
setBodyParameter(std::string("LoadBalancerIds") + "." + std::to_string(dep1 + 1), loadBalancerIds[dep1]);
}
}
int ListLoadBalancersRequest::getSkip() const {
return skip_;
}
void ListLoadBalancersRequest::setSkip(int skip) {
skip_ = skip;
setBodyParameter(std::string("Skip"), std::to_string(skip));
}
std::string ListLoadBalancersRequest::getAddressIpVersion() const {
return addressIpVersion_;
}
void ListLoadBalancersRequest::setAddressIpVersion(const std::string &addressIpVersion) {
addressIpVersion_ = addressIpVersion;
setBodyParameter(std::string("AddressIpVersion"), addressIpVersion);
}
std::string ListLoadBalancersRequest::getResourceGroupId() const {
return resourceGroupId_;
}
void ListLoadBalancersRequest::setResourceGroupId(const std::string &resourceGroupId) {
resourceGroupId_ = resourceGroupId;
setBodyParameter(std::string("ResourceGroupId"), resourceGroupId);
}
std::vector<ListLoadBalancersRequest::std::string> ListLoadBalancersRequest::getZoneIds() const {
return zoneIds_;
}
void ListLoadBalancersRequest::setZoneIds(const std::vector<ListLoadBalancersRequest::std::string> &zoneIds) {
zoneIds_ = zoneIds;
for(int dep1 = 0; dep1 != zoneIds.size(); dep1++) {
setBodyParameter(std::string("ZoneIds") + "." + std::to_string(dep1 + 1), zoneIds[dep1]);
}
}
std::string ListLoadBalancersRequest::getNextToken() const {
return nextToken_;
}
void ListLoadBalancersRequest::setNextToken(const std::string &nextToken) {
nextToken_ = nextToken;
setBodyParameter(std::string("NextToken"), nextToken);
}
std::vector<ListLoadBalancersRequest::std::string> ListLoadBalancersRequest::getVpcIds() const {
return vpcIds_;
}
void ListLoadBalancersRequest::setVpcIds(const std::vector<ListLoadBalancersRequest::std::string> &vpcIds) {
vpcIds_ = vpcIds;
for(int dep1 = 0; dep1 != vpcIds.size(); dep1++) {
setBodyParameter(std::string("VpcIds") + "." + std::to_string(dep1 + 1), vpcIds[dep1]);
}
}
std::vector<ListLoadBalancersRequest::Tag> ListLoadBalancersRequest::getTag() const {
return tag_;
}
void ListLoadBalancersRequest::setTag(const std::vector<ListLoadBalancersRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
std::string ListLoadBalancersRequest::getLoadBalancerBusinessStatus() const {
return loadBalancerBusinessStatus_;
}
void ListLoadBalancersRequest::setLoadBalancerBusinessStatus(const std::string &loadBalancerBusinessStatus) {
loadBalancerBusinessStatus_ = loadBalancerBusinessStatus;
setBodyParameter(std::string("LoadBalancerBusinessStatus"), loadBalancerBusinessStatus);
}
std::string ListLoadBalancersRequest::getLoadBalancerStatus() const {
return loadBalancerStatus_;
}
void ListLoadBalancersRequest::setLoadBalancerStatus(const std::string &loadBalancerStatus) {
loadBalancerStatus_ = loadBalancerStatus;
setBodyParameter(std::string("LoadBalancerStatus"), loadBalancerStatus);
}
int ListLoadBalancersRequest::getMaxResults() const {
return maxResults_;
}
void ListLoadBalancersRequest::setMaxResults(int maxResults) {
maxResults_ = maxResults;
setBodyParameter(std::string("MaxResults"), std::to_string(maxResults));
}

View File

@@ -0,0 +1,124 @@
/*
* 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 <alibabacloud/gwlb/model/ListLoadBalancersResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
ListLoadBalancersResult::ListLoadBalancersResult() :
ServiceResult()
{}
ListLoadBalancersResult::ListLoadBalancersResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListLoadBalancersResult::~ListLoadBalancersResult()
{}
void ListLoadBalancersResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allLoadBalancersNode = value["LoadBalancers"]["Data"];
for (auto valueLoadBalancersData : allLoadBalancersNode)
{
Data loadBalancersObject;
if(!valueLoadBalancersData["AddressIpVersion"].isNull())
loadBalancersObject.addressIpVersion = valueLoadBalancersData["AddressIpVersion"].asString();
if(!valueLoadBalancersData["CreateTime"].isNull())
loadBalancersObject.createTime = valueLoadBalancersData["CreateTime"].asString();
if(!valueLoadBalancersData["CrossZoneEnabled"].isNull())
loadBalancersObject.crossZoneEnabled = valueLoadBalancersData["CrossZoneEnabled"].asString() == "true";
if(!valueLoadBalancersData["LoadBalancerBusinessStatus"].isNull())
loadBalancersObject.loadBalancerBusinessStatus = valueLoadBalancersData["LoadBalancerBusinessStatus"].asString();
if(!valueLoadBalancersData["LoadBalancerId"].isNull())
loadBalancersObject.loadBalancerId = valueLoadBalancersData["LoadBalancerId"].asString();
if(!valueLoadBalancersData["LoadBalancerName"].isNull())
loadBalancersObject.loadBalancerName = valueLoadBalancersData["LoadBalancerName"].asString();
if(!valueLoadBalancersData["LoadBalancerStatus"].isNull())
loadBalancersObject.loadBalancerStatus = valueLoadBalancersData["LoadBalancerStatus"].asString();
if(!valueLoadBalancersData["ResourceGroupId"].isNull())
loadBalancersObject.resourceGroupId = valueLoadBalancersData["ResourceGroupId"].asString();
if(!valueLoadBalancersData["VpcId"].isNull())
loadBalancersObject.vpcId = valueLoadBalancersData["VpcId"].asString();
auto allTagsNode = valueLoadBalancersData["Tags"]["TagModel"];
for (auto valueLoadBalancersDataTagsTagModel : allTagsNode)
{
Data::TagModel tagsObject;
if(!valueLoadBalancersDataTagsTagModel["Key"].isNull())
tagsObject.key = valueLoadBalancersDataTagsTagModel["Key"].asString();
if(!valueLoadBalancersDataTagsTagModel["Value"].isNull())
tagsObject.value = valueLoadBalancersDataTagsTagModel["Value"].asString();
loadBalancersObject.tags.push_back(tagsObject);
}
auto allZoneMappingsNode = valueLoadBalancersData["ZoneMappings"]["ZoneEniModel"];
for (auto valueLoadBalancersDataZoneMappingsZoneEniModel : allZoneMappingsNode)
{
Data::ZoneEniModel zoneMappingsObject;
if(!valueLoadBalancersDataZoneMappingsZoneEniModel["VSwitchId"].isNull())
zoneMappingsObject.vSwitchId = valueLoadBalancersDataZoneMappingsZoneEniModel["VSwitchId"].asString();
if(!valueLoadBalancersDataZoneMappingsZoneEniModel["ZoneId"].isNull())
zoneMappingsObject.zoneId = valueLoadBalancersDataZoneMappingsZoneEniModel["ZoneId"].asString();
auto allLoadBalancerAddressesNode = valueLoadBalancersDataZoneMappingsZoneEniModel["LoadBalancerAddresses"]["EniModels"];
for (auto valueLoadBalancersDataZoneMappingsZoneEniModelLoadBalancerAddressesEniModels : allLoadBalancerAddressesNode)
{
Data::ZoneEniModel::EniModels loadBalancerAddressesObject;
if(!valueLoadBalancersDataZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["EniId"].isNull())
loadBalancerAddressesObject.eniId = valueLoadBalancersDataZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["EniId"].asString();
if(!valueLoadBalancersDataZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["PrivateIpv4Address"].isNull())
loadBalancerAddressesObject.privateIpv4Address = valueLoadBalancersDataZoneMappingsZoneEniModelLoadBalancerAddressesEniModels["PrivateIpv4Address"].asString();
zoneMappingsObject.loadBalancerAddresses.push_back(loadBalancerAddressesObject);
}
loadBalancersObject.zoneMappings.push_back(zoneMappingsObject);
}
loadBalancers_.push_back(loadBalancersObject);
}
if(!value["MaxResults"].isNull())
maxResults_ = std::stoi(value["MaxResults"].asString());
if(!value["NextToken"].isNull())
nextToken_ = value["NextToken"].asString();
if(!value["TotalCount"].isNull())
totalCount_ = std::stoi(value["TotalCount"].asString());
}
int ListLoadBalancersResult::getTotalCount()const
{
return totalCount_;
}
std::string ListLoadBalancersResult::getNextToken()const
{
return nextToken_;
}
int ListLoadBalancersResult::getMaxResults()const
{
return maxResults_;
}
std::vector<ListLoadBalancersResult::Data> ListLoadBalancersResult::getLoadBalancers()const
{
return loadBalancers_;
}

View File

@@ -0,0 +1,85 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/ListServerGroupServersRequest.h>
using AlibabaCloud::Gwlb::Model::ListServerGroupServersRequest;
ListServerGroupServersRequest::ListServerGroupServersRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "ListServerGroupServers") {
setMethod(HttpRequest::Method::Post);
}
ListServerGroupServersRequest::~ListServerGroupServersRequest() {}
int ListServerGroupServersRequest::getSkip() const {
return skip_;
}
void ListServerGroupServersRequest::setSkip(int skip) {
skip_ = skip;
setBodyParameter(std::string("Skip"), std::to_string(skip));
}
std::string ListServerGroupServersRequest::getServerGroupId() const {
return serverGroupId_;
}
void ListServerGroupServersRequest::setServerGroupId(const std::string &serverGroupId) {
serverGroupId_ = serverGroupId;
setBodyParameter(std::string("ServerGroupId"), serverGroupId);
}
std::string ListServerGroupServersRequest::getNextToken() const {
return nextToken_;
}
void ListServerGroupServersRequest::setNextToken(const std::string &nextToken) {
nextToken_ = nextToken;
setBodyParameter(std::string("NextToken"), nextToken);
}
std::vector<ListServerGroupServersRequest::std::string> ListServerGroupServersRequest::getServerIds() const {
return serverIds_;
}
void ListServerGroupServersRequest::setServerIds(const std::vector<ListServerGroupServersRequest::std::string> &serverIds) {
serverIds_ = serverIds;
for(int dep1 = 0; dep1 != serverIds.size(); dep1++) {
setBodyParameter(std::string("ServerIds") + "." + std::to_string(dep1 + 1), serverIds[dep1]);
}
}
std::vector<ListServerGroupServersRequest::std::string> ListServerGroupServersRequest::getServerIps() const {
return serverIps_;
}
void ListServerGroupServersRequest::setServerIps(const std::vector<ListServerGroupServersRequest::std::string> &serverIps) {
serverIps_ = serverIps;
for(int dep1 = 0; dep1 != serverIps.size(); dep1++) {
setBodyParameter(std::string("ServerIps") + "." + std::to_string(dep1 + 1), serverIps[dep1]);
}
}
int ListServerGroupServersRequest::getMaxResults() const {
return maxResults_;
}
void ListServerGroupServersRequest::setMaxResults(int maxResults) {
maxResults_ = maxResults;
setBodyParameter(std::string("MaxResults"), std::to_string(maxResults));
}

View File

@@ -0,0 +1,88 @@
/*
* 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 <alibabacloud/gwlb/model/ListServerGroupServersResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
ListServerGroupServersResult::ListServerGroupServersResult() :
ServiceResult()
{}
ListServerGroupServersResult::ListServerGroupServersResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListServerGroupServersResult::~ListServerGroupServersResult()
{}
void ListServerGroupServersResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allServersNode = value["Servers"]["Server"];
for (auto valueServersServer : allServersNode)
{
Server serversObject;
if(!valueServersServer["Port"].isNull())
serversObject.port = std::stoi(valueServersServer["Port"].asString());
if(!valueServersServer["ServerGroupId"].isNull())
serversObject.serverGroupId = valueServersServer["ServerGroupId"].asString();
if(!valueServersServer["ServerId"].isNull())
serversObject.serverId = valueServersServer["ServerId"].asString();
if(!valueServersServer["ServerIp"].isNull())
serversObject.serverIp = valueServersServer["ServerIp"].asString();
if(!valueServersServer["ServerType"].isNull())
serversObject.serverType = valueServersServer["ServerType"].asString();
if(!valueServersServer["Status"].isNull())
serversObject.status = valueServersServer["Status"].asString();
servers_.push_back(serversObject);
}
if(!value["MaxResults"].isNull())
maxResults_ = std::stoi(value["MaxResults"].asString());
if(!value["NextToken"].isNull())
nextToken_ = value["NextToken"].asString();
if(!value["TotalCount"].isNull())
totalCount_ = std::stoi(value["TotalCount"].asString());
}
int ListServerGroupServersResult::getTotalCount()const
{
return totalCount_;
}
std::string ListServerGroupServersResult::getNextToken()const
{
return nextToken_;
}
int ListServerGroupServersResult::getMaxResults()const
{
return maxResults_;
}
std::vector<ListServerGroupServersResult::Server> ListServerGroupServersResult::getServers()const
{
return servers_;
}

View File

@@ -0,0 +1,115 @@
/*
* 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 <alibabacloud/gwlb/model/ListServerGroupsRequest.h>
using AlibabaCloud::Gwlb::Model::ListServerGroupsRequest;
ListServerGroupsRequest::ListServerGroupsRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "ListServerGroups") {
setMethod(HttpRequest::Method::Post);
}
ListServerGroupsRequest::~ListServerGroupsRequest() {}
std::vector<ListServerGroupsRequest::std::string> ListServerGroupsRequest::getServerGroupNames() const {
return serverGroupNames_;
}
void ListServerGroupsRequest::setServerGroupNames(const std::vector<ListServerGroupsRequest::std::string> &serverGroupNames) {
serverGroupNames_ = serverGroupNames;
for(int dep1 = 0; dep1 != serverGroupNames.size(); dep1++) {
setBodyParameter(std::string("ServerGroupNames") + "." + std::to_string(dep1 + 1), serverGroupNames[dep1]);
}
}
int ListServerGroupsRequest::getSkip() const {
return skip_;
}
void ListServerGroupsRequest::setSkip(int skip) {
skip_ = skip;
setBodyParameter(std::string("Skip"), std::to_string(skip));
}
std::string ListServerGroupsRequest::getResourceGroupId() const {
return resourceGroupId_;
}
void ListServerGroupsRequest::setResourceGroupId(const std::string &resourceGroupId) {
resourceGroupId_ = resourceGroupId;
setBodyParameter(std::string("ResourceGroupId"), resourceGroupId);
}
std::string ListServerGroupsRequest::getNextToken() const {
return nextToken_;
}
void ListServerGroupsRequest::setNextToken(const std::string &nextToken) {
nextToken_ = nextToken;
setBodyParameter(std::string("NextToken"), nextToken);
}
std::vector<ListServerGroupsRequest::Tag> ListServerGroupsRequest::getTag() const {
return tag_;
}
void ListServerGroupsRequest::setTag(const std::vector<ListServerGroupsRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
std::vector<ListServerGroupsRequest::std::string> ListServerGroupsRequest::getServerGroupIds() const {
return serverGroupIds_;
}
void ListServerGroupsRequest::setServerGroupIds(const std::vector<ListServerGroupsRequest::std::string> &serverGroupIds) {
serverGroupIds_ = serverGroupIds;
for(int dep1 = 0; dep1 != serverGroupIds.size(); dep1++) {
setBodyParameter(std::string("ServerGroupIds") + "." + std::to_string(dep1 + 1), serverGroupIds[dep1]);
}
}
std::string ListServerGroupsRequest::getServerGroupType() const {
return serverGroupType_;
}
void ListServerGroupsRequest::setServerGroupType(const std::string &serverGroupType) {
serverGroupType_ = serverGroupType;
setBodyParameter(std::string("ServerGroupType"), serverGroupType);
}
std::string ListServerGroupsRequest::getVpcId() const {
return vpcId_;
}
void ListServerGroupsRequest::setVpcId(const std::string &vpcId) {
vpcId_ = vpcId;
setBodyParameter(std::string("VpcId"), vpcId);
}
int ListServerGroupsRequest::getMaxResults() const {
return maxResults_;
}
void ListServerGroupsRequest::setMaxResults(int maxResults) {
maxResults_ = maxResults;
setBodyParameter(std::string("MaxResults"), std::to_string(maxResults));
}

View File

@@ -0,0 +1,136 @@
/*
* 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 <alibabacloud/gwlb/model/ListServerGroupsResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
ListServerGroupsResult::ListServerGroupsResult() :
ServiceResult()
{}
ListServerGroupsResult::ListServerGroupsResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListServerGroupsResult::~ListServerGroupsResult()
{}
void ListServerGroupsResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allServerGroupsNode = value["ServerGroups"]["serverGroup"];
for (auto valueServerGroupsserverGroup : allServerGroupsNode)
{
ServerGroup serverGroupsObject;
if(!valueServerGroupsserverGroup["CreateTime"].isNull())
serverGroupsObject.createTime = valueServerGroupsserverGroup["CreateTime"].asString();
if(!valueServerGroupsserverGroup["Protocol"].isNull())
serverGroupsObject.protocol = valueServerGroupsserverGroup["Protocol"].asString();
if(!valueServerGroupsserverGroup["ResourceGroupId"].isNull())
serverGroupsObject.resourceGroupId = valueServerGroupsserverGroup["ResourceGroupId"].asString();
if(!valueServerGroupsserverGroup["Scheduler"].isNull())
serverGroupsObject.scheduler = valueServerGroupsserverGroup["Scheduler"].asString();
if(!valueServerGroupsserverGroup["ServerCount"].isNull())
serverGroupsObject.serverCount = std::stoi(valueServerGroupsserverGroup["ServerCount"].asString());
if(!valueServerGroupsserverGroup["ServerGroupId"].isNull())
serverGroupsObject.serverGroupId = valueServerGroupsserverGroup["ServerGroupId"].asString();
if(!valueServerGroupsserverGroup["ServerGroupName"].isNull())
serverGroupsObject.serverGroupName = valueServerGroupsserverGroup["ServerGroupName"].asString();
if(!valueServerGroupsserverGroup["ServerGroupStatus"].isNull())
serverGroupsObject.serverGroupStatus = valueServerGroupsserverGroup["ServerGroupStatus"].asString();
if(!valueServerGroupsserverGroup["ServerGroupType"].isNull())
serverGroupsObject.serverGroupType = valueServerGroupsserverGroup["ServerGroupType"].asString();
if(!valueServerGroupsserverGroup["VpcId"].isNull())
serverGroupsObject.vpcId = valueServerGroupsserverGroup["VpcId"].asString();
auto allTagsNode = valueServerGroupsserverGroup["Tags"]["TagModel"];
for (auto valueServerGroupsserverGroupTagsTagModel : allTagsNode)
{
ServerGroup::TagModel tagsObject;
if(!valueServerGroupsserverGroupTagsTagModel["Key"].isNull())
tagsObject.key = valueServerGroupsserverGroupTagsTagModel["Key"].asString();
if(!valueServerGroupsserverGroupTagsTagModel["Value"].isNull())
tagsObject.value = valueServerGroupsserverGroupTagsTagModel["Value"].asString();
serverGroupsObject.tags.push_back(tagsObject);
}
auto connectionDrainConfigNode = value["ConnectionDrainConfig"];
if(!connectionDrainConfigNode["ConnectionDrainEnabled"].isNull())
serverGroupsObject.connectionDrainConfig.connectionDrainEnabled = connectionDrainConfigNode["ConnectionDrainEnabled"].asString() == "true";
if(!connectionDrainConfigNode["ConnectionDrainTimeout"].isNull())
serverGroupsObject.connectionDrainConfig.connectionDrainTimeout = std::stoi(connectionDrainConfigNode["ConnectionDrainTimeout"].asString());
auto healthCheckConfigNode = value["HealthCheckConfig"];
if(!healthCheckConfigNode["HealthCheckConnectPort"].isNull())
serverGroupsObject.healthCheckConfig.healthCheckConnectPort = std::stoi(healthCheckConfigNode["HealthCheckConnectPort"].asString());
if(!healthCheckConfigNode["HealthCheckConnectTimeout"].isNull())
serverGroupsObject.healthCheckConfig.healthCheckConnectTimeout = std::stoi(healthCheckConfigNode["HealthCheckConnectTimeout"].asString());
if(!healthCheckConfigNode["HealthCheckDomain"].isNull())
serverGroupsObject.healthCheckConfig.healthCheckDomain = healthCheckConfigNode["HealthCheckDomain"].asString();
if(!healthCheckConfigNode["HealthCheckEnabled"].isNull())
serverGroupsObject.healthCheckConfig.healthCheckEnabled = healthCheckConfigNode["HealthCheckEnabled"].asString() == "true";
if(!healthCheckConfigNode["HealthCheckInterval"].isNull())
serverGroupsObject.healthCheckConfig.healthCheckInterval = std::stoi(healthCheckConfigNode["HealthCheckInterval"].asString());
if(!healthCheckConfigNode["HealthCheckPath"].isNull())
serverGroupsObject.healthCheckConfig.healthCheckPath = healthCheckConfigNode["HealthCheckPath"].asString();
if(!healthCheckConfigNode["HealthCheckProtocol"].isNull())
serverGroupsObject.healthCheckConfig.healthCheckProtocol = healthCheckConfigNode["HealthCheckProtocol"].asString();
if(!healthCheckConfigNode["HealthyThreshold"].isNull())
serverGroupsObject.healthCheckConfig.healthyThreshold = std::stoi(healthCheckConfigNode["HealthyThreshold"].asString());
if(!healthCheckConfigNode["UnhealthyThreshold"].isNull())
serverGroupsObject.healthCheckConfig.unhealthyThreshold = std::stoi(healthCheckConfigNode["UnhealthyThreshold"].asString());
auto allHealthCheckHttpCode = healthCheckConfigNode["HealthCheckHttpCode"]["HealthCheckHttpCode"];
for (auto value : allHealthCheckHttpCode)
serverGroupsObject.healthCheckConfig.healthCheckHttpCode.push_back(value.asString());
auto allRelatedLoadBalancerIds = value["RelatedLoadBalancerIds"]["LoadBalancerId"];
for (auto value : allRelatedLoadBalancerIds)
serverGroupsObject.relatedLoadBalancerIds.push_back(value.asString());
serverGroups_.push_back(serverGroupsObject);
}
if(!value["MaxResults"].isNull())
maxResults_ = std::stoi(value["MaxResults"].asString());
if(!value["NextToken"].isNull())
nextToken_ = value["NextToken"].asString();
if(!value["TotalCount"].isNull())
totalCount_ = std::stoi(value["TotalCount"].asString());
}
int ListServerGroupsResult::getTotalCount()const
{
return totalCount_;
}
std::string ListServerGroupsResult::getNextToken()const
{
return nextToken_;
}
std::vector<ListServerGroupsResult::ServerGroup> ListServerGroupsResult::getServerGroups()const
{
return serverGroups_;
}
int ListServerGroupsResult::getMaxResults()const
{
return maxResults_;
}

View File

@@ -0,0 +1,77 @@
/*
* 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 <alibabacloud/gwlb/model/ListTagResourcesRequest.h>
using AlibabaCloud::Gwlb::Model::ListTagResourcesRequest;
ListTagResourcesRequest::ListTagResourcesRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "ListTagResources") {
setMethod(HttpRequest::Method::Post);
}
ListTagResourcesRequest::~ListTagResourcesRequest() {}
std::string ListTagResourcesRequest::getNextToken() const {
return nextToken_;
}
void ListTagResourcesRequest::setNextToken(const std::string &nextToken) {
nextToken_ = nextToken;
setBodyParameter(std::string("NextToken"), nextToken);
}
std::vector<ListTagResourcesRequest::Tag> ListTagResourcesRequest::getTag() const {
return tag_;
}
void ListTagResourcesRequest::setTag(const std::vector<ListTagResourcesRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
std::vector<ListTagResourcesRequest::std::string> ListTagResourcesRequest::getResourceId() const {
return resourceId_;
}
void ListTagResourcesRequest::setResourceId(const std::vector<ListTagResourcesRequest::std::string> &resourceId) {
resourceId_ = resourceId;
for(int dep1 = 0; dep1 != resourceId.size(); dep1++) {
setBodyParameter(std::string("ResourceId") + "." + std::to_string(dep1 + 1), resourceId[dep1]);
}
}
std::string ListTagResourcesRequest::getResourceType() const {
return resourceType_;
}
void ListTagResourcesRequest::setResourceType(const std::string &resourceType) {
resourceType_ = resourceType;
setBodyParameter(std::string("ResourceType"), resourceType);
}
int ListTagResourcesRequest::getMaxResults() const {
return maxResults_;
}
void ListTagResourcesRequest::setMaxResults(int maxResults) {
maxResults_ = maxResults;
setBodyParameter(std::string("MaxResults"), std::to_string(maxResults));
}

View File

@@ -0,0 +1,70 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/ListTagResourcesResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
ListTagResourcesResult::ListTagResourcesResult() :
ServiceResult()
{}
ListTagResourcesResult::ListTagResourcesResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListTagResourcesResult::~ListTagResourcesResult()
{}
void ListTagResourcesResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allTagResourcesNode = value["TagResources"]["tagResource"];
for (auto valueTagResourcestagResource : allTagResourcesNode)
{
TagResource tagResourcesObject;
if(!valueTagResourcestagResource["ResourceId"].isNull())
tagResourcesObject.resourceId = valueTagResourcestagResource["ResourceId"].asString();
if(!valueTagResourcestagResource["ResourceType"].isNull())
tagResourcesObject.resourceType = valueTagResourcestagResource["ResourceType"].asString();
if(!valueTagResourcestagResource["TagKey"].isNull())
tagResourcesObject.tagKey = valueTagResourcestagResource["TagKey"].asString();
if(!valueTagResourcestagResource["TagValue"].isNull())
tagResourcesObject.tagValue = valueTagResourcestagResource["TagValue"].asString();
tagResources_.push_back(tagResourcesObject);
}
if(!value["NextToken"].isNull())
nextToken_ = value["NextToken"].asString();
}
std::string ListTagResourcesResult::getNextToken()const
{
return nextToken_;
}
std::vector<ListTagResourcesResult::TagResource> ListTagResourcesResult::getTagResources()const
{
return tagResources_;
}

View File

@@ -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 <alibabacloud/gwlb/model/MoveResourceGroupRequest.h>
using AlibabaCloud::Gwlb::Model::MoveResourceGroupRequest;
MoveResourceGroupRequest::MoveResourceGroupRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "MoveResourceGroup") {
setMethod(HttpRequest::Method::Post);
}
MoveResourceGroupRequest::~MoveResourceGroupRequest() {}
std::string MoveResourceGroupRequest::getClientToken() const {
return clientToken_;
}
void MoveResourceGroupRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string MoveResourceGroupRequest::getResourceId() const {
return resourceId_;
}
void MoveResourceGroupRequest::setResourceId(const std::string &resourceId) {
resourceId_ = resourceId;
setBodyParameter(std::string("ResourceId"), resourceId);
}
bool MoveResourceGroupRequest::getDryRun() const {
return dryRun_;
}
void MoveResourceGroupRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::string MoveResourceGroupRequest::getResourceType() const {
return resourceType_;
}
void MoveResourceGroupRequest::setResourceType(const std::string &resourceType) {
resourceType_ = resourceType;
setBodyParameter(std::string("ResourceType"), resourceType);
}
std::string MoveResourceGroupRequest::getNewResourceGroupId() const {
return newResourceGroupId_;
}
void MoveResourceGroupRequest::setNewResourceGroupId(const std::string &newResourceGroupId) {
newResourceGroupId_ = newResourceGroupId;
setBodyParameter(std::string("NewResourceGroupId"), newResourceGroupId);
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/MoveResourceGroupResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
MoveResourceGroupResult::MoveResourceGroupResult() :
ServiceResult()
{}
MoveResourceGroupResult::MoveResourceGroupResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
MoveResourceGroupResult::~MoveResourceGroupResult()
{}
void MoveResourceGroupResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -0,0 +1,68 @@
/*
* 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 <alibabacloud/gwlb/model/RemoveServersFromServerGroupRequest.h>
using AlibabaCloud::Gwlb::Model::RemoveServersFromServerGroupRequest;
RemoveServersFromServerGroupRequest::RemoveServersFromServerGroupRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "RemoveServersFromServerGroup") {
setMethod(HttpRequest::Method::Post);
}
RemoveServersFromServerGroupRequest::~RemoveServersFromServerGroupRequest() {}
std::string RemoveServersFromServerGroupRequest::getClientToken() const {
return clientToken_;
}
void RemoveServersFromServerGroupRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string RemoveServersFromServerGroupRequest::getServerGroupId() const {
return serverGroupId_;
}
void RemoveServersFromServerGroupRequest::setServerGroupId(const std::string &serverGroupId) {
serverGroupId_ = serverGroupId;
setBodyParameter(std::string("ServerGroupId"), serverGroupId);
}
std::vector<RemoveServersFromServerGroupRequest::Servers> RemoveServersFromServerGroupRequest::getServers() const {
return servers_;
}
void RemoveServersFromServerGroupRequest::setServers(const std::vector<RemoveServersFromServerGroupRequest::Servers> &servers) {
servers_ = servers;
for(int dep1 = 0; dep1 != servers.size(); dep1++) {
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".Port", std::to_string(servers[dep1].port));
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".ServerId", servers[dep1].serverId);
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".ServerIp", servers[dep1].serverIp);
setBodyParameter(std::string("Servers") + "." + std::to_string(dep1 + 1) + ".ServerType", servers[dep1].serverType);
}
}
bool RemoveServersFromServerGroupRequest::getDryRun() const {
return dryRun_;
}
void RemoveServersFromServerGroupRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/RemoveServersFromServerGroupResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
RemoveServersFromServerGroupResult::RemoveServersFromServerGroupResult() :
ServiceResult()
{}
RemoveServersFromServerGroupResult::RemoveServersFromServerGroupResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
RemoveServersFromServerGroupResult::~RemoveServersFromServerGroupResult()
{}
void RemoveServersFromServerGroupResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -0,0 +1,77 @@
/*
* 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 <alibabacloud/gwlb/model/TagResourcesRequest.h>
using AlibabaCloud::Gwlb::Model::TagResourcesRequest;
TagResourcesRequest::TagResourcesRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "TagResources") {
setMethod(HttpRequest::Method::Post);
}
TagResourcesRequest::~TagResourcesRequest() {}
std::string TagResourcesRequest::getClientToken() const {
return clientToken_;
}
void TagResourcesRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::vector<TagResourcesRequest::Tag> TagResourcesRequest::getTag() const {
return tag_;
}
void TagResourcesRequest::setTag(const std::vector<TagResourcesRequest::Tag> &tag) {
tag_ = tag;
for(int dep1 = 0; dep1 != tag.size(); dep1++) {
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Key", tag[dep1].key);
setBodyParameter(std::string("Tag") + "." + std::to_string(dep1 + 1) + ".Value", tag[dep1].value);
}
}
std::vector<TagResourcesRequest::std::string> TagResourcesRequest::getResourceId() const {
return resourceId_;
}
void TagResourcesRequest::setResourceId(const std::vector<TagResourcesRequest::std::string> &resourceId) {
resourceId_ = resourceId;
for(int dep1 = 0; dep1 != resourceId.size(); dep1++) {
setBodyParameter(std::string("ResourceId") + "." + std::to_string(dep1 + 1), resourceId[dep1]);
}
}
bool TagResourcesRequest::getDryRun() const {
return dryRun_;
}
void TagResourcesRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::string TagResourcesRequest::getResourceType() const {
return resourceType_;
}
void TagResourcesRequest::setResourceType(const std::string &resourceType) {
resourceType_ = resourceType;
setBodyParameter(std::string("ResourceType"), resourceType);
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/TagResourcesResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
TagResourcesResult::TagResourcesResult() :
ServiceResult()
{}
TagResourcesResult::TagResourcesResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
TagResourcesResult::~TagResourcesResult()
{}
void TagResourcesResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -0,0 +1,85 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/UntagResourcesRequest.h>
using AlibabaCloud::Gwlb::Model::UntagResourcesRequest;
UntagResourcesRequest::UntagResourcesRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "UntagResources") {
setMethod(HttpRequest::Method::Post);
}
UntagResourcesRequest::~UntagResourcesRequest() {}
std::string UntagResourcesRequest::getClientToken() const {
return clientToken_;
}
void UntagResourcesRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
bool UntagResourcesRequest::getAll() const {
return all_;
}
void UntagResourcesRequest::setAll(bool all) {
all_ = all;
setBodyParameter(std::string("All"), all ? "true" : "false");
}
std::vector<UntagResourcesRequest::std::string> UntagResourcesRequest::getResourceId() const {
return resourceId_;
}
void UntagResourcesRequest::setResourceId(const std::vector<UntagResourcesRequest::std::string> &resourceId) {
resourceId_ = resourceId;
for(int dep1 = 0; dep1 != resourceId.size(); dep1++) {
setBodyParameter(std::string("ResourceId") + "." + std::to_string(dep1 + 1), resourceId[dep1]);
}
}
bool UntagResourcesRequest::getDryRun() const {
return dryRun_;
}
void UntagResourcesRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::string UntagResourcesRequest::getResourceType() const {
return resourceType_;
}
void UntagResourcesRequest::setResourceType(const std::string &resourceType) {
resourceType_ = resourceType;
setBodyParameter(std::string("ResourceType"), resourceType);
}
std::vector<UntagResourcesRequest::std::string> UntagResourcesRequest::getTagKey() const {
return tagKey_;
}
void UntagResourcesRequest::setTagKey(const std::vector<UntagResourcesRequest::std::string> &tagKey) {
tagKey_ = tagKey;
for(int dep1 = 0; dep1 != tagKey.size(); dep1++) {
setBodyParameter(std::string("TagKey") + "." + std::to_string(dep1 + 1), tagKey[dep1]);
}
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/UntagResourcesResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
UntagResourcesResult::UntagResourcesResult() :
ServiceResult()
{}
UntagResourcesResult::UntagResourcesResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
UntagResourcesResult::~UntagResourcesResult()
{}
void UntagResourcesResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -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 <alibabacloud/gwlb/model/UpdateListenerAttributeRequest.h>
using AlibabaCloud::Gwlb::Model::UpdateListenerAttributeRequest;
UpdateListenerAttributeRequest::UpdateListenerAttributeRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "UpdateListenerAttribute") {
setMethod(HttpRequest::Method::Post);
}
UpdateListenerAttributeRequest::~UpdateListenerAttributeRequest() {}
std::string UpdateListenerAttributeRequest::getClientToken() const {
return clientToken_;
}
void UpdateListenerAttributeRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string UpdateListenerAttributeRequest::getServerGroupId() const {
return serverGroupId_;
}
void UpdateListenerAttributeRequest::setServerGroupId(const std::string &serverGroupId) {
serverGroupId_ = serverGroupId;
setBodyParameter(std::string("ServerGroupId"), serverGroupId);
}
std::string UpdateListenerAttributeRequest::getListenerId() const {
return listenerId_;
}
void UpdateListenerAttributeRequest::setListenerId(const std::string &listenerId) {
listenerId_ = listenerId;
setBodyParameter(std::string("ListenerId"), listenerId);
}
bool UpdateListenerAttributeRequest::getDryRun() const {
return dryRun_;
}
void UpdateListenerAttributeRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::string UpdateListenerAttributeRequest::getListenerDescription() const {
return listenerDescription_;
}
void UpdateListenerAttributeRequest::setListenerDescription(const std::string &listenerDescription) {
listenerDescription_ = listenerDescription;
setBodyParameter(std::string("ListenerDescription"), listenerDescription);
}

View File

@@ -0,0 +1,44 @@
/*
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#include <alibabacloud/gwlb/model/UpdateListenerAttributeResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Gwlb;
using namespace AlibabaCloud::Gwlb::Model;
UpdateListenerAttributeResult::UpdateListenerAttributeResult() :
ServiceResult()
{}
UpdateListenerAttributeResult::UpdateListenerAttributeResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
UpdateListenerAttributeResult::~UpdateListenerAttributeResult()
{}
void UpdateListenerAttributeResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
}

View File

@@ -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 <alibabacloud/gwlb/model/UpdateLoadBalancerAttributeRequest.h>
using AlibabaCloud::Gwlb::Model::UpdateLoadBalancerAttributeRequest;
UpdateLoadBalancerAttributeRequest::UpdateLoadBalancerAttributeRequest()
: RpcServiceRequest("gwlb", "2024-04-15", "UpdateLoadBalancerAttribute") {
setMethod(HttpRequest::Method::Post);
}
UpdateLoadBalancerAttributeRequest::~UpdateLoadBalancerAttributeRequest() {}
bool UpdateLoadBalancerAttributeRequest::getCrossZoneEnabled() const {
return crossZoneEnabled_;
}
void UpdateLoadBalancerAttributeRequest::setCrossZoneEnabled(bool crossZoneEnabled) {
crossZoneEnabled_ = crossZoneEnabled;
setBodyParameter(std::string("CrossZoneEnabled"), crossZoneEnabled ? "true" : "false");
}
std::string UpdateLoadBalancerAttributeRequest::getClientToken() const {
return clientToken_;
}
void UpdateLoadBalancerAttributeRequest::setClientToken(const std::string &clientToken) {
clientToken_ = clientToken;
setBodyParameter(std::string("ClientToken"), clientToken);
}
std::string UpdateLoadBalancerAttributeRequest::getLoadBalancerName() const {
return loadBalancerName_;
}
void UpdateLoadBalancerAttributeRequest::setLoadBalancerName(const std::string &loadBalancerName) {
loadBalancerName_ = loadBalancerName;
setBodyParameter(std::string("LoadBalancerName"), loadBalancerName);
}
bool UpdateLoadBalancerAttributeRequest::getDryRun() const {
return dryRun_;
}
void UpdateLoadBalancerAttributeRequest::setDryRun(bool dryRun) {
dryRun_ = dryRun;
setBodyParameter(std::string("DryRun"), dryRun ? "true" : "false");
}
std::string UpdateLoadBalancerAttributeRequest::getLoadBalancerId() const {
return loadBalancerId_;
}
void UpdateLoadBalancerAttributeRequest::setLoadBalancerId(const std::string &loadBalancerId) {
loadBalancerId_ = loadBalancerId;
setBodyParameter(std::string("LoadBalancerId"), loadBalancerId);
}

Some files were not shown because too many files have changed in this diff Show More