Support query quota.
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
2021-05-13 Version: 1.36.732
|
||||
- Support query quota.
|
||||
- Supprt create quota increase request.
|
||||
|
||||
2021-05-13 Version: 1.36.731
|
||||
- Generated 2020-01-01 for `ddoscoo`.
|
||||
|
||||
|
||||
146
quotas/CMakeLists.txt
Normal file
146
quotas/CMakeLists.txt
Normal 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.
|
||||
#
|
||||
|
||||
set(public_header_dir ${CMAKE_CURRENT_SOURCE_DIR}/../include)
|
||||
|
||||
set(quotas_public_header
|
||||
include/alibabacloud/quotas/QuotasClient.h
|
||||
include/alibabacloud/quotas/QuotasExport.h )
|
||||
|
||||
set(quotas_public_header_model
|
||||
include/alibabacloud/quotas/model/CreateQuotaAlarmRequest.h
|
||||
include/alibabacloud/quotas/model/CreateQuotaAlarmResult.h
|
||||
include/alibabacloud/quotas/model/CreateQuotaApplicationRequest.h
|
||||
include/alibabacloud/quotas/model/CreateQuotaApplicationResult.h
|
||||
include/alibabacloud/quotas/model/DeleteQuotaAlarmRequest.h
|
||||
include/alibabacloud/quotas/model/DeleteQuotaAlarmResult.h
|
||||
include/alibabacloud/quotas/model/GetProductQuotaRequest.h
|
||||
include/alibabacloud/quotas/model/GetProductQuotaResult.h
|
||||
include/alibabacloud/quotas/model/GetProductQuotaDimensionRequest.h
|
||||
include/alibabacloud/quotas/model/GetProductQuotaDimensionResult.h
|
||||
include/alibabacloud/quotas/model/GetQuotaAlarmRequest.h
|
||||
include/alibabacloud/quotas/model/GetQuotaAlarmResult.h
|
||||
include/alibabacloud/quotas/model/GetQuotaApplicationRequest.h
|
||||
include/alibabacloud/quotas/model/GetQuotaApplicationResult.h
|
||||
include/alibabacloud/quotas/model/ListAlarmHistoriesRequest.h
|
||||
include/alibabacloud/quotas/model/ListAlarmHistoriesResult.h
|
||||
include/alibabacloud/quotas/model/ListDependentQuotasRequest.h
|
||||
include/alibabacloud/quotas/model/ListDependentQuotasResult.h
|
||||
include/alibabacloud/quotas/model/ListProductDimensionGroupsRequest.h
|
||||
include/alibabacloud/quotas/model/ListProductDimensionGroupsResult.h
|
||||
include/alibabacloud/quotas/model/ListProductQuotaDimensionsRequest.h
|
||||
include/alibabacloud/quotas/model/ListProductQuotaDimensionsResult.h
|
||||
include/alibabacloud/quotas/model/ListProductQuotasRequest.h
|
||||
include/alibabacloud/quotas/model/ListProductQuotasResult.h
|
||||
include/alibabacloud/quotas/model/ListProductsRequest.h
|
||||
include/alibabacloud/quotas/model/ListProductsResult.h
|
||||
include/alibabacloud/quotas/model/ListQuotaAlarmsRequest.h
|
||||
include/alibabacloud/quotas/model/ListQuotaAlarmsResult.h
|
||||
include/alibabacloud/quotas/model/ListQuotaApplicationsRequest.h
|
||||
include/alibabacloud/quotas/model/ListQuotaApplicationsResult.h
|
||||
include/alibabacloud/quotas/model/UpdateQuotaAlarmRequest.h
|
||||
include/alibabacloud/quotas/model/UpdateQuotaAlarmResult.h )
|
||||
|
||||
set(quotas_src
|
||||
src/QuotasClient.cc
|
||||
src/model/CreateQuotaAlarmRequest.cc
|
||||
src/model/CreateQuotaAlarmResult.cc
|
||||
src/model/CreateQuotaApplicationRequest.cc
|
||||
src/model/CreateQuotaApplicationResult.cc
|
||||
src/model/DeleteQuotaAlarmRequest.cc
|
||||
src/model/DeleteQuotaAlarmResult.cc
|
||||
src/model/GetProductQuotaRequest.cc
|
||||
src/model/GetProductQuotaResult.cc
|
||||
src/model/GetProductQuotaDimensionRequest.cc
|
||||
src/model/GetProductQuotaDimensionResult.cc
|
||||
src/model/GetQuotaAlarmRequest.cc
|
||||
src/model/GetQuotaAlarmResult.cc
|
||||
src/model/GetQuotaApplicationRequest.cc
|
||||
src/model/GetQuotaApplicationResult.cc
|
||||
src/model/ListAlarmHistoriesRequest.cc
|
||||
src/model/ListAlarmHistoriesResult.cc
|
||||
src/model/ListDependentQuotasRequest.cc
|
||||
src/model/ListDependentQuotasResult.cc
|
||||
src/model/ListProductDimensionGroupsRequest.cc
|
||||
src/model/ListProductDimensionGroupsResult.cc
|
||||
src/model/ListProductQuotaDimensionsRequest.cc
|
||||
src/model/ListProductQuotaDimensionsResult.cc
|
||||
src/model/ListProductQuotasRequest.cc
|
||||
src/model/ListProductQuotasResult.cc
|
||||
src/model/ListProductsRequest.cc
|
||||
src/model/ListProductsResult.cc
|
||||
src/model/ListQuotaAlarmsRequest.cc
|
||||
src/model/ListQuotaAlarmsResult.cc
|
||||
src/model/ListQuotaApplicationsRequest.cc
|
||||
src/model/ListQuotaApplicationsResult.cc
|
||||
src/model/UpdateQuotaAlarmRequest.cc
|
||||
src/model/UpdateQuotaAlarmResult.cc )
|
||||
|
||||
add_library(quotas ${LIB_TYPE}
|
||||
${quotas_public_header}
|
||||
${quotas_public_header_model}
|
||||
${quotas_src})
|
||||
|
||||
set_target_properties(quotas
|
||||
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}quotas
|
||||
)
|
||||
|
||||
if(${LIB_TYPE} STREQUAL "SHARED")
|
||||
set_target_properties(quotas
|
||||
PROPERTIES
|
||||
DEFINE_SYMBOL ALIBABACLOUD_QUOTAS_LIBRARY)
|
||||
endif()
|
||||
|
||||
target_include_directories(quotas
|
||||
PRIVATE include
|
||||
${CMAKE_SOURCE_DIR}/core/include
|
||||
)
|
||||
target_link_libraries(quotas
|
||||
core)
|
||||
|
||||
if(CMAKE_HOST_WIN32)
|
||||
ExternalProject_Get_Property(jsoncpp INSTALL_DIR)
|
||||
set(jsoncpp_install_dir ${INSTALL_DIR})
|
||||
add_dependencies(quotas
|
||||
jsoncpp)
|
||||
target_include_directories(quotas
|
||||
PRIVATE ${jsoncpp_install_dir}/include)
|
||||
target_link_libraries(quotas
|
||||
${jsoncpp_install_dir}/lib/jsoncpp.lib)
|
||||
set_target_properties(quotas
|
||||
PROPERTIES
|
||||
COMPILE_OPTIONS "/bigobj")
|
||||
else()
|
||||
target_include_directories(quotas
|
||||
PRIVATE /usr/include/jsoncpp)
|
||||
target_link_libraries(quotas
|
||||
jsoncpp)
|
||||
endif()
|
||||
|
||||
install(FILES ${quotas_public_header}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/quotas)
|
||||
install(FILES ${quotas_public_header_model}
|
||||
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alibabacloud/quotas/model)
|
||||
install(TARGETS quotas
|
||||
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||
)
|
||||
174
quotas/include/alibabacloud/quotas/QuotasClient.h
Normal file
174
quotas/include/alibabacloud/quotas/QuotasClient.h
Normal file
@@ -0,0 +1,174 @@
|
||||
/*
|
||||
* 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_QUOTAS_QUOTASCLIENT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_QUOTASCLIENT_H_
|
||||
|
||||
#include <future>
|
||||
#include <alibabacloud/core/AsyncCallerContext.h>
|
||||
#include <alibabacloud/core/EndpointProvider.h>
|
||||
#include <alibabacloud/core/RpcServiceClient.h>
|
||||
#include "QuotasExport.h"
|
||||
#include "model/CreateQuotaAlarmRequest.h"
|
||||
#include "model/CreateQuotaAlarmResult.h"
|
||||
#include "model/CreateQuotaApplicationRequest.h"
|
||||
#include "model/CreateQuotaApplicationResult.h"
|
||||
#include "model/DeleteQuotaAlarmRequest.h"
|
||||
#include "model/DeleteQuotaAlarmResult.h"
|
||||
#include "model/GetProductQuotaRequest.h"
|
||||
#include "model/GetProductQuotaResult.h"
|
||||
#include "model/GetProductQuotaDimensionRequest.h"
|
||||
#include "model/GetProductQuotaDimensionResult.h"
|
||||
#include "model/GetQuotaAlarmRequest.h"
|
||||
#include "model/GetQuotaAlarmResult.h"
|
||||
#include "model/GetQuotaApplicationRequest.h"
|
||||
#include "model/GetQuotaApplicationResult.h"
|
||||
#include "model/ListAlarmHistoriesRequest.h"
|
||||
#include "model/ListAlarmHistoriesResult.h"
|
||||
#include "model/ListDependentQuotasRequest.h"
|
||||
#include "model/ListDependentQuotasResult.h"
|
||||
#include "model/ListProductDimensionGroupsRequest.h"
|
||||
#include "model/ListProductDimensionGroupsResult.h"
|
||||
#include "model/ListProductQuotaDimensionsRequest.h"
|
||||
#include "model/ListProductQuotaDimensionsResult.h"
|
||||
#include "model/ListProductQuotasRequest.h"
|
||||
#include "model/ListProductQuotasResult.h"
|
||||
#include "model/ListProductsRequest.h"
|
||||
#include "model/ListProductsResult.h"
|
||||
#include "model/ListQuotaAlarmsRequest.h"
|
||||
#include "model/ListQuotaAlarmsResult.h"
|
||||
#include "model/ListQuotaApplicationsRequest.h"
|
||||
#include "model/ListQuotaApplicationsResult.h"
|
||||
#include "model/UpdateQuotaAlarmRequest.h"
|
||||
#include "model/UpdateQuotaAlarmResult.h"
|
||||
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT QuotasClient : public RpcServiceClient
|
||||
{
|
||||
public:
|
||||
typedef Outcome<Error, Model::CreateQuotaAlarmResult> CreateQuotaAlarmOutcome;
|
||||
typedef std::future<CreateQuotaAlarmOutcome> CreateQuotaAlarmOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::CreateQuotaAlarmRequest&, const CreateQuotaAlarmOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateQuotaAlarmAsyncHandler;
|
||||
typedef Outcome<Error, Model::CreateQuotaApplicationResult> CreateQuotaApplicationOutcome;
|
||||
typedef std::future<CreateQuotaApplicationOutcome> CreateQuotaApplicationOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::CreateQuotaApplicationRequest&, const CreateQuotaApplicationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateQuotaApplicationAsyncHandler;
|
||||
typedef Outcome<Error, Model::DeleteQuotaAlarmResult> DeleteQuotaAlarmOutcome;
|
||||
typedef std::future<DeleteQuotaAlarmOutcome> DeleteQuotaAlarmOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::DeleteQuotaAlarmRequest&, const DeleteQuotaAlarmOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteQuotaAlarmAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetProductQuotaResult> GetProductQuotaOutcome;
|
||||
typedef std::future<GetProductQuotaOutcome> GetProductQuotaOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::GetProductQuotaRequest&, const GetProductQuotaOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetProductQuotaAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetProductQuotaDimensionResult> GetProductQuotaDimensionOutcome;
|
||||
typedef std::future<GetProductQuotaDimensionOutcome> GetProductQuotaDimensionOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::GetProductQuotaDimensionRequest&, const GetProductQuotaDimensionOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetProductQuotaDimensionAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetQuotaAlarmResult> GetQuotaAlarmOutcome;
|
||||
typedef std::future<GetQuotaAlarmOutcome> GetQuotaAlarmOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::GetQuotaAlarmRequest&, const GetQuotaAlarmOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetQuotaAlarmAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetQuotaApplicationResult> GetQuotaApplicationOutcome;
|
||||
typedef std::future<GetQuotaApplicationOutcome> GetQuotaApplicationOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::GetQuotaApplicationRequest&, const GetQuotaApplicationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetQuotaApplicationAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListAlarmHistoriesResult> ListAlarmHistoriesOutcome;
|
||||
typedef std::future<ListAlarmHistoriesOutcome> ListAlarmHistoriesOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListAlarmHistoriesRequest&, const ListAlarmHistoriesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListAlarmHistoriesAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListDependentQuotasResult> ListDependentQuotasOutcome;
|
||||
typedef std::future<ListDependentQuotasOutcome> ListDependentQuotasOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListDependentQuotasRequest&, const ListDependentQuotasOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListDependentQuotasAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListProductDimensionGroupsResult> ListProductDimensionGroupsOutcome;
|
||||
typedef std::future<ListProductDimensionGroupsOutcome> ListProductDimensionGroupsOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListProductDimensionGroupsRequest&, const ListProductDimensionGroupsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListProductDimensionGroupsAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListProductQuotaDimensionsResult> ListProductQuotaDimensionsOutcome;
|
||||
typedef std::future<ListProductQuotaDimensionsOutcome> ListProductQuotaDimensionsOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListProductQuotaDimensionsRequest&, const ListProductQuotaDimensionsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListProductQuotaDimensionsAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListProductQuotasResult> ListProductQuotasOutcome;
|
||||
typedef std::future<ListProductQuotasOutcome> ListProductQuotasOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListProductQuotasRequest&, const ListProductQuotasOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListProductQuotasAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListProductsResult> ListProductsOutcome;
|
||||
typedef std::future<ListProductsOutcome> ListProductsOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListProductsRequest&, const ListProductsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListProductsAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListQuotaAlarmsResult> ListQuotaAlarmsOutcome;
|
||||
typedef std::future<ListQuotaAlarmsOutcome> ListQuotaAlarmsOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListQuotaAlarmsRequest&, const ListQuotaAlarmsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListQuotaAlarmsAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListQuotaApplicationsResult> ListQuotaApplicationsOutcome;
|
||||
typedef std::future<ListQuotaApplicationsOutcome> ListQuotaApplicationsOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::ListQuotaApplicationsRequest&, const ListQuotaApplicationsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListQuotaApplicationsAsyncHandler;
|
||||
typedef Outcome<Error, Model::UpdateQuotaAlarmResult> UpdateQuotaAlarmOutcome;
|
||||
typedef std::future<UpdateQuotaAlarmOutcome> UpdateQuotaAlarmOutcomeCallable;
|
||||
typedef std::function<void(const QuotasClient*, const Model::UpdateQuotaAlarmRequest&, const UpdateQuotaAlarmOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> UpdateQuotaAlarmAsyncHandler;
|
||||
|
||||
QuotasClient(const Credentials &credentials, const ClientConfiguration &configuration);
|
||||
QuotasClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
|
||||
QuotasClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
|
||||
~QuotasClient();
|
||||
CreateQuotaAlarmOutcome createQuotaAlarm(const Model::CreateQuotaAlarmRequest &request)const;
|
||||
void createQuotaAlarmAsync(const Model::CreateQuotaAlarmRequest& request, const CreateQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
CreateQuotaAlarmOutcomeCallable createQuotaAlarmCallable(const Model::CreateQuotaAlarmRequest& request) const;
|
||||
CreateQuotaApplicationOutcome createQuotaApplication(const Model::CreateQuotaApplicationRequest &request)const;
|
||||
void createQuotaApplicationAsync(const Model::CreateQuotaApplicationRequest& request, const CreateQuotaApplicationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
CreateQuotaApplicationOutcomeCallable createQuotaApplicationCallable(const Model::CreateQuotaApplicationRequest& request) const;
|
||||
DeleteQuotaAlarmOutcome deleteQuotaAlarm(const Model::DeleteQuotaAlarmRequest &request)const;
|
||||
void deleteQuotaAlarmAsync(const Model::DeleteQuotaAlarmRequest& request, const DeleteQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DeleteQuotaAlarmOutcomeCallable deleteQuotaAlarmCallable(const Model::DeleteQuotaAlarmRequest& request) const;
|
||||
GetProductQuotaOutcome getProductQuota(const Model::GetProductQuotaRequest &request)const;
|
||||
void getProductQuotaAsync(const Model::GetProductQuotaRequest& request, const GetProductQuotaAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetProductQuotaOutcomeCallable getProductQuotaCallable(const Model::GetProductQuotaRequest& request) const;
|
||||
GetProductQuotaDimensionOutcome getProductQuotaDimension(const Model::GetProductQuotaDimensionRequest &request)const;
|
||||
void getProductQuotaDimensionAsync(const Model::GetProductQuotaDimensionRequest& request, const GetProductQuotaDimensionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetProductQuotaDimensionOutcomeCallable getProductQuotaDimensionCallable(const Model::GetProductQuotaDimensionRequest& request) const;
|
||||
GetQuotaAlarmOutcome getQuotaAlarm(const Model::GetQuotaAlarmRequest &request)const;
|
||||
void getQuotaAlarmAsync(const Model::GetQuotaAlarmRequest& request, const GetQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetQuotaAlarmOutcomeCallable getQuotaAlarmCallable(const Model::GetQuotaAlarmRequest& request) const;
|
||||
GetQuotaApplicationOutcome getQuotaApplication(const Model::GetQuotaApplicationRequest &request)const;
|
||||
void getQuotaApplicationAsync(const Model::GetQuotaApplicationRequest& request, const GetQuotaApplicationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetQuotaApplicationOutcomeCallable getQuotaApplicationCallable(const Model::GetQuotaApplicationRequest& request) const;
|
||||
ListAlarmHistoriesOutcome listAlarmHistories(const Model::ListAlarmHistoriesRequest &request)const;
|
||||
void listAlarmHistoriesAsync(const Model::ListAlarmHistoriesRequest& request, const ListAlarmHistoriesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListAlarmHistoriesOutcomeCallable listAlarmHistoriesCallable(const Model::ListAlarmHistoriesRequest& request) const;
|
||||
ListDependentQuotasOutcome listDependentQuotas(const Model::ListDependentQuotasRequest &request)const;
|
||||
void listDependentQuotasAsync(const Model::ListDependentQuotasRequest& request, const ListDependentQuotasAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListDependentQuotasOutcomeCallable listDependentQuotasCallable(const Model::ListDependentQuotasRequest& request) const;
|
||||
ListProductDimensionGroupsOutcome listProductDimensionGroups(const Model::ListProductDimensionGroupsRequest &request)const;
|
||||
void listProductDimensionGroupsAsync(const Model::ListProductDimensionGroupsRequest& request, const ListProductDimensionGroupsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListProductDimensionGroupsOutcomeCallable listProductDimensionGroupsCallable(const Model::ListProductDimensionGroupsRequest& request) const;
|
||||
ListProductQuotaDimensionsOutcome listProductQuotaDimensions(const Model::ListProductQuotaDimensionsRequest &request)const;
|
||||
void listProductQuotaDimensionsAsync(const Model::ListProductQuotaDimensionsRequest& request, const ListProductQuotaDimensionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListProductQuotaDimensionsOutcomeCallable listProductQuotaDimensionsCallable(const Model::ListProductQuotaDimensionsRequest& request) const;
|
||||
ListProductQuotasOutcome listProductQuotas(const Model::ListProductQuotasRequest &request)const;
|
||||
void listProductQuotasAsync(const Model::ListProductQuotasRequest& request, const ListProductQuotasAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListProductQuotasOutcomeCallable listProductQuotasCallable(const Model::ListProductQuotasRequest& request) const;
|
||||
ListProductsOutcome listProducts(const Model::ListProductsRequest &request)const;
|
||||
void listProductsAsync(const Model::ListProductsRequest& request, const ListProductsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListProductsOutcomeCallable listProductsCallable(const Model::ListProductsRequest& request) const;
|
||||
ListQuotaAlarmsOutcome listQuotaAlarms(const Model::ListQuotaAlarmsRequest &request)const;
|
||||
void listQuotaAlarmsAsync(const Model::ListQuotaAlarmsRequest& request, const ListQuotaAlarmsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListQuotaAlarmsOutcomeCallable listQuotaAlarmsCallable(const Model::ListQuotaAlarmsRequest& request) const;
|
||||
ListQuotaApplicationsOutcome listQuotaApplications(const Model::ListQuotaApplicationsRequest &request)const;
|
||||
void listQuotaApplicationsAsync(const Model::ListQuotaApplicationsRequest& request, const ListQuotaApplicationsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListQuotaApplicationsOutcomeCallable listQuotaApplicationsCallable(const Model::ListQuotaApplicationsRequest& request) const;
|
||||
UpdateQuotaAlarmOutcome updateQuotaAlarm(const Model::UpdateQuotaAlarmRequest &request)const;
|
||||
void updateQuotaAlarmAsync(const Model::UpdateQuotaAlarmRequest& request, const UpdateQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
UpdateQuotaAlarmOutcomeCallable updateQuotaAlarmCallable(const Model::UpdateQuotaAlarmRequest& request) const;
|
||||
|
||||
private:
|
||||
std::shared_ptr<EndpointProvider> endpointProvider_;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
#endif // !ALIBABACLOUD_QUOTAS_QUOTASCLIENT_H_
|
||||
32
quotas/include/alibabacloud/quotas/QuotasExport.h
Normal file
32
quotas/include/alibabacloud/quotas/QuotasExport.h
Normal 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_QUOTAS_QUOTASEXPORT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_QUOTASEXPORT_H_
|
||||
|
||||
#include <alibabacloud/core/Global.h>
|
||||
|
||||
#if defined(ALIBABACLOUD_SHARED)
|
||||
# if defined(ALIBABACLOUD_QUOTAS_LIBRARY)
|
||||
# define ALIBABACLOUD_QUOTAS_EXPORT ALIBABACLOUD_DECL_EXPORT
|
||||
# else
|
||||
# define ALIBABACLOUD_QUOTAS_EXPORT ALIBABACLOUD_DECL_IMPORT
|
||||
# endif
|
||||
#else
|
||||
# define ALIBABACLOUD_QUOTAS_EXPORT
|
||||
#endif
|
||||
|
||||
#endif // !ALIBABACLOUD_QUOTAS_QUOTASEXPORT_H_
|
||||
@@ -0,0 +1,75 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaAlarmRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct QuotaDimensions
|
||||
{
|
||||
std::string key;
|
||||
std::string value;
|
||||
};
|
||||
|
||||
public:
|
||||
CreateQuotaAlarmRequest();
|
||||
~CreateQuotaAlarmRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getWebHook()const;
|
||||
void setWebHook(const std::string& webHook);
|
||||
float getThreshold()const;
|
||||
void setThreshold(float threshold);
|
||||
std::string getQuotaActionCode()const;
|
||||
void setQuotaActionCode(const std::string& quotaActionCode);
|
||||
std::string getThresholdType()const;
|
||||
void setThresholdType(const std::string& thresholdType);
|
||||
std::vector<QuotaDimensions> getQuotaDimensions()const;
|
||||
void setQuotaDimensions(const std::vector<QuotaDimensions>& quotaDimensions);
|
||||
float getThresholdPercent()const;
|
||||
void setThresholdPercent(float thresholdPercent);
|
||||
std::string getAlarmName()const;
|
||||
void setAlarmName(const std::string& alarmName);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string webHook_;
|
||||
float threshold_;
|
||||
std::string quotaActionCode_;
|
||||
std::string thresholdType_;
|
||||
std::vector<QuotaDimensions> quotaDimensions_;
|
||||
float thresholdPercent_;
|
||||
std::string alarmName_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaAlarmResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
CreateQuotaAlarmResult();
|
||||
explicit CreateQuotaAlarmResult(const std::string &payload);
|
||||
~CreateQuotaAlarmResult();
|
||||
std::string getAlarmId()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string alarmId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMRESULT_H_
|
||||
@@ -0,0 +1,75 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaApplicationRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct Dimensions
|
||||
{
|
||||
std::string key;
|
||||
std::string value;
|
||||
};
|
||||
|
||||
public:
|
||||
CreateQuotaApplicationRequest();
|
||||
~CreateQuotaApplicationRequest();
|
||||
|
||||
std::string getReason()const;
|
||||
void setReason(const std::string& reason);
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getQuotaActionCode()const;
|
||||
void setQuotaActionCode(const std::string& quotaActionCode);
|
||||
float getDesireValue()const;
|
||||
void setDesireValue(float desireValue);
|
||||
std::string getQuotaCategory()const;
|
||||
void setQuotaCategory(const std::string& quotaCategory);
|
||||
int getNoticeType()const;
|
||||
void setNoticeType(int noticeType);
|
||||
std::string getAuditMode()const;
|
||||
void setAuditMode(const std::string& auditMode);
|
||||
std::vector<Dimensions> getDimensions()const;
|
||||
void setDimensions(const std::vector<Dimensions>& dimensions);
|
||||
|
||||
private:
|
||||
std::string reason_;
|
||||
std::string productCode_;
|
||||
std::string quotaActionCode_;
|
||||
float desireValue_;
|
||||
std::string quotaCategory_;
|
||||
int noticeType_;
|
||||
std::string auditMode_;
|
||||
std::vector<Dimensions> dimensions_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_
|
||||
@@ -0,0 +1,83 @@
|
||||
/*
|
||||
* 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_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaApplicationResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
CreateQuotaApplicationResult();
|
||||
explicit CreateQuotaApplicationResult(const std::string &payload);
|
||||
~CreateQuotaApplicationResult();
|
||||
std::string getStatus()const;
|
||||
std::string getApplyTime()const;
|
||||
std::string getQuotaDescription()const;
|
||||
std::string getEffectiveTime()const;
|
||||
std::string getProductCode()const;
|
||||
std::string getQuotaUnit()const;
|
||||
std::string getAuditReason()const;
|
||||
std::string getDimension()const;
|
||||
float getApproveValue()const;
|
||||
std::string getReason()const;
|
||||
std::string getQuotaActionCode()const;
|
||||
std::string getQuotaName()const;
|
||||
std::string getQuotaArn()const;
|
||||
long getNoticeType()const;
|
||||
std::string getExpireTime()const;
|
||||
std::string getApplicationId()const;
|
||||
int getDesireValue()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string status_;
|
||||
std::string applyTime_;
|
||||
std::string quotaDescription_;
|
||||
std::string effectiveTime_;
|
||||
std::string productCode_;
|
||||
std::string quotaUnit_;
|
||||
std::string auditReason_;
|
||||
std::string dimension_;
|
||||
float approveValue_;
|
||||
std::string reason_;
|
||||
std::string quotaActionCode_;
|
||||
std::string quotaName_;
|
||||
std::string quotaArn_;
|
||||
long noticeType_;
|
||||
std::string expireTime_;
|
||||
std::string applicationId_;
|
||||
int desireValue_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONRESULT_H_
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT DeleteQuotaAlarmRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
DeleteQuotaAlarmRequest();
|
||||
~DeleteQuotaAlarmRequest();
|
||||
|
||||
std::string getAlarmId()const;
|
||||
void setAlarmId(const std::string& alarmId);
|
||||
|
||||
private:
|
||||
std::string alarmId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_
|
||||
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT DeleteQuotaAlarmResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
DeleteQuotaAlarmResult();
|
||||
explicit DeleteQuotaAlarmResult(const std::string &payload);
|
||||
~DeleteQuotaAlarmResult();
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMRESULT_H_
|
||||
@@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetProductQuotaDimensionRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct DependentDimensions
|
||||
{
|
||||
std::string key;
|
||||
std::string value;
|
||||
};
|
||||
|
||||
public:
|
||||
GetProductQuotaDimensionRequest();
|
||||
~GetProductQuotaDimensionRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::vector<DependentDimensions> getDependentDimensions()const;
|
||||
void setDependentDimensions(const std::vector<DependentDimensions>& dependentDimensions);
|
||||
std::string getDimensionKey()const;
|
||||
void setDimensionKey(const std::string& dimensionKey);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::vector<DependentDimensions> dependentDimensions_;
|
||||
std::string dimensionKey_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_
|
||||
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetProductQuotaDimensionResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotaDimension
|
||||
{
|
||||
struct DimensionValueDetailItem
|
||||
{
|
||||
std::string value;
|
||||
std::string name;
|
||||
};
|
||||
std::string dimensionKey;
|
||||
std::vector<std::string> dimensionValues;
|
||||
std::vector<DimensionValueDetailItem> dimensionValueDetail;
|
||||
std::string name;
|
||||
std::vector<std::string> dependentDimensions;
|
||||
};
|
||||
|
||||
|
||||
GetProductQuotaDimensionResult();
|
||||
explicit GetProductQuotaDimensionResult(const std::string &payload);
|
||||
~GetProductQuotaDimensionResult();
|
||||
QuotaDimension getQuotaDimension()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
QuotaDimension quotaDimension_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONRESULT_H_
|
||||
@@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetProductQuotaRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct Dimensions
|
||||
{
|
||||
std::string key;
|
||||
std::string value;
|
||||
};
|
||||
|
||||
public:
|
||||
GetProductQuotaRequest();
|
||||
~GetProductQuotaRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getQuotaActionCode()const;
|
||||
void setQuotaActionCode(const std::string& quotaActionCode);
|
||||
std::vector<Dimensions> getDimensions()const;
|
||||
void setDimensions(const std::vector<Dimensions>& dimensions);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string quotaActionCode_;
|
||||
std::vector<Dimensions> dimensions_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_
|
||||
@@ -0,0 +1,83 @@
|
||||
/*
|
||||
* 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_QUOTAS_MODEL_GETPRODUCTQUOTARESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTARESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetProductQuotaResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Quota
|
||||
{
|
||||
struct Period
|
||||
{
|
||||
int periodValue;
|
||||
std::string periodUnit;
|
||||
};
|
||||
struct QuotaItemsItem
|
||||
{
|
||||
std::string usage;
|
||||
std::string type;
|
||||
std::string quota;
|
||||
std::string quotaUnit;
|
||||
};
|
||||
std::string quotaDescription;
|
||||
bool consumable;
|
||||
std::string unadjustableDetail;
|
||||
std::string productCode;
|
||||
float totalUsage;
|
||||
std::string quotaType;
|
||||
Period period;
|
||||
std::string dimensions;
|
||||
std::string quotaUnit;
|
||||
bool adjustable;
|
||||
std::string quotaActionCode;
|
||||
std::vector<QuotaItemsItem> quotaItems;
|
||||
std::string quotaName;
|
||||
std::string quotaArn;
|
||||
float totalQuota;
|
||||
std::string applicableType;
|
||||
std::vector<std::string> applicableRange;
|
||||
};
|
||||
|
||||
|
||||
GetProductQuotaResult();
|
||||
explicit GetProductQuotaResult(const std::string &payload);
|
||||
~GetProductQuotaResult();
|
||||
Quota getQuota()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Quota quota_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTARESULT_H_
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaAlarmRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
GetQuotaAlarmRequest();
|
||||
~GetQuotaAlarmRequest();
|
||||
|
||||
std::string getAlarmId()const;
|
||||
void setAlarmId(const std::string& alarmId);
|
||||
|
||||
private:
|
||||
std::string alarmId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_
|
||||
@@ -0,0 +1,67 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaAlarmResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotaAlarm
|
||||
{
|
||||
std::string alarmId;
|
||||
float thresholdPercent;
|
||||
std::string productCode;
|
||||
std::string createTime;
|
||||
float quotaUsage;
|
||||
std::string quotaActionCode;
|
||||
std::vector<std::string> notifyChannels;
|
||||
float quotaValue;
|
||||
std::string alarmName;
|
||||
std::string notifyTarget;
|
||||
std::string quotaDimension;
|
||||
float threshold;
|
||||
std::string thresholdType;
|
||||
};
|
||||
|
||||
|
||||
GetQuotaAlarmResult();
|
||||
explicit GetQuotaAlarmResult(const std::string &payload);
|
||||
~GetQuotaAlarmResult();
|
||||
QuotaAlarm getQuotaAlarm()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
QuotaAlarm quotaAlarm_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMRESULT_H_
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaApplicationRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
GetQuotaApplicationRequest();
|
||||
~GetQuotaApplicationRequest();
|
||||
|
||||
std::string getApplicationId()const;
|
||||
void setApplicationId(const std::string& applicationId);
|
||||
|
||||
private:
|
||||
std::string applicationId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_
|
||||
@@ -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_QUOTAS_MODEL_GETQUOTAAPPLICATIONRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaApplicationResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotaApplication
|
||||
{
|
||||
std::string status;
|
||||
std::string applyTime;
|
||||
std::string quotaDescription;
|
||||
std::string effectiveTime;
|
||||
std::string productCode;
|
||||
std::string quotaUnit;
|
||||
std::string auditReason;
|
||||
std::string dimension;
|
||||
float approveValue;
|
||||
std::string reason;
|
||||
std::string quotaActionCode;
|
||||
std::string quotaName;
|
||||
std::string quotaArn;
|
||||
long noticeType;
|
||||
std::string expireTime;
|
||||
std::string applicationId;
|
||||
int desireValue;
|
||||
};
|
||||
|
||||
|
||||
GetQuotaApplicationResult();
|
||||
explicit GetQuotaApplicationResult(const std::string &payload);
|
||||
~GetQuotaApplicationResult();
|
||||
QuotaApplication getQuotaApplication()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
QuotaApplication quotaApplication_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONRESULT_H_
|
||||
@@ -0,0 +1,63 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListAlarmHistoriesRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
ListAlarmHistoriesRequest();
|
||||
~ListAlarmHistoriesRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
long getStartTime()const;
|
||||
void setStartTime(long startTime);
|
||||
std::string getNextToken()const;
|
||||
void setNextToken(const std::string& nextToken);
|
||||
std::string getKeyword()const;
|
||||
void setKeyword(const std::string& keyword);
|
||||
long getEndTime()const;
|
||||
void setEndTime(long endTime);
|
||||
int getMaxResults()const;
|
||||
void setMaxResults(int maxResults);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
long startTime_;
|
||||
std::string nextToken_;
|
||||
std::string keyword_;
|
||||
long endTime_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESREQUEST_H_
|
||||
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListAlarmHistoriesResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct AlarmHistory
|
||||
{
|
||||
std::string quotaActionCode;
|
||||
std::vector<std::string> notifyChannels;
|
||||
float thresholdPercent;
|
||||
std::string alarmName;
|
||||
std::string productCode;
|
||||
std::string notifyTarget;
|
||||
std::string createTime;
|
||||
float quotaUsage;
|
||||
float threshold;
|
||||
};
|
||||
|
||||
|
||||
ListAlarmHistoriesResult();
|
||||
explicit ListAlarmHistoriesResult(const std::string &payload);
|
||||
~ListAlarmHistoriesResult();
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
int getMaxResults()const;
|
||||
std::vector<AlarmHistory> getAlarmHistories()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
std::vector<AlarmHistory> alarmHistories_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESRESULT_H_
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListDependentQuotasRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
ListDependentQuotasRequest();
|
||||
~ListDependentQuotasRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getQuotaActionCode()const;
|
||||
void setQuotaActionCode(const std::string& quotaActionCode);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string quotaActionCode_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASREQUEST_H_
|
||||
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListDependentQuotasResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotasItem
|
||||
{
|
||||
struct DimensionsItem
|
||||
{
|
||||
std::string dimensionKey;
|
||||
std::vector<std::string> dimensionValues;
|
||||
std::vector<std::string> dependentDimension;
|
||||
};
|
||||
std::string quotaActionCode;
|
||||
std::string productCode;
|
||||
std::vector<QuotasItem::DimensionsItem> dimensions;
|
||||
float scale;
|
||||
};
|
||||
|
||||
|
||||
ListDependentQuotasResult();
|
||||
explicit ListDependentQuotasResult(const std::string &payload);
|
||||
~ListDependentQuotasResult();
|
||||
std::vector<QuotasItem> getQuotas()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::vector<QuotasItem> quotas_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASRESULT_H_
|
||||
@@ -0,0 +1,54 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductDimensionGroupsRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
ListProductDimensionGroupsRequest();
|
||||
~ListProductDimensionGroupsRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getNextToken()const;
|
||||
void setNextToken(const std::string& nextToken);
|
||||
int getMaxResults()const;
|
||||
void setMaxResults(int maxResults);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_
|
||||
@@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductDimensionGroupsResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct DimensionGroupsItem
|
||||
{
|
||||
std::string groupName;
|
||||
std::string productCode;
|
||||
std::vector<std::string> dimensionKeys;
|
||||
std::string groupCode;
|
||||
};
|
||||
|
||||
|
||||
ListProductDimensionGroupsResult();
|
||||
explicit ListProductDimensionGroupsResult(const std::string &payload);
|
||||
~ListProductDimensionGroupsResult();
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
int getMaxResults()const;
|
||||
std::vector<DimensionGroupsItem> getDimensionGroups()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
std::vector<DimensionGroupsItem> dimensionGroups_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSRESULT_H_
|
||||
@@ -0,0 +1,57 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductQuotaDimensionsRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
ListProductQuotaDimensionsRequest();
|
||||
~ListProductQuotaDimensionsRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getNextToken()const;
|
||||
void setNextToken(const std::string& nextToken);
|
||||
int getMaxResults()const;
|
||||
void setMaxResults(int maxResults);
|
||||
std::string getQuotaCategory()const;
|
||||
void setQuotaCategory(const std::string& quotaCategory);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
std::string quotaCategory_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_
|
||||
@@ -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_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductQuotaDimensionsResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotaDimensionsItem
|
||||
{
|
||||
struct DimensionValueDetailItem
|
||||
{
|
||||
std::string value;
|
||||
std::string name;
|
||||
};
|
||||
std::string dimensionKey;
|
||||
std::vector<std::string> dimensionValues;
|
||||
std::vector<QuotaDimensionsItem::DimensionValueDetailItem> dimensionValueDetail;
|
||||
std::string name;
|
||||
bool requisite;
|
||||
std::vector<std::string> dependentDimensions;
|
||||
};
|
||||
|
||||
|
||||
ListProductQuotaDimensionsResult();
|
||||
explicit ListProductQuotaDimensionsResult(const std::string &payload);
|
||||
~ListProductQuotaDimensionsResult();
|
||||
std::vector<QuotaDimensionsItem> getQuotaDimensions()const;
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
int getMaxResults()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::vector<QuotaDimensionsItem> quotaDimensions_;
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSRESULT_H_
|
||||
@@ -0,0 +1,81 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductQuotasRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct Dimensions
|
||||
{
|
||||
std::string key;
|
||||
std::string value;
|
||||
};
|
||||
|
||||
public:
|
||||
ListProductQuotasRequest();
|
||||
~ListProductQuotasRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getQuotaActionCode()const;
|
||||
void setQuotaActionCode(const std::string& quotaActionCode);
|
||||
std::string getGroupCode()const;
|
||||
void setGroupCode(const std::string& groupCode);
|
||||
std::string getNextToken()const;
|
||||
void setNextToken(const std::string& nextToken);
|
||||
std::string getSortOrder()const;
|
||||
void setSortOrder(const std::string& sortOrder);
|
||||
std::string getKeyWord()const;
|
||||
void setKeyWord(const std::string& keyWord);
|
||||
std::string getQuotaCategory()const;
|
||||
void setQuotaCategory(const std::string& quotaCategory);
|
||||
int getMaxResults()const;
|
||||
void setMaxResults(int maxResults);
|
||||
std::string getSortField()const;
|
||||
void setSortField(const std::string& sortField);
|
||||
std::vector<Dimensions> getDimensions()const;
|
||||
void setDimensions(const std::vector<Dimensions>& dimensions);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string quotaActionCode_;
|
||||
std::string groupCode_;
|
||||
std::string nextToken_;
|
||||
std::string sortOrder_;
|
||||
std::string keyWord_;
|
||||
std::string quotaCategory_;
|
||||
int maxResults_;
|
||||
std::string sortField_;
|
||||
std::vector<Dimensions> dimensions_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_
|
||||
@@ -0,0 +1,89 @@
|
||||
/*
|
||||
* 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_QUOTAS_MODEL_LISTPRODUCTQUOTASRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductQuotasResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotasItem
|
||||
{
|
||||
struct Period
|
||||
{
|
||||
int periodValue;
|
||||
std::string periodUnit;
|
||||
};
|
||||
struct QuotaItemsItem
|
||||
{
|
||||
std::string usage;
|
||||
std::string type;
|
||||
std::string quota;
|
||||
std::string quotaUnit;
|
||||
};
|
||||
std::string quotaDescription;
|
||||
bool consumable;
|
||||
std::string unadjustableDetail;
|
||||
std::string productCode;
|
||||
float totalUsage;
|
||||
std::string quotaType;
|
||||
Period period;
|
||||
std::string dimensions;
|
||||
std::string quotaUnit;
|
||||
bool adjustable;
|
||||
std::string quotaActionCode;
|
||||
std::vector<QuotasItem::QuotaItemsItem> quotaItems;
|
||||
std::string quotaName;
|
||||
std::string quotaArn;
|
||||
float totalQuota;
|
||||
std::string applicableType;
|
||||
std::vector<std::string> applicableRange;
|
||||
};
|
||||
|
||||
|
||||
ListProductQuotasResult();
|
||||
explicit ListProductQuotasResult(const std::string &payload);
|
||||
~ListProductQuotasResult();
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
std::vector<QuotasItem> getQuotas()const;
|
||||
int getMaxResults()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
std::vector<QuotasItem> quotas_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASRESULT_H_
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductsRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
ListProductsRequest();
|
||||
~ListProductsRequest();
|
||||
|
||||
std::string getNextToken()const;
|
||||
void setNextToken(const std::string& nextToken);
|
||||
int getMaxResults()const;
|
||||
void setMaxResults(int maxResults);
|
||||
|
||||
private:
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSREQUEST_H_
|
||||
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListProductsResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct ProductInfos
|
||||
{
|
||||
std::string secondCategoryNameEn;
|
||||
bool dynamic;
|
||||
std::string commonQuotaSupport;
|
||||
std::string productName;
|
||||
std::string productCode;
|
||||
std::string secondCategoryName;
|
||||
std::string flowControlSupport;
|
||||
long secondCategoryId;
|
||||
std::string productNameEn;
|
||||
};
|
||||
|
||||
|
||||
ListProductsResult();
|
||||
explicit ListProductsResult(const std::string &payload);
|
||||
~ListProductsResult();
|
||||
std::vector<ProductInfos> getProductInfo()const;
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
int getMaxResults()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::vector<ProductInfos> productInfo_;
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSRESULT_H_
|
||||
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaAlarmsRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct QuotaDimensions
|
||||
{
|
||||
std::string key;
|
||||
std::string value;
|
||||
};
|
||||
|
||||
public:
|
||||
ListQuotaAlarmsRequest();
|
||||
~ListQuotaAlarmsRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getQuotaActionCode()const;
|
||||
void setQuotaActionCode(const std::string& quotaActionCode);
|
||||
std::string getNextToken()const;
|
||||
void setNextToken(const std::string& nextToken);
|
||||
std::vector<QuotaDimensions> getQuotaDimensions()const;
|
||||
void setQuotaDimensions(const std::vector<QuotaDimensions>& quotaDimensions);
|
||||
int getMaxResults()const;
|
||||
void setMaxResults(int maxResults);
|
||||
std::string getAlarmName()const;
|
||||
void setAlarmName(const std::string& alarmName);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string quotaActionCode_;
|
||||
std::string nextToken_;
|
||||
std::vector<QuotaDimensions> quotaDimensions_;
|
||||
int maxResults_;
|
||||
std::string alarmName_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_
|
||||
@@ -0,0 +1,75 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaAlarmsResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotaAlarm
|
||||
{
|
||||
std::string alarmId;
|
||||
std::string quotaDimensions;
|
||||
float thresholdPercent;
|
||||
std::string productCode;
|
||||
std::string createTime;
|
||||
std::string webHook;
|
||||
float quotaUsage;
|
||||
bool exceedThreshold;
|
||||
std::string quotaActionCode;
|
||||
std::vector<std::string> notifyChannels;
|
||||
float quotaValue;
|
||||
std::string alarmName;
|
||||
std::string notifyTarget;
|
||||
float threshold;
|
||||
std::string thresholdType;
|
||||
};
|
||||
|
||||
|
||||
ListQuotaAlarmsResult();
|
||||
explicit ListQuotaAlarmsResult(const std::string &payload);
|
||||
~ListQuotaAlarmsResult();
|
||||
std::vector<QuotaAlarm> getQuotaAlarms()const;
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
int getMaxResults()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::vector<QuotaAlarm> quotaAlarms_;
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSRESULT_H_
|
||||
@@ -0,0 +1,75 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationsRequest : public RpcServiceRequest
|
||||
{
|
||||
public:
|
||||
struct Dimensions
|
||||
{
|
||||
std::string key;
|
||||
std::string value;
|
||||
};
|
||||
|
||||
public:
|
||||
ListQuotaApplicationsRequest();
|
||||
~ListQuotaApplicationsRequest();
|
||||
|
||||
std::string getProductCode()const;
|
||||
void setProductCode(const std::string& productCode);
|
||||
std::string getQuotaActionCode()const;
|
||||
void setQuotaActionCode(const std::string& quotaActionCode);
|
||||
std::string getNextToken()const;
|
||||
void setNextToken(const std::string& nextToken);
|
||||
std::string getKeyWord()const;
|
||||
void setKeyWord(const std::string& keyWord);
|
||||
std::string getQuotaCategory()const;
|
||||
void setQuotaCategory(const std::string& quotaCategory);
|
||||
int getMaxResults()const;
|
||||
void setMaxResults(int maxResults);
|
||||
std::string getStatus()const;
|
||||
void setStatus(const std::string& status);
|
||||
std::vector<Dimensions> getDimensions()const;
|
||||
void setDimensions(const std::vector<Dimensions>& dimensions);
|
||||
|
||||
private:
|
||||
std::string productCode_;
|
||||
std::string quotaActionCode_;
|
||||
std::string nextToken_;
|
||||
std::string keyWord_;
|
||||
std::string quotaCategory_;
|
||||
int maxResults_;
|
||||
std::string status_;
|
||||
std::vector<Dimensions> dimensions_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_
|
||||
@@ -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.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationsResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct QuotaApplicationsItem
|
||||
{
|
||||
struct Period
|
||||
{
|
||||
long periodValue;
|
||||
std::string periodUnit;
|
||||
};
|
||||
std::string status;
|
||||
std::string applyTime;
|
||||
std::string comment;
|
||||
std::string quotaDescription;
|
||||
std::string productCode;
|
||||
std::string effectiveTime;
|
||||
Period period;
|
||||
std::string auditReason;
|
||||
std::string quotaUnit;
|
||||
std::string dimension;
|
||||
float approveValue;
|
||||
std::string reason;
|
||||
std::string quotaActionCode;
|
||||
std::string quotaName;
|
||||
std::string quotaArn;
|
||||
int noticeType;
|
||||
std::string applicationId;
|
||||
float desireValue;
|
||||
std::string expireTime;
|
||||
};
|
||||
|
||||
|
||||
ListQuotaApplicationsResult();
|
||||
explicit ListQuotaApplicationsResult(const std::string &payload);
|
||||
~ListQuotaApplicationsResult();
|
||||
std::vector<QuotaApplicationsItem> getQuotaApplications()const;
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
int getMaxResults()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::vector<QuotaApplicationsItem> quotaApplications_;
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSRESULT_H_
|
||||
@@ -0,0 +1,63 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMREQUEST_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT UpdateQuotaAlarmRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
UpdateQuotaAlarmRequest();
|
||||
~UpdateQuotaAlarmRequest();
|
||||
|
||||
std::string getWebHook()const;
|
||||
void setWebHook(const std::string& webHook);
|
||||
float getThreshold()const;
|
||||
void setThreshold(float threshold);
|
||||
std::string getThresholdType()const;
|
||||
void setThresholdType(const std::string& thresholdType);
|
||||
float getThresholdPercent()const;
|
||||
void setThresholdPercent(float thresholdPercent);
|
||||
std::string getAlarmId()const;
|
||||
void setAlarmId(const std::string& alarmId);
|
||||
std::string getAlarmName()const;
|
||||
void setAlarmName(const std::string& alarmName);
|
||||
|
||||
private:
|
||||
std::string webHook_;
|
||||
float threshold_;
|
||||
std::string thresholdType_;
|
||||
float thresholdPercent_;
|
||||
std::string alarmId_;
|
||||
std::string alarmName_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMREQUEST_H_
|
||||
@@ -0,0 +1,49 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMRESULT_H_
|
||||
#define ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quotas/QuotasExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quotas
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUOTAS_EXPORT UpdateQuotaAlarmResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
UpdateQuotaAlarmResult();
|
||||
explicit UpdateQuotaAlarmResult(const std::string &payload);
|
||||
~UpdateQuotaAlarmResult();
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMRESULT_H_
|
||||
629
quotas/src/QuotasClient.cc
Normal file
629
quotas/src/QuotasClient.cc
Normal file
@@ -0,0 +1,629 @@
|
||||
/*
|
||||
* 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/quotas/QuotasClient.h>
|
||||
#include <alibabacloud/core/SimpleCredentialsProvider.h>
|
||||
|
||||
using namespace AlibabaCloud;
|
||||
using namespace AlibabaCloud::Location;
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
namespace
|
||||
{
|
||||
const std::string SERVICE_NAME = "quotas";
|
||||
}
|
||||
|
||||
QuotasClient::QuotasClient(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, "quotas");
|
||||
}
|
||||
|
||||
QuotasClient::QuotasClient(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, "quotas");
|
||||
}
|
||||
|
||||
QuotasClient::QuotasClient(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, "quotas");
|
||||
}
|
||||
|
||||
QuotasClient::~QuotasClient()
|
||||
{}
|
||||
|
||||
QuotasClient::CreateQuotaAlarmOutcome QuotasClient::createQuotaAlarm(const CreateQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return CreateQuotaAlarmOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return CreateQuotaAlarmOutcome(CreateQuotaAlarmResult(outcome.result()));
|
||||
else
|
||||
return CreateQuotaAlarmOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::createQuotaAlarmAsync(const CreateQuotaAlarmRequest& request, const CreateQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, createQuotaAlarm(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::CreateQuotaAlarmOutcomeCallable QuotasClient::createQuotaAlarmCallable(const CreateQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<CreateQuotaAlarmOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->createQuotaAlarm(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::CreateQuotaApplicationOutcome QuotasClient::createQuotaApplication(const CreateQuotaApplicationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return CreateQuotaApplicationOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return CreateQuotaApplicationOutcome(CreateQuotaApplicationResult(outcome.result()));
|
||||
else
|
||||
return CreateQuotaApplicationOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::createQuotaApplicationAsync(const CreateQuotaApplicationRequest& request, const CreateQuotaApplicationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, createQuotaApplication(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::CreateQuotaApplicationOutcomeCallable QuotasClient::createQuotaApplicationCallable(const CreateQuotaApplicationRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<CreateQuotaApplicationOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->createQuotaApplication(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::DeleteQuotaAlarmOutcome QuotasClient::deleteQuotaAlarm(const DeleteQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DeleteQuotaAlarmOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DeleteQuotaAlarmOutcome(DeleteQuotaAlarmResult(outcome.result()));
|
||||
else
|
||||
return DeleteQuotaAlarmOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::deleteQuotaAlarmAsync(const DeleteQuotaAlarmRequest& request, const DeleteQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, deleteQuotaAlarm(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::DeleteQuotaAlarmOutcomeCallable QuotasClient::deleteQuotaAlarmCallable(const DeleteQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DeleteQuotaAlarmOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->deleteQuotaAlarm(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::GetProductQuotaOutcome QuotasClient::getProductQuota(const GetProductQuotaRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GetProductQuotaOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GetProductQuotaOutcome(GetProductQuotaResult(outcome.result()));
|
||||
else
|
||||
return GetProductQuotaOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::getProductQuotaAsync(const GetProductQuotaRequest& request, const GetProductQuotaAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, getProductQuota(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::GetProductQuotaOutcomeCallable QuotasClient::getProductQuotaCallable(const GetProductQuotaRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GetProductQuotaOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->getProductQuota(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::GetProductQuotaDimensionOutcome QuotasClient::getProductQuotaDimension(const GetProductQuotaDimensionRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GetProductQuotaDimensionOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GetProductQuotaDimensionOutcome(GetProductQuotaDimensionResult(outcome.result()));
|
||||
else
|
||||
return GetProductQuotaDimensionOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::getProductQuotaDimensionAsync(const GetProductQuotaDimensionRequest& request, const GetProductQuotaDimensionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, getProductQuotaDimension(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::GetProductQuotaDimensionOutcomeCallable QuotasClient::getProductQuotaDimensionCallable(const GetProductQuotaDimensionRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GetProductQuotaDimensionOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->getProductQuotaDimension(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::GetQuotaAlarmOutcome QuotasClient::getQuotaAlarm(const GetQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GetQuotaAlarmOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GetQuotaAlarmOutcome(GetQuotaAlarmResult(outcome.result()));
|
||||
else
|
||||
return GetQuotaAlarmOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::getQuotaAlarmAsync(const GetQuotaAlarmRequest& request, const GetQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, getQuotaAlarm(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::GetQuotaAlarmOutcomeCallable QuotasClient::getQuotaAlarmCallable(const GetQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GetQuotaAlarmOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->getQuotaAlarm(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::GetQuotaApplicationOutcome QuotasClient::getQuotaApplication(const GetQuotaApplicationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GetQuotaApplicationOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GetQuotaApplicationOutcome(GetQuotaApplicationResult(outcome.result()));
|
||||
else
|
||||
return GetQuotaApplicationOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::getQuotaApplicationAsync(const GetQuotaApplicationRequest& request, const GetQuotaApplicationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, getQuotaApplication(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::GetQuotaApplicationOutcomeCallable QuotasClient::getQuotaApplicationCallable(const GetQuotaApplicationRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GetQuotaApplicationOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->getQuotaApplication(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListAlarmHistoriesOutcome QuotasClient::listAlarmHistories(const ListAlarmHistoriesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListAlarmHistoriesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListAlarmHistoriesOutcome(ListAlarmHistoriesResult(outcome.result()));
|
||||
else
|
||||
return ListAlarmHistoriesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listAlarmHistoriesAsync(const ListAlarmHistoriesRequest& request, const ListAlarmHistoriesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listAlarmHistories(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListAlarmHistoriesOutcomeCallable QuotasClient::listAlarmHistoriesCallable(const ListAlarmHistoriesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListAlarmHistoriesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listAlarmHistories(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListDependentQuotasOutcome QuotasClient::listDependentQuotas(const ListDependentQuotasRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListDependentQuotasOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListDependentQuotasOutcome(ListDependentQuotasResult(outcome.result()));
|
||||
else
|
||||
return ListDependentQuotasOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listDependentQuotasAsync(const ListDependentQuotasRequest& request, const ListDependentQuotasAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listDependentQuotas(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListDependentQuotasOutcomeCallable QuotasClient::listDependentQuotasCallable(const ListDependentQuotasRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListDependentQuotasOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listDependentQuotas(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListProductDimensionGroupsOutcome QuotasClient::listProductDimensionGroups(const ListProductDimensionGroupsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListProductDimensionGroupsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListProductDimensionGroupsOutcome(ListProductDimensionGroupsResult(outcome.result()));
|
||||
else
|
||||
return ListProductDimensionGroupsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listProductDimensionGroupsAsync(const ListProductDimensionGroupsRequest& request, const ListProductDimensionGroupsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listProductDimensionGroups(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListProductDimensionGroupsOutcomeCallable QuotasClient::listProductDimensionGroupsCallable(const ListProductDimensionGroupsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListProductDimensionGroupsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listProductDimensionGroups(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListProductQuotaDimensionsOutcome QuotasClient::listProductQuotaDimensions(const ListProductQuotaDimensionsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListProductQuotaDimensionsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListProductQuotaDimensionsOutcome(ListProductQuotaDimensionsResult(outcome.result()));
|
||||
else
|
||||
return ListProductQuotaDimensionsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listProductQuotaDimensionsAsync(const ListProductQuotaDimensionsRequest& request, const ListProductQuotaDimensionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listProductQuotaDimensions(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListProductQuotaDimensionsOutcomeCallable QuotasClient::listProductQuotaDimensionsCallable(const ListProductQuotaDimensionsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListProductQuotaDimensionsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listProductQuotaDimensions(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListProductQuotasOutcome QuotasClient::listProductQuotas(const ListProductQuotasRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListProductQuotasOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListProductQuotasOutcome(ListProductQuotasResult(outcome.result()));
|
||||
else
|
||||
return ListProductQuotasOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listProductQuotasAsync(const ListProductQuotasRequest& request, const ListProductQuotasAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listProductQuotas(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListProductQuotasOutcomeCallable QuotasClient::listProductQuotasCallable(const ListProductQuotasRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListProductQuotasOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listProductQuotas(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListProductsOutcome QuotasClient::listProducts(const ListProductsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListProductsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListProductsOutcome(ListProductsResult(outcome.result()));
|
||||
else
|
||||
return ListProductsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listProductsAsync(const ListProductsRequest& request, const ListProductsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listProducts(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListProductsOutcomeCallable QuotasClient::listProductsCallable(const ListProductsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListProductsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listProducts(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListQuotaAlarmsOutcome QuotasClient::listQuotaAlarms(const ListQuotaAlarmsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListQuotaAlarmsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListQuotaAlarmsOutcome(ListQuotaAlarmsResult(outcome.result()));
|
||||
else
|
||||
return ListQuotaAlarmsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listQuotaAlarmsAsync(const ListQuotaAlarmsRequest& request, const ListQuotaAlarmsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listQuotaAlarms(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListQuotaAlarmsOutcomeCallable QuotasClient::listQuotaAlarmsCallable(const ListQuotaAlarmsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListQuotaAlarmsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listQuotaAlarms(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::ListQuotaApplicationsOutcome QuotasClient::listQuotaApplications(const ListQuotaApplicationsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListQuotaApplicationsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListQuotaApplicationsOutcome(ListQuotaApplicationsResult(outcome.result()));
|
||||
else
|
||||
return ListQuotaApplicationsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::listQuotaApplicationsAsync(const ListQuotaApplicationsRequest& request, const ListQuotaApplicationsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listQuotaApplications(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::ListQuotaApplicationsOutcomeCallable QuotasClient::listQuotaApplicationsCallable(const ListQuotaApplicationsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListQuotaApplicationsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listQuotaApplications(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
QuotasClient::UpdateQuotaAlarmOutcome QuotasClient::updateQuotaAlarm(const UpdateQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return UpdateQuotaAlarmOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return UpdateQuotaAlarmOutcome(UpdateQuotaAlarmResult(outcome.result()));
|
||||
else
|
||||
return UpdateQuotaAlarmOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void QuotasClient::updateQuotaAlarmAsync(const UpdateQuotaAlarmRequest& request, const UpdateQuotaAlarmAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, updateQuotaAlarm(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
QuotasClient::UpdateQuotaAlarmOutcomeCallable QuotasClient::updateQuotaAlarmCallable(const UpdateQuotaAlarmRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<UpdateQuotaAlarmOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->updateQuotaAlarm(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
122
quotas/src/model/CreateQuotaAlarmRequest.cc
Normal file
122
quotas/src/model/CreateQuotaAlarmRequest.cc
Normal file
@@ -0,0 +1,122 @@
|
||||
/*
|
||||
* 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/quotas/model/CreateQuotaAlarmRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::CreateQuotaAlarmRequest;
|
||||
|
||||
CreateQuotaAlarmRequest::CreateQuotaAlarmRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "CreateQuotaAlarm")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
CreateQuotaAlarmRequest::~CreateQuotaAlarmRequest()
|
||||
{}
|
||||
|
||||
std::string CreateQuotaAlarmRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string CreateQuotaAlarmRequest::getWebHook()const
|
||||
{
|
||||
return webHook_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setWebHook(const std::string& webHook)
|
||||
{
|
||||
webHook_ = webHook;
|
||||
setBodyParameter("WebHook", webHook);
|
||||
}
|
||||
|
||||
float CreateQuotaAlarmRequest::getThreshold()const
|
||||
{
|
||||
return threshold_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setThreshold(float threshold)
|
||||
{
|
||||
threshold_ = threshold;
|
||||
setBodyParameter("Threshold", std::to_string(threshold));
|
||||
}
|
||||
|
||||
std::string CreateQuotaAlarmRequest::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setQuotaActionCode(const std::string& quotaActionCode)
|
||||
{
|
||||
quotaActionCode_ = quotaActionCode;
|
||||
setBodyParameter("QuotaActionCode", quotaActionCode);
|
||||
}
|
||||
|
||||
std::string CreateQuotaAlarmRequest::getThresholdType()const
|
||||
{
|
||||
return thresholdType_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setThresholdType(const std::string& thresholdType)
|
||||
{
|
||||
thresholdType_ = thresholdType;
|
||||
setBodyParameter("ThresholdType", thresholdType);
|
||||
}
|
||||
|
||||
std::vector<CreateQuotaAlarmRequest::QuotaDimensions> CreateQuotaAlarmRequest::getQuotaDimensions()const
|
||||
{
|
||||
return quotaDimensions_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setQuotaDimensions(const std::vector<QuotaDimensions>& quotaDimensions)
|
||||
{
|
||||
quotaDimensions_ = quotaDimensions;
|
||||
for(int dep1 = 0; dep1!= quotaDimensions.size(); dep1++) {
|
||||
auto quotaDimensionsObj = quotaDimensions.at(dep1);
|
||||
std::string quotaDimensionsObjStr = "QuotaDimensions." + std::to_string(dep1 + 1);
|
||||
setParameter(quotaDimensionsObjStr + ".Key", quotaDimensionsObj.key);
|
||||
setParameter(quotaDimensionsObjStr + ".Value", quotaDimensionsObj.value);
|
||||
}
|
||||
}
|
||||
|
||||
float CreateQuotaAlarmRequest::getThresholdPercent()const
|
||||
{
|
||||
return thresholdPercent_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setThresholdPercent(float thresholdPercent)
|
||||
{
|
||||
thresholdPercent_ = thresholdPercent;
|
||||
setBodyParameter("ThresholdPercent", std::to_string(thresholdPercent));
|
||||
}
|
||||
|
||||
std::string CreateQuotaAlarmRequest::getAlarmName()const
|
||||
{
|
||||
return alarmName_;
|
||||
}
|
||||
|
||||
void CreateQuotaAlarmRequest::setAlarmName(const std::string& alarmName)
|
||||
{
|
||||
alarmName_ = alarmName;
|
||||
setBodyParameter("AlarmName", alarmName);
|
||||
}
|
||||
|
||||
51
quotas/src/model/CreateQuotaAlarmResult.cc
Normal file
51
quotas/src/model/CreateQuotaAlarmResult.cc
Normal 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/quotas/model/CreateQuotaAlarmResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
CreateQuotaAlarmResult::CreateQuotaAlarmResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
CreateQuotaAlarmResult::CreateQuotaAlarmResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
CreateQuotaAlarmResult::~CreateQuotaAlarmResult()
|
||||
{}
|
||||
|
||||
void CreateQuotaAlarmResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
if(!value["AlarmId"].isNull())
|
||||
alarmId_ = value["AlarmId"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string CreateQuotaAlarmResult::getAlarmId()const
|
||||
{
|
||||
return alarmId_;
|
||||
}
|
||||
|
||||
122
quotas/src/model/CreateQuotaApplicationRequest.cc
Normal file
122
quotas/src/model/CreateQuotaApplicationRequest.cc
Normal file
@@ -0,0 +1,122 @@
|
||||
/*
|
||||
* 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/quotas/model/CreateQuotaApplicationRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::CreateQuotaApplicationRequest;
|
||||
|
||||
CreateQuotaApplicationRequest::CreateQuotaApplicationRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "CreateQuotaApplication")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
CreateQuotaApplicationRequest::~CreateQuotaApplicationRequest()
|
||||
{}
|
||||
|
||||
std::string CreateQuotaApplicationRequest::getReason()const
|
||||
{
|
||||
return reason_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setReason(const std::string& reason)
|
||||
{
|
||||
reason_ = reason;
|
||||
setBodyParameter("Reason", reason);
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationRequest::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setQuotaActionCode(const std::string& quotaActionCode)
|
||||
{
|
||||
quotaActionCode_ = quotaActionCode;
|
||||
setBodyParameter("QuotaActionCode", quotaActionCode);
|
||||
}
|
||||
|
||||
float CreateQuotaApplicationRequest::getDesireValue()const
|
||||
{
|
||||
return desireValue_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setDesireValue(float desireValue)
|
||||
{
|
||||
desireValue_ = desireValue;
|
||||
setBodyParameter("DesireValue", std::to_string(desireValue));
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationRequest::getQuotaCategory()const
|
||||
{
|
||||
return quotaCategory_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setQuotaCategory(const std::string& quotaCategory)
|
||||
{
|
||||
quotaCategory_ = quotaCategory;
|
||||
setBodyParameter("QuotaCategory", quotaCategory);
|
||||
}
|
||||
|
||||
int CreateQuotaApplicationRequest::getNoticeType()const
|
||||
{
|
||||
return noticeType_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setNoticeType(int noticeType)
|
||||
{
|
||||
noticeType_ = noticeType;
|
||||
setBodyParameter("NoticeType", std::to_string(noticeType));
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationRequest::getAuditMode()const
|
||||
{
|
||||
return auditMode_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setAuditMode(const std::string& auditMode)
|
||||
{
|
||||
auditMode_ = auditMode;
|
||||
setBodyParameter("AuditMode", auditMode);
|
||||
}
|
||||
|
||||
std::vector<CreateQuotaApplicationRequest::Dimensions> CreateQuotaApplicationRequest::getDimensions()const
|
||||
{
|
||||
return dimensions_;
|
||||
}
|
||||
|
||||
void CreateQuotaApplicationRequest::setDimensions(const std::vector<Dimensions>& dimensions)
|
||||
{
|
||||
dimensions_ = dimensions;
|
||||
for(int dep1 = 0; dep1!= dimensions.size(); dep1++) {
|
||||
auto dimensionsObj = dimensions.at(dep1);
|
||||
std::string dimensionsObjStr = "Dimensions." + std::to_string(dep1 + 1);
|
||||
setParameter(dimensionsObjStr + ".Key", dimensionsObj.key);
|
||||
setParameter(dimensionsObjStr + ".Value", dimensionsObj.value);
|
||||
}
|
||||
}
|
||||
|
||||
163
quotas/src/model/CreateQuotaApplicationResult.cc
Normal file
163
quotas/src/model/CreateQuotaApplicationResult.cc
Normal file
@@ -0,0 +1,163 @@
|
||||
/*
|
||||
* 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/quotas/model/CreateQuotaApplicationResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
CreateQuotaApplicationResult::CreateQuotaApplicationResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
CreateQuotaApplicationResult::CreateQuotaApplicationResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
CreateQuotaApplicationResult::~CreateQuotaApplicationResult()
|
||||
{}
|
||||
|
||||
void CreateQuotaApplicationResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
if(!value["Status"].isNull())
|
||||
status_ = value["Status"].asString();
|
||||
if(!value["ApplyTime"].isNull())
|
||||
applyTime_ = value["ApplyTime"].asString();
|
||||
if(!value["QuotaDescription"].isNull())
|
||||
quotaDescription_ = value["QuotaDescription"].asString();
|
||||
if(!value["EffectiveTime"].isNull())
|
||||
effectiveTime_ = value["EffectiveTime"].asString();
|
||||
if(!value["ProductCode"].isNull())
|
||||
productCode_ = value["ProductCode"].asString();
|
||||
if(!value["QuotaUnit"].isNull())
|
||||
quotaUnit_ = value["QuotaUnit"].asString();
|
||||
if(!value["AuditReason"].isNull())
|
||||
auditReason_ = value["AuditReason"].asString();
|
||||
if(!value["Dimension"].isNull())
|
||||
dimension_ = value["Dimension"].asString();
|
||||
if(!value["ApproveValue"].isNull())
|
||||
approveValue_ = std::stof(value["ApproveValue"].asString());
|
||||
if(!value["Reason"].isNull())
|
||||
reason_ = value["Reason"].asString();
|
||||
if(!value["QuotaActionCode"].isNull())
|
||||
quotaActionCode_ = value["QuotaActionCode"].asString();
|
||||
if(!value["QuotaName"].isNull())
|
||||
quotaName_ = value["QuotaName"].asString();
|
||||
if(!value["QuotaArn"].isNull())
|
||||
quotaArn_ = value["QuotaArn"].asString();
|
||||
if(!value["NoticeType"].isNull())
|
||||
noticeType_ = std::stol(value["NoticeType"].asString());
|
||||
if(!value["ExpireTime"].isNull())
|
||||
expireTime_ = value["ExpireTime"].asString();
|
||||
if(!value["ApplicationId"].isNull())
|
||||
applicationId_ = value["ApplicationId"].asString();
|
||||
if(!value["DesireValue"].isNull())
|
||||
desireValue_ = std::stoi(value["DesireValue"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getStatus()const
|
||||
{
|
||||
return status_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getApplyTime()const
|
||||
{
|
||||
return applyTime_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getQuotaDescription()const
|
||||
{
|
||||
return quotaDescription_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getEffectiveTime()const
|
||||
{
|
||||
return effectiveTime_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getQuotaUnit()const
|
||||
{
|
||||
return quotaUnit_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getAuditReason()const
|
||||
{
|
||||
return auditReason_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getDimension()const
|
||||
{
|
||||
return dimension_;
|
||||
}
|
||||
|
||||
float CreateQuotaApplicationResult::getApproveValue()const
|
||||
{
|
||||
return approveValue_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getReason()const
|
||||
{
|
||||
return reason_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getQuotaName()const
|
||||
{
|
||||
return quotaName_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getQuotaArn()const
|
||||
{
|
||||
return quotaArn_;
|
||||
}
|
||||
|
||||
long CreateQuotaApplicationResult::getNoticeType()const
|
||||
{
|
||||
return noticeType_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getExpireTime()const
|
||||
{
|
||||
return expireTime_;
|
||||
}
|
||||
|
||||
std::string CreateQuotaApplicationResult::getApplicationId()const
|
||||
{
|
||||
return applicationId_;
|
||||
}
|
||||
|
||||
int CreateQuotaApplicationResult::getDesireValue()const
|
||||
{
|
||||
return desireValue_;
|
||||
}
|
||||
|
||||
40
quotas/src/model/DeleteQuotaAlarmRequest.cc
Normal file
40
quotas/src/model/DeleteQuotaAlarmRequest.cc
Normal file
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/DeleteQuotaAlarmRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::DeleteQuotaAlarmRequest;
|
||||
|
||||
DeleteQuotaAlarmRequest::DeleteQuotaAlarmRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "DeleteQuotaAlarm")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DeleteQuotaAlarmRequest::~DeleteQuotaAlarmRequest()
|
||||
{}
|
||||
|
||||
std::string DeleteQuotaAlarmRequest::getAlarmId()const
|
||||
{
|
||||
return alarmId_;
|
||||
}
|
||||
|
||||
void DeleteQuotaAlarmRequest::setAlarmId(const std::string& alarmId)
|
||||
{
|
||||
alarmId_ = alarmId;
|
||||
setBodyParameter("AlarmId", alarmId);
|
||||
}
|
||||
|
||||
44
quotas/src/model/DeleteQuotaAlarmResult.cc
Normal file
44
quotas/src/model/DeleteQuotaAlarmResult.cc
Normal 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/quotas/model/DeleteQuotaAlarmResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
DeleteQuotaAlarmResult::DeleteQuotaAlarmResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DeleteQuotaAlarmResult::DeleteQuotaAlarmResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DeleteQuotaAlarmResult::~DeleteQuotaAlarmResult()
|
||||
{}
|
||||
|
||||
void DeleteQuotaAlarmResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
67
quotas/src/model/GetProductQuotaDimensionRequest.cc
Normal file
67
quotas/src/model/GetProductQuotaDimensionRequest.cc
Normal file
@@ -0,0 +1,67 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/GetProductQuotaDimensionRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::GetProductQuotaDimensionRequest;
|
||||
|
||||
GetProductQuotaDimensionRequest::GetProductQuotaDimensionRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "GetProductQuotaDimension")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
GetProductQuotaDimensionRequest::~GetProductQuotaDimensionRequest()
|
||||
{}
|
||||
|
||||
std::string GetProductQuotaDimensionRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void GetProductQuotaDimensionRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::vector<GetProductQuotaDimensionRequest::DependentDimensions> GetProductQuotaDimensionRequest::getDependentDimensions()const
|
||||
{
|
||||
return dependentDimensions_;
|
||||
}
|
||||
|
||||
void GetProductQuotaDimensionRequest::setDependentDimensions(const std::vector<DependentDimensions>& dependentDimensions)
|
||||
{
|
||||
dependentDimensions_ = dependentDimensions;
|
||||
for(int dep1 = 0; dep1!= dependentDimensions.size(); dep1++) {
|
||||
auto dependentDimensionsObj = dependentDimensions.at(dep1);
|
||||
std::string dependentDimensionsObjStr = "DependentDimensions." + std::to_string(dep1 + 1);
|
||||
setParameter(dependentDimensionsObjStr + ".Key", dependentDimensionsObj.key);
|
||||
setParameter(dependentDimensionsObjStr + ".Value", dependentDimensionsObj.value);
|
||||
}
|
||||
}
|
||||
|
||||
std::string GetProductQuotaDimensionRequest::getDimensionKey()const
|
||||
{
|
||||
return dimensionKey_;
|
||||
}
|
||||
|
||||
void GetProductQuotaDimensionRequest::setDimensionKey(const std::string& dimensionKey)
|
||||
{
|
||||
dimensionKey_ = dimensionKey;
|
||||
setBodyParameter("DimensionKey", dimensionKey);
|
||||
}
|
||||
|
||||
70
quotas/src/model/GetProductQuotaDimensionResult.cc
Normal file
70
quotas/src/model/GetProductQuotaDimensionResult.cc
Normal 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/quotas/model/GetProductQuotaDimensionResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
GetProductQuotaDimensionResult::GetProductQuotaDimensionResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GetProductQuotaDimensionResult::GetProductQuotaDimensionResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GetProductQuotaDimensionResult::~GetProductQuotaDimensionResult()
|
||||
{}
|
||||
|
||||
void GetProductQuotaDimensionResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto quotaDimensionNode = value["QuotaDimension"];
|
||||
if(!quotaDimensionNode["DimensionKey"].isNull())
|
||||
quotaDimension_.dimensionKey = quotaDimensionNode["DimensionKey"].asString();
|
||||
if(!quotaDimensionNode["Name"].isNull())
|
||||
quotaDimension_.name = quotaDimensionNode["Name"].asString();
|
||||
auto allDimensionValueDetailNode = quotaDimensionNode["DimensionValueDetail"]["DimensionValueDetailItem"];
|
||||
for (auto quotaDimensionNodeDimensionValueDetailDimensionValueDetailItem : allDimensionValueDetailNode)
|
||||
{
|
||||
QuotaDimension::DimensionValueDetailItem dimensionValueDetailItemObject;
|
||||
if(!quotaDimensionNodeDimensionValueDetailDimensionValueDetailItem["Value"].isNull())
|
||||
dimensionValueDetailItemObject.value = quotaDimensionNodeDimensionValueDetailDimensionValueDetailItem["Value"].asString();
|
||||
if(!quotaDimensionNodeDimensionValueDetailDimensionValueDetailItem["Name"].isNull())
|
||||
dimensionValueDetailItemObject.name = quotaDimensionNodeDimensionValueDetailDimensionValueDetailItem["Name"].asString();
|
||||
quotaDimension_.dimensionValueDetail.push_back(dimensionValueDetailItemObject);
|
||||
}
|
||||
auto allDimensionValues = quotaDimensionNode["DimensionValues"]["DimensionValues"];
|
||||
for (auto value : allDimensionValues)
|
||||
quotaDimension_.dimensionValues.push_back(value.asString());
|
||||
auto allDependentDimensions = quotaDimensionNode["DependentDimensions"]["DependentDimensions"];
|
||||
for (auto value : allDependentDimensions)
|
||||
quotaDimension_.dependentDimensions.push_back(value.asString());
|
||||
|
||||
}
|
||||
|
||||
GetProductQuotaDimensionResult::QuotaDimension GetProductQuotaDimensionResult::getQuotaDimension()const
|
||||
{
|
||||
return quotaDimension_;
|
||||
}
|
||||
|
||||
67
quotas/src/model/GetProductQuotaRequest.cc
Normal file
67
quotas/src/model/GetProductQuotaRequest.cc
Normal file
@@ -0,0 +1,67 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/GetProductQuotaRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::GetProductQuotaRequest;
|
||||
|
||||
GetProductQuotaRequest::GetProductQuotaRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "GetProductQuota")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
GetProductQuotaRequest::~GetProductQuotaRequest()
|
||||
{}
|
||||
|
||||
std::string GetProductQuotaRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void GetProductQuotaRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string GetProductQuotaRequest::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
void GetProductQuotaRequest::setQuotaActionCode(const std::string& quotaActionCode)
|
||||
{
|
||||
quotaActionCode_ = quotaActionCode;
|
||||
setBodyParameter("QuotaActionCode", quotaActionCode);
|
||||
}
|
||||
|
||||
std::vector<GetProductQuotaRequest::Dimensions> GetProductQuotaRequest::getDimensions()const
|
||||
{
|
||||
return dimensions_;
|
||||
}
|
||||
|
||||
void GetProductQuotaRequest::setDimensions(const std::vector<Dimensions>& dimensions)
|
||||
{
|
||||
dimensions_ = dimensions;
|
||||
for(int dep1 = 0; dep1!= dimensions.size(); dep1++) {
|
||||
auto dimensionsObj = dimensions.at(dep1);
|
||||
std::string dimensionsObjStr = "Dimensions." + std::to_string(dep1 + 1);
|
||||
setParameter(dimensionsObjStr + ".Key", dimensionsObj.key);
|
||||
setParameter(dimensionsObjStr + ".Value", dimensionsObj.value);
|
||||
}
|
||||
}
|
||||
|
||||
100
quotas/src/model/GetProductQuotaResult.cc
Normal file
100
quotas/src/model/GetProductQuotaResult.cc
Normal file
@@ -0,0 +1,100 @@
|
||||
/*
|
||||
* 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/quotas/model/GetProductQuotaResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
GetProductQuotaResult::GetProductQuotaResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GetProductQuotaResult::GetProductQuotaResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GetProductQuotaResult::~GetProductQuotaResult()
|
||||
{}
|
||||
|
||||
void GetProductQuotaResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto quotaNode = value["Quota"];
|
||||
if(!quotaNode["QuotaDescription"].isNull())
|
||||
quota_.quotaDescription = quotaNode["QuotaDescription"].asString();
|
||||
if(!quotaNode["Consumable"].isNull())
|
||||
quota_.consumable = quotaNode["Consumable"].asString() == "true";
|
||||
if(!quotaNode["UnadjustableDetail"].isNull())
|
||||
quota_.unadjustableDetail = quotaNode["UnadjustableDetail"].asString();
|
||||
if(!quotaNode["ProductCode"].isNull())
|
||||
quota_.productCode = quotaNode["ProductCode"].asString();
|
||||
if(!quotaNode["TotalUsage"].isNull())
|
||||
quota_.totalUsage = std::stof(quotaNode["TotalUsage"].asString());
|
||||
if(!quotaNode["QuotaType"].isNull())
|
||||
quota_.quotaType = quotaNode["QuotaType"].asString();
|
||||
if(!quotaNode["Dimensions"].isNull())
|
||||
quota_.dimensions = quotaNode["Dimensions"].asString();
|
||||
if(!quotaNode["QuotaUnit"].isNull())
|
||||
quota_.quotaUnit = quotaNode["QuotaUnit"].asString();
|
||||
if(!quotaNode["Adjustable"].isNull())
|
||||
quota_.adjustable = quotaNode["Adjustable"].asString() == "true";
|
||||
if(!quotaNode["QuotaActionCode"].isNull())
|
||||
quota_.quotaActionCode = quotaNode["QuotaActionCode"].asString();
|
||||
if(!quotaNode["QuotaName"].isNull())
|
||||
quota_.quotaName = quotaNode["QuotaName"].asString();
|
||||
if(!quotaNode["QuotaArn"].isNull())
|
||||
quota_.quotaArn = quotaNode["QuotaArn"].asString();
|
||||
if(!quotaNode["TotalQuota"].isNull())
|
||||
quota_.totalQuota = std::stof(quotaNode["TotalQuota"].asString());
|
||||
if(!quotaNode["ApplicableType"].isNull())
|
||||
quota_.applicableType = quotaNode["ApplicableType"].asString();
|
||||
auto allQuotaItemsNode = quotaNode["QuotaItems"]["QuotaItemsItem"];
|
||||
for (auto quotaNodeQuotaItemsQuotaItemsItem : allQuotaItemsNode)
|
||||
{
|
||||
Quota::QuotaItemsItem quotaItemsItemObject;
|
||||
if(!quotaNodeQuotaItemsQuotaItemsItem["Usage"].isNull())
|
||||
quotaItemsItemObject.usage = quotaNodeQuotaItemsQuotaItemsItem["Usage"].asString();
|
||||
if(!quotaNodeQuotaItemsQuotaItemsItem["Type"].isNull())
|
||||
quotaItemsItemObject.type = quotaNodeQuotaItemsQuotaItemsItem["Type"].asString();
|
||||
if(!quotaNodeQuotaItemsQuotaItemsItem["Quota"].isNull())
|
||||
quotaItemsItemObject.quota = quotaNodeQuotaItemsQuotaItemsItem["Quota"].asString();
|
||||
if(!quotaNodeQuotaItemsQuotaItemsItem["QuotaUnit"].isNull())
|
||||
quotaItemsItemObject.quotaUnit = quotaNodeQuotaItemsQuotaItemsItem["QuotaUnit"].asString();
|
||||
quota_.quotaItems.push_back(quotaItemsItemObject);
|
||||
}
|
||||
auto periodNode = quotaNode["Period"];
|
||||
if(!periodNode["PeriodValue"].isNull())
|
||||
quota_.period.periodValue = std::stoi(periodNode["PeriodValue"].asString());
|
||||
if(!periodNode["PeriodUnit"].isNull())
|
||||
quota_.period.periodUnit = periodNode["PeriodUnit"].asString();
|
||||
auto allApplicableRange = quotaNode["ApplicableRange"]["ApplicableRange"];
|
||||
for (auto value : allApplicableRange)
|
||||
quota_.applicableRange.push_back(value.asString());
|
||||
|
||||
}
|
||||
|
||||
GetProductQuotaResult::Quota GetProductQuotaResult::getQuota()const
|
||||
{
|
||||
return quota_;
|
||||
}
|
||||
|
||||
40
quotas/src/model/GetQuotaAlarmRequest.cc
Normal file
40
quotas/src/model/GetQuotaAlarmRequest.cc
Normal file
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/GetQuotaAlarmRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::GetQuotaAlarmRequest;
|
||||
|
||||
GetQuotaAlarmRequest::GetQuotaAlarmRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "GetQuotaAlarm")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
GetQuotaAlarmRequest::~GetQuotaAlarmRequest()
|
||||
{}
|
||||
|
||||
std::string GetQuotaAlarmRequest::getAlarmId()const
|
||||
{
|
||||
return alarmId_;
|
||||
}
|
||||
|
||||
void GetQuotaAlarmRequest::setAlarmId(const std::string& alarmId)
|
||||
{
|
||||
alarmId_ = alarmId;
|
||||
setBodyParameter("AlarmId", alarmId);
|
||||
}
|
||||
|
||||
77
quotas/src/model/GetQuotaAlarmResult.cc
Normal file
77
quotas/src/model/GetQuotaAlarmResult.cc
Normal 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/quotas/model/GetQuotaAlarmResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
GetQuotaAlarmResult::GetQuotaAlarmResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GetQuotaAlarmResult::GetQuotaAlarmResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GetQuotaAlarmResult::~GetQuotaAlarmResult()
|
||||
{}
|
||||
|
||||
void GetQuotaAlarmResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto quotaAlarmNode = value["QuotaAlarm"];
|
||||
if(!quotaAlarmNode["AlarmId"].isNull())
|
||||
quotaAlarm_.alarmId = quotaAlarmNode["AlarmId"].asString();
|
||||
if(!quotaAlarmNode["QuotaActionCode"].isNull())
|
||||
quotaAlarm_.quotaActionCode = quotaAlarmNode["QuotaActionCode"].asString();
|
||||
if(!quotaAlarmNode["QuotaValue"].isNull())
|
||||
quotaAlarm_.quotaValue = std::stof(quotaAlarmNode["QuotaValue"].asString());
|
||||
if(!quotaAlarmNode["ThresholdPercent"].isNull())
|
||||
quotaAlarm_.thresholdPercent = std::stof(quotaAlarmNode["ThresholdPercent"].asString());
|
||||
if(!quotaAlarmNode["AlarmName"].isNull())
|
||||
quotaAlarm_.alarmName = quotaAlarmNode["AlarmName"].asString();
|
||||
if(!quotaAlarmNode["ProductCode"].isNull())
|
||||
quotaAlarm_.productCode = quotaAlarmNode["ProductCode"].asString();
|
||||
if(!quotaAlarmNode["NotifyTarget"].isNull())
|
||||
quotaAlarm_.notifyTarget = quotaAlarmNode["NotifyTarget"].asString();
|
||||
if(!quotaAlarmNode["CreateTime"].isNull())
|
||||
quotaAlarm_.createTime = quotaAlarmNode["CreateTime"].asString();
|
||||
if(!quotaAlarmNode["QuotaDimension"].isNull())
|
||||
quotaAlarm_.quotaDimension = quotaAlarmNode["QuotaDimension"].asString();
|
||||
if(!quotaAlarmNode["QuotaUsage"].isNull())
|
||||
quotaAlarm_.quotaUsage = std::stof(quotaAlarmNode["QuotaUsage"].asString());
|
||||
if(!quotaAlarmNode["Threshold"].isNull())
|
||||
quotaAlarm_.threshold = std::stof(quotaAlarmNode["Threshold"].asString());
|
||||
if(!quotaAlarmNode["ThresholdType"].isNull())
|
||||
quotaAlarm_.thresholdType = quotaAlarmNode["ThresholdType"].asString();
|
||||
auto allNotifyChannels = quotaAlarmNode["NotifyChannels"]["NotifyChannels"];
|
||||
for (auto value : allNotifyChannels)
|
||||
quotaAlarm_.notifyChannels.push_back(value.asString());
|
||||
|
||||
}
|
||||
|
||||
GetQuotaAlarmResult::QuotaAlarm GetQuotaAlarmResult::getQuotaAlarm()const
|
||||
{
|
||||
return quotaAlarm_;
|
||||
}
|
||||
|
||||
40
quotas/src/model/GetQuotaApplicationRequest.cc
Normal file
40
quotas/src/model/GetQuotaApplicationRequest.cc
Normal file
@@ -0,0 +1,40 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/GetQuotaApplicationRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::GetQuotaApplicationRequest;
|
||||
|
||||
GetQuotaApplicationRequest::GetQuotaApplicationRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "GetQuotaApplication")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
GetQuotaApplicationRequest::~GetQuotaApplicationRequest()
|
||||
{}
|
||||
|
||||
std::string GetQuotaApplicationRequest::getApplicationId()const
|
||||
{
|
||||
return applicationId_;
|
||||
}
|
||||
|
||||
void GetQuotaApplicationRequest::setApplicationId(const std::string& applicationId)
|
||||
{
|
||||
applicationId_ = applicationId;
|
||||
setBodyParameter("ApplicationId", applicationId);
|
||||
}
|
||||
|
||||
84
quotas/src/model/GetQuotaApplicationResult.cc
Normal file
84
quotas/src/model/GetQuotaApplicationResult.cc
Normal 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/quotas/model/GetQuotaApplicationResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
GetQuotaApplicationResult::GetQuotaApplicationResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GetQuotaApplicationResult::GetQuotaApplicationResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GetQuotaApplicationResult::~GetQuotaApplicationResult()
|
||||
{}
|
||||
|
||||
void GetQuotaApplicationResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto quotaApplicationNode = value["QuotaApplication"];
|
||||
if(!quotaApplicationNode["Status"].isNull())
|
||||
quotaApplication_.status = quotaApplicationNode["Status"].asString();
|
||||
if(!quotaApplicationNode["ApplyTime"].isNull())
|
||||
quotaApplication_.applyTime = quotaApplicationNode["ApplyTime"].asString();
|
||||
if(!quotaApplicationNode["QuotaDescription"].isNull())
|
||||
quotaApplication_.quotaDescription = quotaApplicationNode["QuotaDescription"].asString();
|
||||
if(!quotaApplicationNode["EffectiveTime"].isNull())
|
||||
quotaApplication_.effectiveTime = quotaApplicationNode["EffectiveTime"].asString();
|
||||
if(!quotaApplicationNode["ProductCode"].isNull())
|
||||
quotaApplication_.productCode = quotaApplicationNode["ProductCode"].asString();
|
||||
if(!quotaApplicationNode["QuotaUnit"].isNull())
|
||||
quotaApplication_.quotaUnit = quotaApplicationNode["QuotaUnit"].asString();
|
||||
if(!quotaApplicationNode["AuditReason"].isNull())
|
||||
quotaApplication_.auditReason = quotaApplicationNode["AuditReason"].asString();
|
||||
if(!quotaApplicationNode["Dimension"].isNull())
|
||||
quotaApplication_.dimension = quotaApplicationNode["Dimension"].asString();
|
||||
if(!quotaApplicationNode["ApproveValue"].isNull())
|
||||
quotaApplication_.approveValue = std::stof(quotaApplicationNode["ApproveValue"].asString());
|
||||
if(!quotaApplicationNode["Reason"].isNull())
|
||||
quotaApplication_.reason = quotaApplicationNode["Reason"].asString();
|
||||
if(!quotaApplicationNode["QuotaActionCode"].isNull())
|
||||
quotaApplication_.quotaActionCode = quotaApplicationNode["QuotaActionCode"].asString();
|
||||
if(!quotaApplicationNode["QuotaName"].isNull())
|
||||
quotaApplication_.quotaName = quotaApplicationNode["QuotaName"].asString();
|
||||
if(!quotaApplicationNode["QuotaArn"].isNull())
|
||||
quotaApplication_.quotaArn = quotaApplicationNode["QuotaArn"].asString();
|
||||
if(!quotaApplicationNode["NoticeType"].isNull())
|
||||
quotaApplication_.noticeType = std::stol(quotaApplicationNode["NoticeType"].asString());
|
||||
if(!quotaApplicationNode["ExpireTime"].isNull())
|
||||
quotaApplication_.expireTime = quotaApplicationNode["ExpireTime"].asString();
|
||||
if(!quotaApplicationNode["ApplicationId"].isNull())
|
||||
quotaApplication_.applicationId = quotaApplicationNode["ApplicationId"].asString();
|
||||
if(!quotaApplicationNode["DesireValue"].isNull())
|
||||
quotaApplication_.desireValue = std::stoi(quotaApplicationNode["DesireValue"].asString());
|
||||
|
||||
}
|
||||
|
||||
GetQuotaApplicationResult::QuotaApplication GetQuotaApplicationResult::getQuotaApplication()const
|
||||
{
|
||||
return quotaApplication_;
|
||||
}
|
||||
|
||||
95
quotas/src/model/ListAlarmHistoriesRequest.cc
Normal file
95
quotas/src/model/ListAlarmHistoriesRequest.cc
Normal file
@@ -0,0 +1,95 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/ListAlarmHistoriesRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListAlarmHistoriesRequest;
|
||||
|
||||
ListAlarmHistoriesRequest::ListAlarmHistoriesRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListAlarmHistories")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListAlarmHistoriesRequest::~ListAlarmHistoriesRequest()
|
||||
{}
|
||||
|
||||
std::string ListAlarmHistoriesRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void ListAlarmHistoriesRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
long ListAlarmHistoriesRequest::getStartTime()const
|
||||
{
|
||||
return startTime_;
|
||||
}
|
||||
|
||||
void ListAlarmHistoriesRequest::setStartTime(long startTime)
|
||||
{
|
||||
startTime_ = startTime;
|
||||
setBodyParameter("StartTime", std::to_string(startTime));
|
||||
}
|
||||
|
||||
std::string ListAlarmHistoriesRequest::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListAlarmHistoriesRequest::setNextToken(const std::string& nextToken)
|
||||
{
|
||||
nextToken_ = nextToken;
|
||||
setBodyParameter("NextToken", nextToken);
|
||||
}
|
||||
|
||||
std::string ListAlarmHistoriesRequest::getKeyword()const
|
||||
{
|
||||
return keyword_;
|
||||
}
|
||||
|
||||
void ListAlarmHistoriesRequest::setKeyword(const std::string& keyword)
|
||||
{
|
||||
keyword_ = keyword;
|
||||
setBodyParameter("Keyword", keyword);
|
||||
}
|
||||
|
||||
long ListAlarmHistoriesRequest::getEndTime()const
|
||||
{
|
||||
return endTime_;
|
||||
}
|
||||
|
||||
void ListAlarmHistoriesRequest::setEndTime(long endTime)
|
||||
{
|
||||
endTime_ = endTime;
|
||||
setBodyParameter("EndTime", std::to_string(endTime));
|
||||
}
|
||||
|
||||
int ListAlarmHistoriesRequest::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListAlarmHistoriesRequest::setMaxResults(int maxResults)
|
||||
{
|
||||
maxResults_ = maxResults;
|
||||
setBodyParameter("MaxResults", std::to_string(maxResults));
|
||||
}
|
||||
|
||||
95
quotas/src/model/ListAlarmHistoriesResult.cc
Normal file
95
quotas/src/model/ListAlarmHistoriesResult.cc
Normal file
@@ -0,0 +1,95 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/ListAlarmHistoriesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListAlarmHistoriesResult::ListAlarmHistoriesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListAlarmHistoriesResult::ListAlarmHistoriesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListAlarmHistoriesResult::~ListAlarmHistoriesResult()
|
||||
{}
|
||||
|
||||
void ListAlarmHistoriesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allAlarmHistoriesNode = value["AlarmHistories"]["AlarmHistory"];
|
||||
for (auto valueAlarmHistoriesAlarmHistory : allAlarmHistoriesNode)
|
||||
{
|
||||
AlarmHistory alarmHistoriesObject;
|
||||
if(!valueAlarmHistoriesAlarmHistory["AlarmName"].isNull())
|
||||
alarmHistoriesObject.alarmName = valueAlarmHistoriesAlarmHistory["AlarmName"].asString();
|
||||
if(!valueAlarmHistoriesAlarmHistory["QuotaUsage"].isNull())
|
||||
alarmHistoriesObject.quotaUsage = std::stof(valueAlarmHistoriesAlarmHistory["QuotaUsage"].asString());
|
||||
if(!valueAlarmHistoriesAlarmHistory["ProductCode"].isNull())
|
||||
alarmHistoriesObject.productCode = valueAlarmHistoriesAlarmHistory["ProductCode"].asString();
|
||||
if(!valueAlarmHistoriesAlarmHistory["CreateTime"].isNull())
|
||||
alarmHistoriesObject.createTime = valueAlarmHistoriesAlarmHistory["CreateTime"].asString();
|
||||
if(!valueAlarmHistoriesAlarmHistory["NotifyTarget"].isNull())
|
||||
alarmHistoriesObject.notifyTarget = valueAlarmHistoriesAlarmHistory["NotifyTarget"].asString();
|
||||
if(!valueAlarmHistoriesAlarmHistory["Threshold"].isNull())
|
||||
alarmHistoriesObject.threshold = std::stof(valueAlarmHistoriesAlarmHistory["Threshold"].asString());
|
||||
if(!valueAlarmHistoriesAlarmHistory["ThresholdPercent"].isNull())
|
||||
alarmHistoriesObject.thresholdPercent = std::stof(valueAlarmHistoriesAlarmHistory["ThresholdPercent"].asString());
|
||||
if(!valueAlarmHistoriesAlarmHistory["QuotaActionCode"].isNull())
|
||||
alarmHistoriesObject.quotaActionCode = valueAlarmHistoriesAlarmHistory["QuotaActionCode"].asString();
|
||||
auto allNotifyChannels = value["NotifyChannels"]["NotifyChannels"];
|
||||
for (auto value : allNotifyChannels)
|
||||
alarmHistoriesObject.notifyChannels.push_back(value.asString());
|
||||
alarmHistories_.push_back(alarmHistoriesObject);
|
||||
}
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
|
||||
}
|
||||
|
||||
int ListAlarmHistoriesResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListAlarmHistoriesResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
int ListAlarmHistoriesResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
std::vector<ListAlarmHistoriesResult::AlarmHistory> ListAlarmHistoriesResult::getAlarmHistories()const
|
||||
{
|
||||
return alarmHistories_;
|
||||
}
|
||||
|
||||
51
quotas/src/model/ListDependentQuotasRequest.cc
Normal file
51
quotas/src/model/ListDependentQuotasRequest.cc
Normal 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/quotas/model/ListDependentQuotasRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListDependentQuotasRequest;
|
||||
|
||||
ListDependentQuotasRequest::ListDependentQuotasRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListDependentQuotas")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListDependentQuotasRequest::~ListDependentQuotasRequest()
|
||||
{}
|
||||
|
||||
std::string ListDependentQuotasRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void ListDependentQuotasRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string ListDependentQuotasRequest::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
void ListDependentQuotasRequest::setQuotaActionCode(const std::string& quotaActionCode)
|
||||
{
|
||||
quotaActionCode_ = quotaActionCode;
|
||||
setBodyParameter("QuotaActionCode", quotaActionCode);
|
||||
}
|
||||
|
||||
75
quotas/src/model/ListDependentQuotasResult.cc
Normal file
75
quotas/src/model/ListDependentQuotasResult.cc
Normal file
@@ -0,0 +1,75 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/ListDependentQuotasResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListDependentQuotasResult::ListDependentQuotasResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListDependentQuotasResult::ListDependentQuotasResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListDependentQuotasResult::~ListDependentQuotasResult()
|
||||
{}
|
||||
|
||||
void ListDependentQuotasResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allQuotasNode = value["Quotas"]["QuotasItem"];
|
||||
for (auto valueQuotasQuotasItem : allQuotasNode)
|
||||
{
|
||||
QuotasItem quotasObject;
|
||||
if(!valueQuotasQuotasItem["QuotaActionCode"].isNull())
|
||||
quotasObject.quotaActionCode = valueQuotasQuotasItem["QuotaActionCode"].asString();
|
||||
if(!valueQuotasQuotasItem["ProductCode"].isNull())
|
||||
quotasObject.productCode = valueQuotasQuotasItem["ProductCode"].asString();
|
||||
if(!valueQuotasQuotasItem["Scale"].isNull())
|
||||
quotasObject.scale = std::stof(valueQuotasQuotasItem["Scale"].asString());
|
||||
auto allDimensionsNode = valueQuotasQuotasItem["Dimensions"]["DimensionsItem"];
|
||||
for (auto valueQuotasQuotasItemDimensionsDimensionsItem : allDimensionsNode)
|
||||
{
|
||||
QuotasItem::DimensionsItem dimensionsObject;
|
||||
if(!valueQuotasQuotasItemDimensionsDimensionsItem["DimensionKey"].isNull())
|
||||
dimensionsObject.dimensionKey = valueQuotasQuotasItemDimensionsDimensionsItem["DimensionKey"].asString();
|
||||
auto allDimensionValues = value["DimensionValues"]["DimensionValues"];
|
||||
for (auto value : allDimensionValues)
|
||||
dimensionsObject.dimensionValues.push_back(value.asString());
|
||||
auto allDependentDimension = value["DependentDimension"]["DependentDimension"];
|
||||
for (auto value : allDependentDimension)
|
||||
dimensionsObject.dependentDimension.push_back(value.asString());
|
||||
quotasObject.dimensions.push_back(dimensionsObject);
|
||||
}
|
||||
quotas_.push_back(quotasObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
std::vector<ListDependentQuotasResult::QuotasItem> ListDependentQuotasResult::getQuotas()const
|
||||
{
|
||||
return quotas_;
|
||||
}
|
||||
|
||||
62
quotas/src/model/ListProductDimensionGroupsRequest.cc
Normal file
62
quotas/src/model/ListProductDimensionGroupsRequest.cc
Normal file
@@ -0,0 +1,62 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/ListProductDimensionGroupsRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListProductDimensionGroupsRequest;
|
||||
|
||||
ListProductDimensionGroupsRequest::ListProductDimensionGroupsRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListProductDimensionGroups")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
ListProductDimensionGroupsRequest::~ListProductDimensionGroupsRequest()
|
||||
{}
|
||||
|
||||
std::string ListProductDimensionGroupsRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void ListProductDimensionGroupsRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string ListProductDimensionGroupsRequest::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListProductDimensionGroupsRequest::setNextToken(const std::string& nextToken)
|
||||
{
|
||||
nextToken_ = nextToken;
|
||||
setParameter("NextToken", nextToken);
|
||||
}
|
||||
|
||||
int ListProductDimensionGroupsRequest::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListProductDimensionGroupsRequest::setMaxResults(int maxResults)
|
||||
{
|
||||
maxResults_ = maxResults;
|
||||
setParameter("MaxResults", std::to_string(maxResults));
|
||||
}
|
||||
|
||||
85
quotas/src/model/ListProductDimensionGroupsResult.cc
Normal file
85
quotas/src/model/ListProductDimensionGroupsResult.cc
Normal 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/quotas/model/ListProductDimensionGroupsResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListProductDimensionGroupsResult::ListProductDimensionGroupsResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListProductDimensionGroupsResult::ListProductDimensionGroupsResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListProductDimensionGroupsResult::~ListProductDimensionGroupsResult()
|
||||
{}
|
||||
|
||||
void ListProductDimensionGroupsResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allDimensionGroupsNode = value["DimensionGroups"]["DimensionGroupsItem"];
|
||||
for (auto valueDimensionGroupsDimensionGroupsItem : allDimensionGroupsNode)
|
||||
{
|
||||
DimensionGroupsItem dimensionGroupsObject;
|
||||
if(!valueDimensionGroupsDimensionGroupsItem["GroupName"].isNull())
|
||||
dimensionGroupsObject.groupName = valueDimensionGroupsDimensionGroupsItem["GroupName"].asString();
|
||||
if(!valueDimensionGroupsDimensionGroupsItem["ProductCode"].isNull())
|
||||
dimensionGroupsObject.productCode = valueDimensionGroupsDimensionGroupsItem["ProductCode"].asString();
|
||||
if(!valueDimensionGroupsDimensionGroupsItem["GroupCode"].isNull())
|
||||
dimensionGroupsObject.groupCode = valueDimensionGroupsDimensionGroupsItem["GroupCode"].asString();
|
||||
auto allDimensionKeys = value["DimensionKeys"]["DimensionKeys"];
|
||||
for (auto value : allDimensionKeys)
|
||||
dimensionGroupsObject.dimensionKeys.push_back(value.asString());
|
||||
dimensionGroups_.push_back(dimensionGroupsObject);
|
||||
}
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
|
||||
}
|
||||
|
||||
int ListProductDimensionGroupsResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListProductDimensionGroupsResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
int ListProductDimensionGroupsResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
std::vector<ListProductDimensionGroupsResult::DimensionGroupsItem> ListProductDimensionGroupsResult::getDimensionGroups()const
|
||||
{
|
||||
return dimensionGroups_;
|
||||
}
|
||||
|
||||
73
quotas/src/model/ListProductQuotaDimensionsRequest.cc
Normal file
73
quotas/src/model/ListProductQuotaDimensionsRequest.cc
Normal file
@@ -0,0 +1,73 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/ListProductQuotaDimensionsRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListProductQuotaDimensionsRequest;
|
||||
|
||||
ListProductQuotaDimensionsRequest::ListProductQuotaDimensionsRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListProductQuotaDimensions")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListProductQuotaDimensionsRequest::~ListProductQuotaDimensionsRequest()
|
||||
{}
|
||||
|
||||
std::string ListProductQuotaDimensionsRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void ListProductQuotaDimensionsRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string ListProductQuotaDimensionsRequest::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListProductQuotaDimensionsRequest::setNextToken(const std::string& nextToken)
|
||||
{
|
||||
nextToken_ = nextToken;
|
||||
setBodyParameter("NextToken", nextToken);
|
||||
}
|
||||
|
||||
int ListProductQuotaDimensionsRequest::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListProductQuotaDimensionsRequest::setMaxResults(int maxResults)
|
||||
{
|
||||
maxResults_ = maxResults;
|
||||
setBodyParameter("MaxResults", std::to_string(maxResults));
|
||||
}
|
||||
|
||||
std::string ListProductQuotaDimensionsRequest::getQuotaCategory()const
|
||||
{
|
||||
return quotaCategory_;
|
||||
}
|
||||
|
||||
void ListProductQuotaDimensionsRequest::setQuotaCategory(const std::string& quotaCategory)
|
||||
{
|
||||
quotaCategory_ = quotaCategory;
|
||||
setBodyParameter("QuotaCategory", quotaCategory);
|
||||
}
|
||||
|
||||
98
quotas/src/model/ListProductQuotaDimensionsResult.cc
Normal file
98
quotas/src/model/ListProductQuotaDimensionsResult.cc
Normal file
@@ -0,0 +1,98 @@
|
||||
/*
|
||||
* 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/quotas/model/ListProductQuotaDimensionsResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListProductQuotaDimensionsResult::ListProductQuotaDimensionsResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListProductQuotaDimensionsResult::ListProductQuotaDimensionsResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListProductQuotaDimensionsResult::~ListProductQuotaDimensionsResult()
|
||||
{}
|
||||
|
||||
void ListProductQuotaDimensionsResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allQuotaDimensionsNode = value["QuotaDimensions"]["QuotaDimensionsItem"];
|
||||
for (auto valueQuotaDimensionsQuotaDimensionsItem : allQuotaDimensionsNode)
|
||||
{
|
||||
QuotaDimensionsItem quotaDimensionsObject;
|
||||
if(!valueQuotaDimensionsQuotaDimensionsItem["DimensionKey"].isNull())
|
||||
quotaDimensionsObject.dimensionKey = valueQuotaDimensionsQuotaDimensionsItem["DimensionKey"].asString();
|
||||
if(!valueQuotaDimensionsQuotaDimensionsItem["Name"].isNull())
|
||||
quotaDimensionsObject.name = valueQuotaDimensionsQuotaDimensionsItem["Name"].asString();
|
||||
if(!valueQuotaDimensionsQuotaDimensionsItem["Requisite"].isNull())
|
||||
quotaDimensionsObject.requisite = valueQuotaDimensionsQuotaDimensionsItem["Requisite"].asString() == "true";
|
||||
auto allDimensionValueDetailNode = valueQuotaDimensionsQuotaDimensionsItem["DimensionValueDetail"]["DimensionValueDetailItem"];
|
||||
for (auto valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem : allDimensionValueDetailNode)
|
||||
{
|
||||
QuotaDimensionsItem::DimensionValueDetailItem dimensionValueDetailObject;
|
||||
if(!valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem["Value"].isNull())
|
||||
dimensionValueDetailObject.value = valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem["Value"].asString();
|
||||
if(!valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem["Name"].isNull())
|
||||
dimensionValueDetailObject.name = valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem["Name"].asString();
|
||||
quotaDimensionsObject.dimensionValueDetail.push_back(dimensionValueDetailObject);
|
||||
}
|
||||
auto allDimensionValues = value["DimensionValues"]["DimensionValues"];
|
||||
for (auto value : allDimensionValues)
|
||||
quotaDimensionsObject.dimensionValues.push_back(value.asString());
|
||||
auto allDependentDimensions = value["DependentDimensions"]["DependentDimension"];
|
||||
for (auto value : allDependentDimensions)
|
||||
quotaDimensionsObject.dependentDimensions.push_back(value.asString());
|
||||
quotaDimensions_.push_back(quotaDimensionsObject);
|
||||
}
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<ListProductQuotaDimensionsResult::QuotaDimensionsItem> ListProductQuotaDimensionsResult::getQuotaDimensions()const
|
||||
{
|
||||
return quotaDimensions_;
|
||||
}
|
||||
|
||||
int ListProductQuotaDimensionsResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListProductQuotaDimensionsResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
int ListProductQuotaDimensionsResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
144
quotas/src/model/ListProductQuotasRequest.cc
Normal file
144
quotas/src/model/ListProductQuotasRequest.cc
Normal file
@@ -0,0 +1,144 @@
|
||||
/*
|
||||
* 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/quotas/model/ListProductQuotasRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListProductQuotasRequest;
|
||||
|
||||
ListProductQuotasRequest::ListProductQuotasRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListProductQuotas")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListProductQuotasRequest::~ListProductQuotasRequest()
|
||||
{}
|
||||
|
||||
std::string ListProductQuotasRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string ListProductQuotasRequest::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setQuotaActionCode(const std::string& quotaActionCode)
|
||||
{
|
||||
quotaActionCode_ = quotaActionCode;
|
||||
setBodyParameter("QuotaActionCode", quotaActionCode);
|
||||
}
|
||||
|
||||
std::string ListProductQuotasRequest::getGroupCode()const
|
||||
{
|
||||
return groupCode_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setGroupCode(const std::string& groupCode)
|
||||
{
|
||||
groupCode_ = groupCode;
|
||||
setBodyParameter("GroupCode", groupCode);
|
||||
}
|
||||
|
||||
std::string ListProductQuotasRequest::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setNextToken(const std::string& nextToken)
|
||||
{
|
||||
nextToken_ = nextToken;
|
||||
setBodyParameter("NextToken", nextToken);
|
||||
}
|
||||
|
||||
std::string ListProductQuotasRequest::getSortOrder()const
|
||||
{
|
||||
return sortOrder_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setSortOrder(const std::string& sortOrder)
|
||||
{
|
||||
sortOrder_ = sortOrder;
|
||||
setBodyParameter("SortOrder", sortOrder);
|
||||
}
|
||||
|
||||
std::string ListProductQuotasRequest::getKeyWord()const
|
||||
{
|
||||
return keyWord_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setKeyWord(const std::string& keyWord)
|
||||
{
|
||||
keyWord_ = keyWord;
|
||||
setBodyParameter("KeyWord", keyWord);
|
||||
}
|
||||
|
||||
std::string ListProductQuotasRequest::getQuotaCategory()const
|
||||
{
|
||||
return quotaCategory_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setQuotaCategory(const std::string& quotaCategory)
|
||||
{
|
||||
quotaCategory_ = quotaCategory;
|
||||
setBodyParameter("QuotaCategory", quotaCategory);
|
||||
}
|
||||
|
||||
int ListProductQuotasRequest::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setMaxResults(int maxResults)
|
||||
{
|
||||
maxResults_ = maxResults;
|
||||
setBodyParameter("MaxResults", std::to_string(maxResults));
|
||||
}
|
||||
|
||||
std::string ListProductQuotasRequest::getSortField()const
|
||||
{
|
||||
return sortField_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setSortField(const std::string& sortField)
|
||||
{
|
||||
sortField_ = sortField;
|
||||
setBodyParameter("SortField", sortField);
|
||||
}
|
||||
|
||||
std::vector<ListProductQuotasRequest::Dimensions> ListProductQuotasRequest::getDimensions()const
|
||||
{
|
||||
return dimensions_;
|
||||
}
|
||||
|
||||
void ListProductQuotasRequest::setDimensions(const std::vector<Dimensions>& dimensions)
|
||||
{
|
||||
dimensions_ = dimensions;
|
||||
for(int dep1 = 0; dep1!= dimensions.size(); dep1++) {
|
||||
auto dimensionsObj = dimensions.at(dep1);
|
||||
std::string dimensionsObjStr = "Dimensions." + std::to_string(dep1 + 1);
|
||||
setParameter(dimensionsObjStr + ".Key", dimensionsObj.key);
|
||||
setParameter(dimensionsObjStr + ".Value", dimensionsObj.value);
|
||||
}
|
||||
}
|
||||
|
||||
126
quotas/src/model/ListProductQuotasResult.cc
Normal file
126
quotas/src/model/ListProductQuotasResult.cc
Normal file
@@ -0,0 +1,126 @@
|
||||
/*
|
||||
* 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/quotas/model/ListProductQuotasResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListProductQuotasResult::ListProductQuotasResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListProductQuotasResult::ListProductQuotasResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListProductQuotasResult::~ListProductQuotasResult()
|
||||
{}
|
||||
|
||||
void ListProductQuotasResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allQuotasNode = value["Quotas"]["QuotasItem"];
|
||||
for (auto valueQuotasQuotasItem : allQuotasNode)
|
||||
{
|
||||
QuotasItem quotasObject;
|
||||
if(!valueQuotasQuotasItem["QuotaDescription"].isNull())
|
||||
quotasObject.quotaDescription = valueQuotasQuotasItem["QuotaDescription"].asString();
|
||||
if(!valueQuotasQuotasItem["Consumable"].isNull())
|
||||
quotasObject.consumable = valueQuotasQuotasItem["Consumable"].asString() == "true";
|
||||
if(!valueQuotasQuotasItem["UnadjustableDetail"].isNull())
|
||||
quotasObject.unadjustableDetail = valueQuotasQuotasItem["UnadjustableDetail"].asString();
|
||||
if(!valueQuotasQuotasItem["ProductCode"].isNull())
|
||||
quotasObject.productCode = valueQuotasQuotasItem["ProductCode"].asString();
|
||||
if(!valueQuotasQuotasItem["TotalUsage"].isNull())
|
||||
quotasObject.totalUsage = std::stof(valueQuotasQuotasItem["TotalUsage"].asString());
|
||||
if(!valueQuotasQuotasItem["QuotaType"].isNull())
|
||||
quotasObject.quotaType = valueQuotasQuotasItem["QuotaType"].asString();
|
||||
if(!valueQuotasQuotasItem["Dimensions"].isNull())
|
||||
quotasObject.dimensions = valueQuotasQuotasItem["Dimensions"].asString();
|
||||
if(!valueQuotasQuotasItem["QuotaUnit"].isNull())
|
||||
quotasObject.quotaUnit = valueQuotasQuotasItem["QuotaUnit"].asString();
|
||||
if(!valueQuotasQuotasItem["Adjustable"].isNull())
|
||||
quotasObject.adjustable = valueQuotasQuotasItem["Adjustable"].asString() == "true";
|
||||
if(!valueQuotasQuotasItem["QuotaActionCode"].isNull())
|
||||
quotasObject.quotaActionCode = valueQuotasQuotasItem["QuotaActionCode"].asString();
|
||||
if(!valueQuotasQuotasItem["QuotaName"].isNull())
|
||||
quotasObject.quotaName = valueQuotasQuotasItem["QuotaName"].asString();
|
||||
if(!valueQuotasQuotasItem["QuotaArn"].isNull())
|
||||
quotasObject.quotaArn = valueQuotasQuotasItem["QuotaArn"].asString();
|
||||
if(!valueQuotasQuotasItem["TotalQuota"].isNull())
|
||||
quotasObject.totalQuota = std::stof(valueQuotasQuotasItem["TotalQuota"].asString());
|
||||
if(!valueQuotasQuotasItem["ApplicableType"].isNull())
|
||||
quotasObject.applicableType = valueQuotasQuotasItem["ApplicableType"].asString();
|
||||
auto allQuotaItemsNode = valueQuotasQuotasItem["QuotaItems"]["QuotaItemsItem"];
|
||||
for (auto valueQuotasQuotasItemQuotaItemsQuotaItemsItem : allQuotaItemsNode)
|
||||
{
|
||||
QuotasItem::QuotaItemsItem quotaItemsObject;
|
||||
if(!valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Usage"].isNull())
|
||||
quotaItemsObject.usage = valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Usage"].asString();
|
||||
if(!valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Type"].isNull())
|
||||
quotaItemsObject.type = valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Type"].asString();
|
||||
if(!valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Quota"].isNull())
|
||||
quotaItemsObject.quota = valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Quota"].asString();
|
||||
if(!valueQuotasQuotasItemQuotaItemsQuotaItemsItem["QuotaUnit"].isNull())
|
||||
quotaItemsObject.quotaUnit = valueQuotasQuotasItemQuotaItemsQuotaItemsItem["QuotaUnit"].asString();
|
||||
quotasObject.quotaItems.push_back(quotaItemsObject);
|
||||
}
|
||||
auto periodNode = value["Period"];
|
||||
if(!periodNode["PeriodValue"].isNull())
|
||||
quotasObject.period.periodValue = std::stoi(periodNode["PeriodValue"].asString());
|
||||
if(!periodNode["PeriodUnit"].isNull())
|
||||
quotasObject.period.periodUnit = periodNode["PeriodUnit"].asString();
|
||||
auto allApplicableRange = value["ApplicableRange"]["ApplicableRange"];
|
||||
for (auto value : allApplicableRange)
|
||||
quotasObject.applicableRange.push_back(value.asString());
|
||||
quotas_.push_back(quotasObject);
|
||||
}
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
|
||||
}
|
||||
|
||||
int ListProductQuotasResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListProductQuotasResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
std::vector<ListProductQuotasResult::QuotasItem> ListProductQuotasResult::getQuotas()const
|
||||
{
|
||||
return quotas_;
|
||||
}
|
||||
|
||||
int ListProductQuotasResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
51
quotas/src/model/ListProductsRequest.cc
Normal file
51
quotas/src/model/ListProductsRequest.cc
Normal 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/quotas/model/ListProductsRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListProductsRequest;
|
||||
|
||||
ListProductsRequest::ListProductsRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListProducts")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListProductsRequest::~ListProductsRequest()
|
||||
{}
|
||||
|
||||
std::string ListProductsRequest::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListProductsRequest::setNextToken(const std::string& nextToken)
|
||||
{
|
||||
nextToken_ = nextToken;
|
||||
setBodyParameter("NextToken", nextToken);
|
||||
}
|
||||
|
||||
int ListProductsRequest::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListProductsRequest::setMaxResults(int maxResults)
|
||||
{
|
||||
maxResults_ = maxResults;
|
||||
setBodyParameter("MaxResults", std::to_string(maxResults));
|
||||
}
|
||||
|
||||
94
quotas/src/model/ListProductsResult.cc
Normal file
94
quotas/src/model/ListProductsResult.cc
Normal file
@@ -0,0 +1,94 @@
|
||||
/*
|
||||
* 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/quotas/model/ListProductsResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListProductsResult::ListProductsResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListProductsResult::ListProductsResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListProductsResult::~ListProductsResult()
|
||||
{}
|
||||
|
||||
void ListProductsResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allProductInfoNode = value["ProductInfo"]["ProductInfos"];
|
||||
for (auto valueProductInfoProductInfos : allProductInfoNode)
|
||||
{
|
||||
ProductInfos productInfoObject;
|
||||
if(!valueProductInfoProductInfos["SecondCategoryNameEn"].isNull())
|
||||
productInfoObject.secondCategoryNameEn = valueProductInfoProductInfos["SecondCategoryNameEn"].asString();
|
||||
if(!valueProductInfoProductInfos["Dynamic"].isNull())
|
||||
productInfoObject.dynamic = valueProductInfoProductInfos["Dynamic"].asString() == "true";
|
||||
if(!valueProductInfoProductInfos["CommonQuotaSupport"].isNull())
|
||||
productInfoObject.commonQuotaSupport = valueProductInfoProductInfos["CommonQuotaSupport"].asString();
|
||||
if(!valueProductInfoProductInfos["ProductName"].isNull())
|
||||
productInfoObject.productName = valueProductInfoProductInfos["ProductName"].asString();
|
||||
if(!valueProductInfoProductInfos["ProductCode"].isNull())
|
||||
productInfoObject.productCode = valueProductInfoProductInfos["ProductCode"].asString();
|
||||
if(!valueProductInfoProductInfos["SecondCategoryName"].isNull())
|
||||
productInfoObject.secondCategoryName = valueProductInfoProductInfos["SecondCategoryName"].asString();
|
||||
if(!valueProductInfoProductInfos["FlowControlSupport"].isNull())
|
||||
productInfoObject.flowControlSupport = valueProductInfoProductInfos["FlowControlSupport"].asString();
|
||||
if(!valueProductInfoProductInfos["SecondCategoryId"].isNull())
|
||||
productInfoObject.secondCategoryId = std::stol(valueProductInfoProductInfos["SecondCategoryId"].asString());
|
||||
if(!valueProductInfoProductInfos["ProductNameEn"].isNull())
|
||||
productInfoObject.productNameEn = valueProductInfoProductInfos["ProductNameEn"].asString();
|
||||
productInfo_.push_back(productInfoObject);
|
||||
}
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<ListProductsResult::ProductInfos> ListProductsResult::getProductInfo()const
|
||||
{
|
||||
return productInfo_;
|
||||
}
|
||||
|
||||
int ListProductsResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListProductsResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
int ListProductsResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
100
quotas/src/model/ListQuotaAlarmsRequest.cc
Normal file
100
quotas/src/model/ListQuotaAlarmsRequest.cc
Normal file
@@ -0,0 +1,100 @@
|
||||
/*
|
||||
* 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/quotas/model/ListQuotaAlarmsRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListQuotaAlarmsRequest;
|
||||
|
||||
ListQuotaAlarmsRequest::ListQuotaAlarmsRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListQuotaAlarms")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListQuotaAlarmsRequest::~ListQuotaAlarmsRequest()
|
||||
{}
|
||||
|
||||
std::string ListQuotaAlarmsRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void ListQuotaAlarmsRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string ListQuotaAlarmsRequest::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
void ListQuotaAlarmsRequest::setQuotaActionCode(const std::string& quotaActionCode)
|
||||
{
|
||||
quotaActionCode_ = quotaActionCode;
|
||||
setBodyParameter("QuotaActionCode", quotaActionCode);
|
||||
}
|
||||
|
||||
std::string ListQuotaAlarmsRequest::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListQuotaAlarmsRequest::setNextToken(const std::string& nextToken)
|
||||
{
|
||||
nextToken_ = nextToken;
|
||||
setBodyParameter("NextToken", nextToken);
|
||||
}
|
||||
|
||||
std::vector<ListQuotaAlarmsRequest::QuotaDimensions> ListQuotaAlarmsRequest::getQuotaDimensions()const
|
||||
{
|
||||
return quotaDimensions_;
|
||||
}
|
||||
|
||||
void ListQuotaAlarmsRequest::setQuotaDimensions(const std::vector<QuotaDimensions>& quotaDimensions)
|
||||
{
|
||||
quotaDimensions_ = quotaDimensions;
|
||||
for(int dep1 = 0; dep1!= quotaDimensions.size(); dep1++) {
|
||||
auto quotaDimensionsObj = quotaDimensions.at(dep1);
|
||||
std::string quotaDimensionsObjStr = "QuotaDimensions." + std::to_string(dep1 + 1);
|
||||
setParameter(quotaDimensionsObjStr + ".Key", quotaDimensionsObj.key);
|
||||
setParameter(quotaDimensionsObjStr + ".Value", quotaDimensionsObj.value);
|
||||
}
|
||||
}
|
||||
|
||||
int ListQuotaAlarmsRequest::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListQuotaAlarmsRequest::setMaxResults(int maxResults)
|
||||
{
|
||||
maxResults_ = maxResults;
|
||||
setBodyParameter("MaxResults", std::to_string(maxResults));
|
||||
}
|
||||
|
||||
std::string ListQuotaAlarmsRequest::getAlarmName()const
|
||||
{
|
||||
return alarmName_;
|
||||
}
|
||||
|
||||
void ListQuotaAlarmsRequest::setAlarmName(const std::string& alarmName)
|
||||
{
|
||||
alarmName_ = alarmName;
|
||||
setBodyParameter("AlarmName", alarmName);
|
||||
}
|
||||
|
||||
107
quotas/src/model/ListQuotaAlarmsResult.cc
Normal file
107
quotas/src/model/ListQuotaAlarmsResult.cc
Normal file
@@ -0,0 +1,107 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/ListQuotaAlarmsResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListQuotaAlarmsResult::ListQuotaAlarmsResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListQuotaAlarmsResult::ListQuotaAlarmsResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListQuotaAlarmsResult::~ListQuotaAlarmsResult()
|
||||
{}
|
||||
|
||||
void ListQuotaAlarmsResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allQuotaAlarmsNode = value["QuotaAlarms"]["QuotaAlarm"];
|
||||
for (auto valueQuotaAlarmsQuotaAlarm : allQuotaAlarmsNode)
|
||||
{
|
||||
QuotaAlarm quotaAlarmsObject;
|
||||
if(!valueQuotaAlarmsQuotaAlarm["AlarmId"].isNull())
|
||||
quotaAlarmsObject.alarmId = valueQuotaAlarmsQuotaAlarm["AlarmId"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["QuotaDimensions"].isNull())
|
||||
quotaAlarmsObject.quotaDimensions = valueQuotaAlarmsQuotaAlarm["QuotaDimensions"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["ThresholdPercent"].isNull())
|
||||
quotaAlarmsObject.thresholdPercent = std::stof(valueQuotaAlarmsQuotaAlarm["ThresholdPercent"].asString());
|
||||
if(!valueQuotaAlarmsQuotaAlarm["ProductCode"].isNull())
|
||||
quotaAlarmsObject.productCode = valueQuotaAlarmsQuotaAlarm["ProductCode"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["CreateTime"].isNull())
|
||||
quotaAlarmsObject.createTime = valueQuotaAlarmsQuotaAlarm["CreateTime"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["WebHook"].isNull())
|
||||
quotaAlarmsObject.webHook = valueQuotaAlarmsQuotaAlarm["WebHook"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["QuotaUsage"].isNull())
|
||||
quotaAlarmsObject.quotaUsage = std::stof(valueQuotaAlarmsQuotaAlarm["QuotaUsage"].asString());
|
||||
if(!valueQuotaAlarmsQuotaAlarm["ExceedThreshold"].isNull())
|
||||
quotaAlarmsObject.exceedThreshold = valueQuotaAlarmsQuotaAlarm["ExceedThreshold"].asString() == "true";
|
||||
if(!valueQuotaAlarmsQuotaAlarm["QuotaActionCode"].isNull())
|
||||
quotaAlarmsObject.quotaActionCode = valueQuotaAlarmsQuotaAlarm["QuotaActionCode"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["QuotaValue"].isNull())
|
||||
quotaAlarmsObject.quotaValue = std::stof(valueQuotaAlarmsQuotaAlarm["QuotaValue"].asString());
|
||||
if(!valueQuotaAlarmsQuotaAlarm["AlarmName"].isNull())
|
||||
quotaAlarmsObject.alarmName = valueQuotaAlarmsQuotaAlarm["AlarmName"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["NotifyTarget"].isNull())
|
||||
quotaAlarmsObject.notifyTarget = valueQuotaAlarmsQuotaAlarm["NotifyTarget"].asString();
|
||||
if(!valueQuotaAlarmsQuotaAlarm["Threshold"].isNull())
|
||||
quotaAlarmsObject.threshold = std::stof(valueQuotaAlarmsQuotaAlarm["Threshold"].asString());
|
||||
if(!valueQuotaAlarmsQuotaAlarm["ThresholdType"].isNull())
|
||||
quotaAlarmsObject.thresholdType = valueQuotaAlarmsQuotaAlarm["ThresholdType"].asString();
|
||||
auto allNotifyChannels = value["NotifyChannels"]["NotifyChannels"];
|
||||
for (auto value : allNotifyChannels)
|
||||
quotaAlarmsObject.notifyChannels.push_back(value.asString());
|
||||
quotaAlarms_.push_back(quotaAlarmsObject);
|
||||
}
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<ListQuotaAlarmsResult::QuotaAlarm> ListQuotaAlarmsResult::getQuotaAlarms()const
|
||||
{
|
||||
return quotaAlarms_;
|
||||
}
|
||||
|
||||
int ListQuotaAlarmsResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListQuotaAlarmsResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
int ListQuotaAlarmsResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
122
quotas/src/model/ListQuotaApplicationsRequest.cc
Normal file
122
quotas/src/model/ListQuotaApplicationsRequest.cc
Normal file
@@ -0,0 +1,122 @@
|
||||
/*
|
||||
* 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/quotas/model/ListQuotaApplicationsRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::ListQuotaApplicationsRequest;
|
||||
|
||||
ListQuotaApplicationsRequest::ListQuotaApplicationsRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "ListQuotaApplications")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListQuotaApplicationsRequest::~ListQuotaApplicationsRequest()
|
||||
{}
|
||||
|
||||
std::string ListQuotaApplicationsRequest::getProductCode()const
|
||||
{
|
||||
return productCode_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setProductCode(const std::string& productCode)
|
||||
{
|
||||
productCode_ = productCode;
|
||||
setBodyParameter("ProductCode", productCode);
|
||||
}
|
||||
|
||||
std::string ListQuotaApplicationsRequest::getQuotaActionCode()const
|
||||
{
|
||||
return quotaActionCode_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setQuotaActionCode(const std::string& quotaActionCode)
|
||||
{
|
||||
quotaActionCode_ = quotaActionCode;
|
||||
setBodyParameter("QuotaActionCode", quotaActionCode);
|
||||
}
|
||||
|
||||
std::string ListQuotaApplicationsRequest::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setNextToken(const std::string& nextToken)
|
||||
{
|
||||
nextToken_ = nextToken;
|
||||
setBodyParameter("NextToken", nextToken);
|
||||
}
|
||||
|
||||
std::string ListQuotaApplicationsRequest::getKeyWord()const
|
||||
{
|
||||
return keyWord_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setKeyWord(const std::string& keyWord)
|
||||
{
|
||||
keyWord_ = keyWord;
|
||||
setBodyParameter("KeyWord", keyWord);
|
||||
}
|
||||
|
||||
std::string ListQuotaApplicationsRequest::getQuotaCategory()const
|
||||
{
|
||||
return quotaCategory_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setQuotaCategory(const std::string& quotaCategory)
|
||||
{
|
||||
quotaCategory_ = quotaCategory;
|
||||
setBodyParameter("QuotaCategory", quotaCategory);
|
||||
}
|
||||
|
||||
int ListQuotaApplicationsRequest::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setMaxResults(int maxResults)
|
||||
{
|
||||
maxResults_ = maxResults;
|
||||
setBodyParameter("MaxResults", std::to_string(maxResults));
|
||||
}
|
||||
|
||||
std::string ListQuotaApplicationsRequest::getStatus()const
|
||||
{
|
||||
return status_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setStatus(const std::string& status)
|
||||
{
|
||||
status_ = status;
|
||||
setBodyParameter("Status", status);
|
||||
}
|
||||
|
||||
std::vector<ListQuotaApplicationsRequest::Dimensions> ListQuotaApplicationsRequest::getDimensions()const
|
||||
{
|
||||
return dimensions_;
|
||||
}
|
||||
|
||||
void ListQuotaApplicationsRequest::setDimensions(const std::vector<Dimensions>& dimensions)
|
||||
{
|
||||
dimensions_ = dimensions;
|
||||
for(int dep1 = 0; dep1!= dimensions.size(); dep1++) {
|
||||
auto dimensionsObj = dimensions.at(dep1);
|
||||
std::string dimensionsObjStr = "Dimensions." + std::to_string(dep1 + 1);
|
||||
setParameter(dimensionsObjStr + ".Key", dimensionsObj.key);
|
||||
setParameter(dimensionsObjStr + ".Value", dimensionsObj.value);
|
||||
}
|
||||
}
|
||||
|
||||
117
quotas/src/model/ListQuotaApplicationsResult.cc
Normal file
117
quotas/src/model/ListQuotaApplicationsResult.cc
Normal file
@@ -0,0 +1,117 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/ListQuotaApplicationsResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
ListQuotaApplicationsResult::ListQuotaApplicationsResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListQuotaApplicationsResult::ListQuotaApplicationsResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListQuotaApplicationsResult::~ListQuotaApplicationsResult()
|
||||
{}
|
||||
|
||||
void ListQuotaApplicationsResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allQuotaApplicationsNode = value["QuotaApplications"]["QuotaApplicationsItem"];
|
||||
for (auto valueQuotaApplicationsQuotaApplicationsItem : allQuotaApplicationsNode)
|
||||
{
|
||||
QuotaApplicationsItem quotaApplicationsObject;
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["Status"].isNull())
|
||||
quotaApplicationsObject.status = valueQuotaApplicationsQuotaApplicationsItem["Status"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["ApplyTime"].isNull())
|
||||
quotaApplicationsObject.applyTime = valueQuotaApplicationsQuotaApplicationsItem["ApplyTime"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["Comment"].isNull())
|
||||
quotaApplicationsObject.comment = valueQuotaApplicationsQuotaApplicationsItem["Comment"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaDescription"].isNull())
|
||||
quotaApplicationsObject.quotaDescription = valueQuotaApplicationsQuotaApplicationsItem["QuotaDescription"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["ProductCode"].isNull())
|
||||
quotaApplicationsObject.productCode = valueQuotaApplicationsQuotaApplicationsItem["ProductCode"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["EffectiveTime"].isNull())
|
||||
quotaApplicationsObject.effectiveTime = valueQuotaApplicationsQuotaApplicationsItem["EffectiveTime"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["AuditReason"].isNull())
|
||||
quotaApplicationsObject.auditReason = valueQuotaApplicationsQuotaApplicationsItem["AuditReason"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaUnit"].isNull())
|
||||
quotaApplicationsObject.quotaUnit = valueQuotaApplicationsQuotaApplicationsItem["QuotaUnit"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["Dimension"].isNull())
|
||||
quotaApplicationsObject.dimension = valueQuotaApplicationsQuotaApplicationsItem["Dimension"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["ApproveValue"].isNull())
|
||||
quotaApplicationsObject.approveValue = std::stof(valueQuotaApplicationsQuotaApplicationsItem["ApproveValue"].asString());
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["Reason"].isNull())
|
||||
quotaApplicationsObject.reason = valueQuotaApplicationsQuotaApplicationsItem["Reason"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaActionCode"].isNull())
|
||||
quotaApplicationsObject.quotaActionCode = valueQuotaApplicationsQuotaApplicationsItem["QuotaActionCode"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaName"].isNull())
|
||||
quotaApplicationsObject.quotaName = valueQuotaApplicationsQuotaApplicationsItem["QuotaName"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaArn"].isNull())
|
||||
quotaApplicationsObject.quotaArn = valueQuotaApplicationsQuotaApplicationsItem["QuotaArn"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["NoticeType"].isNull())
|
||||
quotaApplicationsObject.noticeType = std::stoi(valueQuotaApplicationsQuotaApplicationsItem["NoticeType"].asString());
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["ApplicationId"].isNull())
|
||||
quotaApplicationsObject.applicationId = valueQuotaApplicationsQuotaApplicationsItem["ApplicationId"].asString();
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["DesireValue"].isNull())
|
||||
quotaApplicationsObject.desireValue = std::stof(valueQuotaApplicationsQuotaApplicationsItem["DesireValue"].asString());
|
||||
if(!valueQuotaApplicationsQuotaApplicationsItem["ExpireTime"].isNull())
|
||||
quotaApplicationsObject.expireTime = valueQuotaApplicationsQuotaApplicationsItem["ExpireTime"].asString();
|
||||
auto periodNode = value["Period"];
|
||||
if(!periodNode["PeriodValue"].isNull())
|
||||
quotaApplicationsObject.period.periodValue = std::stol(periodNode["PeriodValue"].asString());
|
||||
if(!periodNode["PeriodUnit"].isNull())
|
||||
quotaApplicationsObject.period.periodUnit = periodNode["PeriodUnit"].asString();
|
||||
quotaApplications_.push_back(quotaApplicationsObject);
|
||||
}
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
|
||||
}
|
||||
|
||||
std::vector<ListQuotaApplicationsResult::QuotaApplicationsItem> ListQuotaApplicationsResult::getQuotaApplications()const
|
||||
{
|
||||
return quotaApplications_;
|
||||
}
|
||||
|
||||
int ListQuotaApplicationsResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListQuotaApplicationsResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
int ListQuotaApplicationsResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
95
quotas/src/model/UpdateQuotaAlarmRequest.cc
Normal file
95
quotas/src/model/UpdateQuotaAlarmRequest.cc
Normal file
@@ -0,0 +1,95 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/quotas/model/UpdateQuotaAlarmRequest.h>
|
||||
|
||||
using AlibabaCloud::Quotas::Model::UpdateQuotaAlarmRequest;
|
||||
|
||||
UpdateQuotaAlarmRequest::UpdateQuotaAlarmRequest() :
|
||||
RpcServiceRequest("quotas", "2020-05-10", "UpdateQuotaAlarm")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
UpdateQuotaAlarmRequest::~UpdateQuotaAlarmRequest()
|
||||
{}
|
||||
|
||||
std::string UpdateQuotaAlarmRequest::getWebHook()const
|
||||
{
|
||||
return webHook_;
|
||||
}
|
||||
|
||||
void UpdateQuotaAlarmRequest::setWebHook(const std::string& webHook)
|
||||
{
|
||||
webHook_ = webHook;
|
||||
setBodyParameter("WebHook", webHook);
|
||||
}
|
||||
|
||||
float UpdateQuotaAlarmRequest::getThreshold()const
|
||||
{
|
||||
return threshold_;
|
||||
}
|
||||
|
||||
void UpdateQuotaAlarmRequest::setThreshold(float threshold)
|
||||
{
|
||||
threshold_ = threshold;
|
||||
setBodyParameter("Threshold", std::to_string(threshold));
|
||||
}
|
||||
|
||||
std::string UpdateQuotaAlarmRequest::getThresholdType()const
|
||||
{
|
||||
return thresholdType_;
|
||||
}
|
||||
|
||||
void UpdateQuotaAlarmRequest::setThresholdType(const std::string& thresholdType)
|
||||
{
|
||||
thresholdType_ = thresholdType;
|
||||
setBodyParameter("ThresholdType", thresholdType);
|
||||
}
|
||||
|
||||
float UpdateQuotaAlarmRequest::getThresholdPercent()const
|
||||
{
|
||||
return thresholdPercent_;
|
||||
}
|
||||
|
||||
void UpdateQuotaAlarmRequest::setThresholdPercent(float thresholdPercent)
|
||||
{
|
||||
thresholdPercent_ = thresholdPercent;
|
||||
setBodyParameter("ThresholdPercent", std::to_string(thresholdPercent));
|
||||
}
|
||||
|
||||
std::string UpdateQuotaAlarmRequest::getAlarmId()const
|
||||
{
|
||||
return alarmId_;
|
||||
}
|
||||
|
||||
void UpdateQuotaAlarmRequest::setAlarmId(const std::string& alarmId)
|
||||
{
|
||||
alarmId_ = alarmId;
|
||||
setBodyParameter("AlarmId", alarmId);
|
||||
}
|
||||
|
||||
std::string UpdateQuotaAlarmRequest::getAlarmName()const
|
||||
{
|
||||
return alarmName_;
|
||||
}
|
||||
|
||||
void UpdateQuotaAlarmRequest::setAlarmName(const std::string& alarmName)
|
||||
{
|
||||
alarmName_ = alarmName;
|
||||
setBodyParameter("AlarmName", alarmName);
|
||||
}
|
||||
|
||||
44
quotas/src/model/UpdateQuotaAlarmResult.cc
Normal file
44
quotas/src/model/UpdateQuotaAlarmResult.cc
Normal 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/quotas/model/UpdateQuotaAlarmResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quotas;
|
||||
using namespace AlibabaCloud::Quotas::Model;
|
||||
|
||||
UpdateQuotaAlarmResult::UpdateQuotaAlarmResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
UpdateQuotaAlarmResult::UpdateQuotaAlarmResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
UpdateQuotaAlarmResult::~UpdateQuotaAlarmResult()
|
||||
{}
|
||||
|
||||
void UpdateQuotaAlarmResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user