diff --git a/VERSION b/VERSION index df46e331f..055794ed6 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.36.1942 \ No newline at end of file +1.36.1943 \ No newline at end of file diff --git a/quotas/CMakeLists.txt b/quotas/CMakeLists.txt index e2b1e6e7f..ceb15e4b4 100644 --- a/quotas/CMakeLists.txt +++ b/quotas/CMakeLists.txt @@ -25,8 +25,14 @@ set(quotas_public_header_model include/alibabacloud/quotas/model/CreateQuotaAlarmResult.h include/alibabacloud/quotas/model/CreateQuotaApplicationRequest.h include/alibabacloud/quotas/model/CreateQuotaApplicationResult.h + include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateRequest.h + include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateResult.h + include/alibabacloud/quotas/model/CreateTemplateQuotaItemRequest.h + include/alibabacloud/quotas/model/CreateTemplateQuotaItemResult.h include/alibabacloud/quotas/model/DeleteQuotaAlarmRequest.h include/alibabacloud/quotas/model/DeleteQuotaAlarmResult.h + include/alibabacloud/quotas/model/DeleteTemplateQuotaItemRequest.h + include/alibabacloud/quotas/model/DeleteTemplateQuotaItemResult.h include/alibabacloud/quotas/model/GetProductQuotaRequest.h include/alibabacloud/quotas/model/GetProductQuotaResult.h include/alibabacloud/quotas/model/GetProductQuotaDimensionRequest.h @@ -35,6 +41,10 @@ set(quotas_public_header_model include/alibabacloud/quotas/model/GetQuotaAlarmResult.h include/alibabacloud/quotas/model/GetQuotaApplicationRequest.h include/alibabacloud/quotas/model/GetQuotaApplicationResult.h + include/alibabacloud/quotas/model/GetQuotaApplicationApprovalRequest.h + include/alibabacloud/quotas/model/GetQuotaApplicationApprovalResult.h + include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusRequest.h + include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusResult.h include/alibabacloud/quotas/model/ListAlarmHistoriesRequest.h include/alibabacloud/quotas/model/ListAlarmHistoriesResult.h include/alibabacloud/quotas/model/ListDependentQuotasRequest.h @@ -49,8 +59,20 @@ set(quotas_public_header_model include/alibabacloud/quotas/model/ListProductsResult.h include/alibabacloud/quotas/model/ListQuotaAlarmsRequest.h include/alibabacloud/quotas/model/ListQuotaAlarmsResult.h + include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesRequest.h + include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesResult.h include/alibabacloud/quotas/model/ListQuotaApplicationsRequest.h include/alibabacloud/quotas/model/ListQuotaApplicationsResult.h + include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateRequest.h + include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateResult.h + include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateRequest.h + include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateResult.h + include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusRequest.h + include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusResult.h + include/alibabacloud/quotas/model/ModifyTemplateQuotaItemRequest.h + include/alibabacloud/quotas/model/ModifyTemplateQuotaItemResult.h + include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalRequest.h + include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalResult.h include/alibabacloud/quotas/model/UpdateQuotaAlarmRequest.h include/alibabacloud/quotas/model/UpdateQuotaAlarmResult.h ) @@ -60,8 +82,14 @@ set(quotas_src src/model/CreateQuotaAlarmResult.cc src/model/CreateQuotaApplicationRequest.cc src/model/CreateQuotaApplicationResult.cc + src/model/CreateQuotaApplicationsForTemplateRequest.cc + src/model/CreateQuotaApplicationsForTemplateResult.cc + src/model/CreateTemplateQuotaItemRequest.cc + src/model/CreateTemplateQuotaItemResult.cc src/model/DeleteQuotaAlarmRequest.cc src/model/DeleteQuotaAlarmResult.cc + src/model/DeleteTemplateQuotaItemRequest.cc + src/model/DeleteTemplateQuotaItemResult.cc src/model/GetProductQuotaRequest.cc src/model/GetProductQuotaResult.cc src/model/GetProductQuotaDimensionRequest.cc @@ -70,6 +98,10 @@ set(quotas_src src/model/GetQuotaAlarmResult.cc src/model/GetQuotaApplicationRequest.cc src/model/GetQuotaApplicationResult.cc + src/model/GetQuotaApplicationApprovalRequest.cc + src/model/GetQuotaApplicationApprovalResult.cc + src/model/GetQuotaTemplateServiceStatusRequest.cc + src/model/GetQuotaTemplateServiceStatusResult.cc src/model/ListAlarmHistoriesRequest.cc src/model/ListAlarmHistoriesResult.cc src/model/ListDependentQuotasRequest.cc @@ -84,8 +116,20 @@ set(quotas_src src/model/ListProductsResult.cc src/model/ListQuotaAlarmsRequest.cc src/model/ListQuotaAlarmsResult.cc + src/model/ListQuotaApplicationTemplatesRequest.cc + src/model/ListQuotaApplicationTemplatesResult.cc src/model/ListQuotaApplicationsRequest.cc src/model/ListQuotaApplicationsResult.cc + src/model/ListQuotaApplicationsDetailForTemplateRequest.cc + src/model/ListQuotaApplicationsDetailForTemplateResult.cc + src/model/ListQuotaApplicationsForTemplateRequest.cc + src/model/ListQuotaApplicationsForTemplateResult.cc + src/model/ModifyQuotaTemplateServiceStatusRequest.cc + src/model/ModifyQuotaTemplateServiceStatusResult.cc + src/model/ModifyTemplateQuotaItemRequest.cc + src/model/ModifyTemplateQuotaItemResult.cc + src/model/RemindQuotaApplicationApprovalRequest.cc + src/model/RemindQuotaApplicationApprovalResult.cc src/model/UpdateQuotaAlarmRequest.cc src/model/UpdateQuotaAlarmResult.cc ) diff --git a/quotas/include/alibabacloud/quotas/QuotasClient.h b/quotas/include/alibabacloud/quotas/QuotasClient.h index cd3ec03a0..9c29a3553 100644 --- a/quotas/include/alibabacloud/quotas/QuotasClient.h +++ b/quotas/include/alibabacloud/quotas/QuotasClient.h @@ -26,8 +26,14 @@ #include "model/CreateQuotaAlarmResult.h" #include "model/CreateQuotaApplicationRequest.h" #include "model/CreateQuotaApplicationResult.h" +#include "model/CreateQuotaApplicationsForTemplateRequest.h" +#include "model/CreateQuotaApplicationsForTemplateResult.h" +#include "model/CreateTemplateQuotaItemRequest.h" +#include "model/CreateTemplateQuotaItemResult.h" #include "model/DeleteQuotaAlarmRequest.h" #include "model/DeleteQuotaAlarmResult.h" +#include "model/DeleteTemplateQuotaItemRequest.h" +#include "model/DeleteTemplateQuotaItemResult.h" #include "model/GetProductQuotaRequest.h" #include "model/GetProductQuotaResult.h" #include "model/GetProductQuotaDimensionRequest.h" @@ -36,6 +42,10 @@ #include "model/GetQuotaAlarmResult.h" #include "model/GetQuotaApplicationRequest.h" #include "model/GetQuotaApplicationResult.h" +#include "model/GetQuotaApplicationApprovalRequest.h" +#include "model/GetQuotaApplicationApprovalResult.h" +#include "model/GetQuotaTemplateServiceStatusRequest.h" +#include "model/GetQuotaTemplateServiceStatusResult.h" #include "model/ListAlarmHistoriesRequest.h" #include "model/ListAlarmHistoriesResult.h" #include "model/ListDependentQuotasRequest.h" @@ -50,8 +60,20 @@ #include "model/ListProductsResult.h" #include "model/ListQuotaAlarmsRequest.h" #include "model/ListQuotaAlarmsResult.h" +#include "model/ListQuotaApplicationTemplatesRequest.h" +#include "model/ListQuotaApplicationTemplatesResult.h" #include "model/ListQuotaApplicationsRequest.h" #include "model/ListQuotaApplicationsResult.h" +#include "model/ListQuotaApplicationsDetailForTemplateRequest.h" +#include "model/ListQuotaApplicationsDetailForTemplateResult.h" +#include "model/ListQuotaApplicationsForTemplateRequest.h" +#include "model/ListQuotaApplicationsForTemplateResult.h" +#include "model/ModifyQuotaTemplateServiceStatusRequest.h" +#include "model/ModifyQuotaTemplateServiceStatusResult.h" +#include "model/ModifyTemplateQuotaItemRequest.h" +#include "model/ModifyTemplateQuotaItemResult.h" +#include "model/RemindQuotaApplicationApprovalRequest.h" +#include "model/RemindQuotaApplicationApprovalResult.h" #include "model/UpdateQuotaAlarmRequest.h" #include "model/UpdateQuotaAlarmResult.h" @@ -69,9 +91,18 @@ namespace AlibabaCloud typedef Outcome CreateQuotaApplicationOutcome; typedef std::future CreateQuotaApplicationOutcomeCallable; typedef std::function&)> CreateQuotaApplicationAsyncHandler; + typedef Outcome CreateQuotaApplicationsForTemplateOutcome; + typedef std::future CreateQuotaApplicationsForTemplateOutcomeCallable; + typedef std::function&)> CreateQuotaApplicationsForTemplateAsyncHandler; + typedef Outcome CreateTemplateQuotaItemOutcome; + typedef std::future CreateTemplateQuotaItemOutcomeCallable; + typedef std::function&)> CreateTemplateQuotaItemAsyncHandler; typedef Outcome DeleteQuotaAlarmOutcome; typedef std::future DeleteQuotaAlarmOutcomeCallable; typedef std::function&)> DeleteQuotaAlarmAsyncHandler; + typedef Outcome DeleteTemplateQuotaItemOutcome; + typedef std::future DeleteTemplateQuotaItemOutcomeCallable; + typedef std::function&)> DeleteTemplateQuotaItemAsyncHandler; typedef Outcome GetProductQuotaOutcome; typedef std::future GetProductQuotaOutcomeCallable; typedef std::function&)> GetProductQuotaAsyncHandler; @@ -84,6 +115,12 @@ namespace AlibabaCloud typedef Outcome GetQuotaApplicationOutcome; typedef std::future GetQuotaApplicationOutcomeCallable; typedef std::function&)> GetQuotaApplicationAsyncHandler; + typedef Outcome GetQuotaApplicationApprovalOutcome; + typedef std::future GetQuotaApplicationApprovalOutcomeCallable; + typedef std::function&)> GetQuotaApplicationApprovalAsyncHandler; + typedef Outcome GetQuotaTemplateServiceStatusOutcome; + typedef std::future GetQuotaTemplateServiceStatusOutcomeCallable; + typedef std::function&)> GetQuotaTemplateServiceStatusAsyncHandler; typedef Outcome ListAlarmHistoriesOutcome; typedef std::future ListAlarmHistoriesOutcomeCallable; typedef std::function&)> ListAlarmHistoriesAsyncHandler; @@ -105,9 +142,27 @@ namespace AlibabaCloud typedef Outcome ListQuotaAlarmsOutcome; typedef std::future ListQuotaAlarmsOutcomeCallable; typedef std::function&)> ListQuotaAlarmsAsyncHandler; + typedef Outcome ListQuotaApplicationTemplatesOutcome; + typedef std::future ListQuotaApplicationTemplatesOutcomeCallable; + typedef std::function&)> ListQuotaApplicationTemplatesAsyncHandler; typedef Outcome ListQuotaApplicationsOutcome; typedef std::future ListQuotaApplicationsOutcomeCallable; typedef std::function&)> ListQuotaApplicationsAsyncHandler; + typedef Outcome ListQuotaApplicationsDetailForTemplateOutcome; + typedef std::future ListQuotaApplicationsDetailForTemplateOutcomeCallable; + typedef std::function&)> ListQuotaApplicationsDetailForTemplateAsyncHandler; + typedef Outcome ListQuotaApplicationsForTemplateOutcome; + typedef std::future ListQuotaApplicationsForTemplateOutcomeCallable; + typedef std::function&)> ListQuotaApplicationsForTemplateAsyncHandler; + typedef Outcome ModifyQuotaTemplateServiceStatusOutcome; + typedef std::future ModifyQuotaTemplateServiceStatusOutcomeCallable; + typedef std::function&)> ModifyQuotaTemplateServiceStatusAsyncHandler; + typedef Outcome ModifyTemplateQuotaItemOutcome; + typedef std::future ModifyTemplateQuotaItemOutcomeCallable; + typedef std::function&)> ModifyTemplateQuotaItemAsyncHandler; + typedef Outcome RemindQuotaApplicationApprovalOutcome; + typedef std::future RemindQuotaApplicationApprovalOutcomeCallable; + typedef std::function&)> RemindQuotaApplicationApprovalAsyncHandler; typedef Outcome UpdateQuotaAlarmOutcome; typedef std::future UpdateQuotaAlarmOutcomeCallable; typedef std::function&)> UpdateQuotaAlarmAsyncHandler; @@ -122,9 +177,18 @@ namespace AlibabaCloud CreateQuotaApplicationOutcome createQuotaApplication(const Model::CreateQuotaApplicationRequest &request)const; void createQuotaApplicationAsync(const Model::CreateQuotaApplicationRequest& request, const CreateQuotaApplicationAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateQuotaApplicationOutcomeCallable createQuotaApplicationCallable(const Model::CreateQuotaApplicationRequest& request) const; + CreateQuotaApplicationsForTemplateOutcome createQuotaApplicationsForTemplate(const Model::CreateQuotaApplicationsForTemplateRequest &request)const; + void createQuotaApplicationsForTemplateAsync(const Model::CreateQuotaApplicationsForTemplateRequest& request, const CreateQuotaApplicationsForTemplateAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateQuotaApplicationsForTemplateOutcomeCallable createQuotaApplicationsForTemplateCallable(const Model::CreateQuotaApplicationsForTemplateRequest& request) const; + CreateTemplateQuotaItemOutcome createTemplateQuotaItem(const Model::CreateTemplateQuotaItemRequest &request)const; + void createTemplateQuotaItemAsync(const Model::CreateTemplateQuotaItemRequest& request, const CreateTemplateQuotaItemAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateTemplateQuotaItemOutcomeCallable createTemplateQuotaItemCallable(const Model::CreateTemplateQuotaItemRequest& request) const; DeleteQuotaAlarmOutcome deleteQuotaAlarm(const Model::DeleteQuotaAlarmRequest &request)const; void deleteQuotaAlarmAsync(const Model::DeleteQuotaAlarmRequest& request, const DeleteQuotaAlarmAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DeleteQuotaAlarmOutcomeCallable deleteQuotaAlarmCallable(const Model::DeleteQuotaAlarmRequest& request) const; + DeleteTemplateQuotaItemOutcome deleteTemplateQuotaItem(const Model::DeleteTemplateQuotaItemRequest &request)const; + void deleteTemplateQuotaItemAsync(const Model::DeleteTemplateQuotaItemRequest& request, const DeleteTemplateQuotaItemAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteTemplateQuotaItemOutcomeCallable deleteTemplateQuotaItemCallable(const Model::DeleteTemplateQuotaItemRequest& request) const; GetProductQuotaOutcome getProductQuota(const Model::GetProductQuotaRequest &request)const; void getProductQuotaAsync(const Model::GetProductQuotaRequest& request, const GetProductQuotaAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; GetProductQuotaOutcomeCallable getProductQuotaCallable(const Model::GetProductQuotaRequest& request) const; @@ -137,6 +201,12 @@ namespace AlibabaCloud GetQuotaApplicationOutcome getQuotaApplication(const Model::GetQuotaApplicationRequest &request)const; void getQuotaApplicationAsync(const Model::GetQuotaApplicationRequest& request, const GetQuotaApplicationAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; GetQuotaApplicationOutcomeCallable getQuotaApplicationCallable(const Model::GetQuotaApplicationRequest& request) const; + GetQuotaApplicationApprovalOutcome getQuotaApplicationApproval(const Model::GetQuotaApplicationApprovalRequest &request)const; + void getQuotaApplicationApprovalAsync(const Model::GetQuotaApplicationApprovalRequest& request, const GetQuotaApplicationApprovalAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetQuotaApplicationApprovalOutcomeCallable getQuotaApplicationApprovalCallable(const Model::GetQuotaApplicationApprovalRequest& request) const; + GetQuotaTemplateServiceStatusOutcome getQuotaTemplateServiceStatus(const Model::GetQuotaTemplateServiceStatusRequest &request)const; + void getQuotaTemplateServiceStatusAsync(const Model::GetQuotaTemplateServiceStatusRequest& request, const GetQuotaTemplateServiceStatusAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetQuotaTemplateServiceStatusOutcomeCallable getQuotaTemplateServiceStatusCallable(const Model::GetQuotaTemplateServiceStatusRequest& request) const; ListAlarmHistoriesOutcome listAlarmHistories(const Model::ListAlarmHistoriesRequest &request)const; void listAlarmHistoriesAsync(const Model::ListAlarmHistoriesRequest& request, const ListAlarmHistoriesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; ListAlarmHistoriesOutcomeCallable listAlarmHistoriesCallable(const Model::ListAlarmHistoriesRequest& request) const; @@ -158,9 +228,27 @@ namespace AlibabaCloud ListQuotaAlarmsOutcome listQuotaAlarms(const Model::ListQuotaAlarmsRequest &request)const; void listQuotaAlarmsAsync(const Model::ListQuotaAlarmsRequest& request, const ListQuotaAlarmsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; ListQuotaAlarmsOutcomeCallable listQuotaAlarmsCallable(const Model::ListQuotaAlarmsRequest& request) const; + ListQuotaApplicationTemplatesOutcome listQuotaApplicationTemplates(const Model::ListQuotaApplicationTemplatesRequest &request)const; + void listQuotaApplicationTemplatesAsync(const Model::ListQuotaApplicationTemplatesRequest& request, const ListQuotaApplicationTemplatesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListQuotaApplicationTemplatesOutcomeCallable listQuotaApplicationTemplatesCallable(const Model::ListQuotaApplicationTemplatesRequest& request) const; ListQuotaApplicationsOutcome listQuotaApplications(const Model::ListQuotaApplicationsRequest &request)const; void listQuotaApplicationsAsync(const Model::ListQuotaApplicationsRequest& request, const ListQuotaApplicationsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; ListQuotaApplicationsOutcomeCallable listQuotaApplicationsCallable(const Model::ListQuotaApplicationsRequest& request) const; + ListQuotaApplicationsDetailForTemplateOutcome listQuotaApplicationsDetailForTemplate(const Model::ListQuotaApplicationsDetailForTemplateRequest &request)const; + void listQuotaApplicationsDetailForTemplateAsync(const Model::ListQuotaApplicationsDetailForTemplateRequest& request, const ListQuotaApplicationsDetailForTemplateAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListQuotaApplicationsDetailForTemplateOutcomeCallable listQuotaApplicationsDetailForTemplateCallable(const Model::ListQuotaApplicationsDetailForTemplateRequest& request) const; + ListQuotaApplicationsForTemplateOutcome listQuotaApplicationsForTemplate(const Model::ListQuotaApplicationsForTemplateRequest &request)const; + void listQuotaApplicationsForTemplateAsync(const Model::ListQuotaApplicationsForTemplateRequest& request, const ListQuotaApplicationsForTemplateAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ListQuotaApplicationsForTemplateOutcomeCallable listQuotaApplicationsForTemplateCallable(const Model::ListQuotaApplicationsForTemplateRequest& request) const; + ModifyQuotaTemplateServiceStatusOutcome modifyQuotaTemplateServiceStatus(const Model::ModifyQuotaTemplateServiceStatusRequest &request)const; + void modifyQuotaTemplateServiceStatusAsync(const Model::ModifyQuotaTemplateServiceStatusRequest& request, const ModifyQuotaTemplateServiceStatusAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ModifyQuotaTemplateServiceStatusOutcomeCallable modifyQuotaTemplateServiceStatusCallable(const Model::ModifyQuotaTemplateServiceStatusRequest& request) const; + ModifyTemplateQuotaItemOutcome modifyTemplateQuotaItem(const Model::ModifyTemplateQuotaItemRequest &request)const; + void modifyTemplateQuotaItemAsync(const Model::ModifyTemplateQuotaItemRequest& request, const ModifyTemplateQuotaItemAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ModifyTemplateQuotaItemOutcomeCallable modifyTemplateQuotaItemCallable(const Model::ModifyTemplateQuotaItemRequest& request) const; + RemindQuotaApplicationApprovalOutcome remindQuotaApplicationApproval(const Model::RemindQuotaApplicationApprovalRequest &request)const; + void remindQuotaApplicationApprovalAsync(const Model::RemindQuotaApplicationApprovalRequest& request, const RemindQuotaApplicationApprovalAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + RemindQuotaApplicationApprovalOutcomeCallable remindQuotaApplicationApprovalCallable(const Model::RemindQuotaApplicationApprovalRequest& request) const; UpdateQuotaAlarmOutcome updateQuotaAlarm(const Model::UpdateQuotaAlarmRequest &request)const; void updateQuotaAlarmAsync(const Model::UpdateQuotaAlarmRequest& request, const UpdateQuotaAlarmAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; UpdateQuotaAlarmOutcomeCallable updateQuotaAlarmCallable(const Model::UpdateQuotaAlarmRequest& request) const; diff --git a/quotas/include/alibabacloud/quotas/model/CreateQuotaAlarmRequest.h b/quotas/include/alibabacloud/quotas/model/CreateQuotaAlarmRequest.h index 93657be79..5ffbdd1b3 100644 --- a/quotas/include/alibabacloud/quotas/model/CreateQuotaAlarmRequest.h +++ b/quotas/include/alibabacloud/quotas/model/CreateQuotaAlarmRequest.h @@ -1,75 +1,70 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_ - -#include -#include -#include -#include - -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 getQuotaDimensions()const; - void setQuotaDimensions(const std::vector& 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_; - float thresholdPercent_; - std::string alarmName_; - - }; - } - } -} -#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaAlarmRequest : public RpcServiceRequest { +public: + struct QuotaDimensions { + std::string key; + std::string value; + }; + 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 "aActionCode); + std::string getThresholdType() const; + void setThresholdType(const std::string &thresholdType); + std::vector getQuotaDimensions() const; + void setQuotaDimensions(const std::vector "aDimensions); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + 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_; + std::string originalContext_; + float thresholdPercent_; + std::string alarmName_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAALARMREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationRequest.h b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationRequest.h index 878374b3d..0e6fcf4dc 100644 --- a/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationRequest.h +++ b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationRequest.h @@ -1,75 +1,79 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_ - -#include -#include -#include -#include - -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 getDimensions()const; - void setDimensions(const std::vector& dimensions); - - private: - std::string reason_; - std::string productCode_; - std::string quotaActionCode_; - float desireValue_; - std::string quotaCategory_; - int noticeType_; - std::string auditMode_; - std::vector dimensions_; - - }; - } - } -} -#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaApplicationRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + 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 "aActionCode); + float getDesireValue() const; + void setDesireValue(float desireValue); + std::string getEffectiveTime() const; + void setEffectiveTime(const std::string &effectiveTime); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getExpireTime() const; + void setExpireTime(const std::string &expireTime); + std::string getEnvLanguage() const; + void setEnvLanguage(const std::string &envLanguage); + int getNoticeType() const; + void setNoticeType(int noticeType); + std::string getAuditMode() const; + void setAuditMode(const std::string &auditMode); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string reason_; + std::string productCode_; + std::string quotaActionCode_; + float desireValue_; + std::string effectiveTime_; + std::string quotaCategory_; + std::string originalContext_; + std::string expireTime_; + std::string envLanguage_; + int noticeType_; + std::string auditMode_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationResult.h b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationResult.h index 1d6f0fe28..91cdb2ee2 100644 --- a/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationResult.h +++ b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationResult.h @@ -40,10 +40,10 @@ namespace AlibabaCloud 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 getEffectiveTime()const; std::string getAuditReason()const; + std::string getQuotaUnit()const; std::string getDimension()const; float getApproveValue()const; std::string getReason()const; @@ -51,9 +51,9 @@ namespace AlibabaCloud std::string getQuotaName()const; std::string getQuotaArn()const; long getNoticeType()const; - std::string getExpireTime()const; - std::string getApplicationId()const; int getDesireValue()const; + std::string getApplicationId()const; + std::string getExpireTime()const; protected: void parse(const std::string &payload); @@ -61,10 +61,10 @@ namespace AlibabaCloud std::string status_; std::string applyTime_; std::string quotaDescription_; - std::string effectiveTime_; std::string productCode_; - std::string quotaUnit_; + std::string effectiveTime_; std::string auditReason_; + std::string quotaUnit_; std::string dimension_; float approveValue_; std::string reason_; @@ -72,9 +72,9 @@ namespace AlibabaCloud std::string quotaName_; std::string quotaArn_; long noticeType_; - std::string expireTime_; - std::string applicationId_; int desireValue_; + std::string applicationId_; + std::string expireTime_; }; } diff --git a/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateRequest.h b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateRequest.h new file mode 100644 index 000000000..32b565d70 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateRequest.h @@ -0,0 +1,79 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONSFORTEMPLATEREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONSFORTEMPLATEREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaApplicationsForTemplateRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + CreateQuotaApplicationsForTemplateRequest(); + ~CreateQuotaApplicationsForTemplateRequest(); + 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 "aActionCode); + double getDesireValue() const; + void setDesireValue(double desireValue); + std::string getEffectiveTime() const; + void setEffectiveTime(const std::string &effectiveTime); + std::vector getAliyunUids() const; + void setAliyunUids(const std::vector &aliyunUids); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getExpireTime() const; + void setExpireTime(const std::string &expireTime); + std::string getEnvLanguage() const; + void setEnvLanguage(const std::string &envLanguage); + int getNoticeType() const; + void setNoticeType(int noticeType); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string reason_; + std::string productCode_; + std::string quotaActionCode_; + double desireValue_; + std::string effectiveTime_; + std::vector aliyunUids_; + std::string quotaCategory_; + std::string originalContext_; + std::string expireTime_; + std::string envLanguage_; + int noticeType_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONSFORTEMPLATEREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateResult.h b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateResult.h new file mode 100644 index 000000000..8a0952263 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/CreateQuotaApplicationsForTemplateResult.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_CREATEQUOTAAPPLICATIONSFORTEMPLATERESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONSFORTEMPLATERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT CreateQuotaApplicationsForTemplateResult : public ServiceResult + { + public: + struct FailResultsItem + { + std::string aliyunUid; + std::string reason; + }; + + + CreateQuotaApplicationsForTemplateResult(); + explicit CreateQuotaApplicationsForTemplateResult(const std::string &payload); + ~CreateQuotaApplicationsForTemplateResult(); + std::string getBatchQuotaApplicationId()const; + std::vector getAliyunUids()const; + std::vector getFailResults()const; + + protected: + void parse(const std::string &payload); + private: + std::string batchQuotaApplicationId_; + std::vector aliyunUids_; + std::vector failResults_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATEQUOTAAPPLICATIONSFORTEMPLATERESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/CreateTemplateQuotaItemRequest.h b/quotas/include/alibabacloud/quotas/model/CreateTemplateQuotaItemRequest.h new file mode 100644 index 000000000..438445148 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/CreateTemplateQuotaItemRequest.h @@ -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. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_CREATETEMPLATEQUOTAITEMREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_CREATETEMPLATEQUOTAITEMREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT CreateTemplateQuotaItemRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + CreateTemplateQuotaItemRequest(); + ~CreateTemplateQuotaItemRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + float getDesireValue() const; + void setDesireValue(float desireValue); + std::string getEffectiveTime() const; + void setEffectiveTime(const std::string &effectiveTime); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getExpireTime() const; + void setExpireTime(const std::string &expireTime); + std::string getEnvLanguage() const; + void setEnvLanguage(const std::string &envLanguage); + long getNoticeType() const; + void setNoticeType(long noticeType); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string productCode_; + std::string quotaActionCode_; + float desireValue_; + std::string effectiveTime_; + std::string quotaCategory_; + std::string originalContext_; + std::string expireTime_; + std::string envLanguage_; + long noticeType_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATETEMPLATEQUOTAITEMREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/CreateTemplateQuotaItemResult.h b/quotas/include/alibabacloud/quotas/model/CreateTemplateQuotaItemResult.h new file mode 100644 index 000000000..c62dad46c --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/CreateTemplateQuotaItemResult.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_CREATETEMPLATEQUOTAITEMRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_CREATETEMPLATEQUOTAITEMRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT CreateTemplateQuotaItemResult : public ServiceResult + { + public: + + + CreateTemplateQuotaItemResult(); + explicit CreateTemplateQuotaItemResult(const std::string &payload); + ~CreateTemplateQuotaItemResult(); + std::string getId()const; + + protected: + void parse(const std::string &payload); + private: + std::string id_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_CREATETEMPLATEQUOTAITEMRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/DeleteQuotaAlarmRequest.h b/quotas/include/alibabacloud/quotas/model/DeleteQuotaAlarmRequest.h index f19fe3d28..5044c9c54 100644 --- a/quotas/include/alibabacloud/quotas/model/DeleteQuotaAlarmRequest.h +++ b/quotas/include/alibabacloud/quotas/model/DeleteQuotaAlarmRequest.h @@ -1,48 +1,45 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT DeleteQuotaAlarmRequest : public RpcServiceRequest { +public: + DeleteQuotaAlarmRequest(); + ~DeleteQuotaAlarmRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getAlarmId() const; + void setAlarmId(const std::string &alarmId); + +private: + std::string originalContext_; + std::string alarmId_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_DELETEQUOTAALARMREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/DeleteTemplateQuotaItemRequest.h b/quotas/include/alibabacloud/quotas/model/DeleteTemplateQuotaItemRequest.h new file mode 100644 index 000000000..9355ffce6 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/DeleteTemplateQuotaItemRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_DELETETEMPLATEQUOTAITEMREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_DELETETEMPLATEQUOTAITEMREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT DeleteTemplateQuotaItemRequest : public RpcServiceRequest { +public: + DeleteTemplateQuotaItemRequest(); + ~DeleteTemplateQuotaItemRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getId() const; + void setId(const std::string &id); + +private: + std::string originalContext_; + std::string id_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_DELETETEMPLATEQUOTAITEMREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/DeleteTemplateQuotaItemResult.h b/quotas/include/alibabacloud/quotas/model/DeleteTemplateQuotaItemResult.h new file mode 100644 index 000000000..d5785613c --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/DeleteTemplateQuotaItemResult.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_DELETETEMPLATEQUOTAITEMRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_DELETETEMPLATEQUOTAITEMRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT DeleteTemplateQuotaItemResult : public ServiceResult + { + public: + + + DeleteTemplateQuotaItemResult(); + explicit DeleteTemplateQuotaItemResult(const std::string &payload); + ~DeleteTemplateQuotaItemResult(); + std::string getId()const; + + protected: + void parse(const std::string &payload); + private: + std::string id_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_DELETETEMPLATEQUOTAITEMRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/GetProductQuotaDimensionRequest.h b/quotas/include/alibabacloud/quotas/model/GetProductQuotaDimensionRequest.h index de5636134..2dcea15ce 100644 --- a/quotas/include/alibabacloud/quotas/model/GetProductQuotaDimensionRequest.h +++ b/quotas/include/alibabacloud/quotas/model/GetProductQuotaDimensionRequest.h @@ -1,60 +1,55 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_ - -#include -#include -#include -#include - -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 getDependentDimensions()const; - void setDependentDimensions(const std::vector& dependentDimensions); - std::string getDimensionKey()const; - void setDimensionKey(const std::string& dimensionKey); - - private: - std::string productCode_; - std::vector dependentDimensions_; - std::string dimensionKey_; - - }; - } - } -} -#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT GetProductQuotaDimensionRequest : public RpcServiceRequest { +public: + struct DependentDimensions { + std::string key; + std::string value; + }; + GetProductQuotaDimensionRequest(); + ~GetProductQuotaDimensionRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::vector getDependentDimensions() const; + void setDependentDimensions(const std::vector &dependentDimensions); + std::string getDimensionKey() const; + void setDimensionKey(const std::string &dimensionKey); + +private: + std::string originalContext_; + std::string productCode_; + std::vector dependentDimensions_; + std::string dimensionKey_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTADIMENSIONREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/GetProductQuotaRequest.h b/quotas/include/alibabacloud/quotas/model/GetProductQuotaRequest.h index a74fbfc53..0b6003f83 100644 --- a/quotas/include/alibabacloud/quotas/model/GetProductQuotaRequest.h +++ b/quotas/include/alibabacloud/quotas/model/GetProductQuotaRequest.h @@ -1,60 +1,55 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_ - -#include -#include -#include -#include - -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 getDimensions()const; - void setDimensions(const std::vector& dimensions); - - private: - std::string productCode_; - std::string quotaActionCode_; - std::vector dimensions_; - - }; - } - } -} -#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT GetProductQuotaRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + GetProductQuotaRequest(); + ~GetProductQuotaRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string productCode_; + std::string quotaActionCode_; + std::string originalContext_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETPRODUCTQUOTAREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/GetProductQuotaResult.h b/quotas/include/alibabacloud/quotas/model/GetProductQuotaResult.h index efd1dd312..b692162b5 100644 --- a/quotas/include/alibabacloud/quotas/model/GetProductQuotaResult.h +++ b/quotas/include/alibabacloud/quotas/model/GetProductQuotaResult.h @@ -39,28 +39,41 @@ namespace AlibabaCloud int periodValue; std::string periodUnit; }; + struct UsageMetric + { + std::string metricName; + std::string metricDimensions; + std::string metricNamespace; + }; struct QuotaItemsItem { - std::string usage; std::string type; + std::string usage; std::string quota; std::string quotaUnit; }; std::string quotaDescription; - bool consumable; std::string unadjustableDetail; - std::string productCode; + bool consumable; + UsageMetric usageMetric; float totalUsage; + std::string productCode; + std::string effectiveTime; std::string quotaType; Period period; - std::string dimensions; std::string quotaUnit; + std::string dimensions; + bool globalQuota; bool adjustable; std::string quotaActionCode; std::vector quotaItems; std::string quotaName; std::string quotaArn; float totalQuota; + std::string applyReasonTips; + std::string quotaCategory; + std::vector supportedRange; + std::string expireTime; std::string applicableType; std::vector applicableRange; }; diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmRequest.h b/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmRequest.h index f7abf5b28..c518a6c5d 100644 --- a/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmRequest.h +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmRequest.h @@ -1,48 +1,45 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaAlarmRequest : public RpcServiceRequest { +public: + GetQuotaAlarmRequest(); + ~GetQuotaAlarmRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getAlarmId() const; + void setAlarmId(const std::string &alarmId); + +private: + std::string originalContext_; + std::string alarmId_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAALARMREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmResult.h b/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmResult.h index 05bb6ec49..8ebdfaa56 100644 --- a/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmResult.h +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaAlarmResult.h @@ -45,8 +45,9 @@ namespace AlibabaCloud std::string alarmName; std::string notifyTarget; std::string quotaDimension; - float threshold; + std::string webhook; std::string thresholdType; + float threshold; }; diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationApprovalRequest.h b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationApprovalRequest.h new file mode 100644 index 000000000..29bbef5a4 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationApprovalRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONAPPROVALREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONAPPROVALREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaApplicationApprovalRequest : public RpcServiceRequest { +public: + GetQuotaApplicationApprovalRequest(); + ~GetQuotaApplicationApprovalRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getApplicationId() const; + void setApplicationId(const std::string &applicationId); + +private: + std::string originalContext_; + std::string applicationId_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONAPPROVALREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationApprovalResult.h b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationApprovalResult.h new file mode 100644 index 000000000..bc7444c78 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationApprovalResult.h @@ -0,0 +1,74 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONAPPROVALRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONAPPROVALRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaApplicationApprovalResult : public ServiceResult + { + public: + struct Module + { + int reminderIntervalHours; + std::string unsupportReminderReason; + int approvalHours; + bool supportReminder; + }; + + + GetQuotaApplicationApprovalResult(); + explicit GetQuotaApplicationApprovalResult(const std::string &payload); + ~GetQuotaApplicationApprovalResult(); + bool getAllowRetry()const; + std::vector getErrorArgs()const; + int getHttpStatusCode()const; + std::string getErrorMsg()const; + std::string getDynamicCode()const; + std::string getDynamicMessage()const; + std::string getErrorCode()const; + Module getModule()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + bool allowRetry_; + std::vector errorArgs_; + int httpStatusCode_; + std::string errorMsg_; + std::string dynamicCode_; + std::string dynamicMessage_; + std::string errorCode_; + Module module_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONAPPROVALRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationRequest.h b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationRequest.h index b33007c3f..f270515f4 100644 --- a/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationRequest.h +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationRequest.h @@ -1,48 +1,45 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaApplicationRequest : public RpcServiceRequest { +public: + GetQuotaApplicationRequest(); + ~GetQuotaApplicationRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getApplicationId() const; + void setApplicationId(const std::string &applicationId); + +private: + std::string originalContext_; + std::string applicationId_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTAAPPLICATIONREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationResult.h b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationResult.h index 9446bebaf..6fe3e9b8b 100644 --- a/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationResult.h +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaApplicationResult.h @@ -37,10 +37,10 @@ namespace AlibabaCloud std::string status; std::string applyTime; std::string quotaDescription; - std::string effectiveTime; std::string productCode; - std::string quotaUnit; + std::string effectiveTime; std::string auditReason; + std::string quotaUnit; std::string dimension; float approveValue; std::string reason; @@ -48,9 +48,9 @@ namespace AlibabaCloud std::string quotaName; std::string quotaArn; long noticeType; - std::string expireTime; - std::string applicationId; int desireValue; + std::string applicationId; + std::string expireTime; }; diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusRequest.h b/quotas/include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusRequest.h new file mode 100644 index 000000000..3f30fc8bd --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTATEMPLATESERVICESTATUSREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTATEMPLATESERVICESTATUSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaTemplateServiceStatusRequest : public RpcServiceRequest { +public: + GetQuotaTemplateServiceStatusRequest(); + ~GetQuotaTemplateServiceStatusRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getResourceDirectoryId() const; + void setResourceDirectoryId(const std::string &resourceDirectoryId); + +private: + std::string originalContext_; + std::string resourceDirectoryId_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTATEMPLATESERVICESTATUSREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusResult.h b/quotas/include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusResult.h new file mode 100644 index 000000000..87ddbcc22 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/GetQuotaTemplateServiceStatusResult.h @@ -0,0 +1,56 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_GETQUOTATEMPLATESERVICESTATUSRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_GETQUOTATEMPLATESERVICESTATUSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT GetQuotaTemplateServiceStatusResult : public ServiceResult + { + public: + struct TemplateServiceStatus + { + std::string resourceDirectoryId; + int serviceStatus; + }; + + + GetQuotaTemplateServiceStatusResult(); + explicit GetQuotaTemplateServiceStatusResult(const std::string &payload); + ~GetQuotaTemplateServiceStatusResult(); + TemplateServiceStatus getTemplateServiceStatus()const; + + protected: + void parse(const std::string &payload); + private: + TemplateServiceStatus templateServiceStatus_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_GETQUOTATEMPLATESERVICESTATUSRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesRequest.h b/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesRequest.h index 80e482875..7b9a15990 100644 --- a/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesRequest.h @@ -1,63 +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 -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESREQUEST_H_ + +#include +#include +#include +#include +#include + +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); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + long getEndTime() const; + void setEndTime(long endTime); + std::string getAlarmId() const; + void setAlarmId(const std::string &alarmId); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::string productCode_; + long startTime_; + std::string nextToken_; + std::string keyword_; + std::string originalContext_; + long endTime_; + std::string alarmId_; + int maxResults_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTALARMHISTORIESREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesResult.h b/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesResult.h index 73dafe8c0..0c4f13d8b 100644 --- a/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesResult.h +++ b/quotas/include/alibabacloud/quotas/model/ListAlarmHistoriesResult.h @@ -38,8 +38,8 @@ namespace AlibabaCloud std::vector notifyChannels; float thresholdPercent; std::string alarmName; - std::string productCode; std::string notifyTarget; + std::string productCode; std::string createTime; float quotaUsage; float threshold; diff --git a/quotas/include/alibabacloud/quotas/model/ListDependentQuotasRequest.h b/quotas/include/alibabacloud/quotas/model/ListDependentQuotasRequest.h index 17ece5d7e..cec47e134 100644 --- a/quotas/include/alibabacloud/quotas/model/ListDependentQuotasRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListDependentQuotasRequest.h @@ -1,51 +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_LISTDEPENDENTQUOTASREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListDependentQuotasRequest : public RpcServiceRequest { +public: + ListDependentQuotasRequest(); + ~ListDependentQuotasRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + +private: + std::string originalContext_; + std::string productCode_; + std::string quotaActionCode_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTDEPENDENTQUOTASREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListDependentQuotasResult.h b/quotas/include/alibabacloud/quotas/model/ListDependentQuotasResult.h index 0fe6a3297..c8154b58b 100644 --- a/quotas/include/alibabacloud/quotas/model/ListDependentQuotasResult.h +++ b/quotas/include/alibabacloud/quotas/model/ListDependentQuotasResult.h @@ -37,8 +37,8 @@ namespace AlibabaCloud struct DimensionsItem { std::string dimensionKey; - std::vector dimensionValues; std::vector dependentDimension; + std::vector dimensionValues; }; std::string quotaActionCode; std::string productCode; diff --git a/quotas/include/alibabacloud/quotas/model/ListProductDimensionGroupsRequest.h b/quotas/include/alibabacloud/quotas/model/ListProductDimensionGroupsRequest.h index a058174f9..eb5b52592 100644 --- a/quotas/include/alibabacloud/quotas/model/ListProductDimensionGroupsRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListProductDimensionGroupsRequest.h @@ -1,54 +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_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListProductDimensionGroupsRequest : public RpcServiceRequest { +public: + ListProductDimensionGroupsRequest(); + ~ListProductDimensionGroupsRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + 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 originalContext_; + std::string productCode_; + std::string nextToken_; + int maxResults_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTDIMENSIONGROUPSREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsRequest.h b/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsRequest.h index 0ca2c93b8..ee6b4ec95 100644 --- a/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsRequest.h @@ -1,57 +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_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_ + +#include +#include +#include +#include +#include + +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); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::string productCode_; + std::string nextToken_; + std::string quotaCategory_; + std::string originalContext_; + int maxResults_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTADIMENSIONSREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsResult.h b/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsResult.h index 29a7449f5..8cc854831 100644 --- a/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsResult.h +++ b/quotas/include/alibabacloud/quotas/model/ListProductQuotaDimensionsResult.h @@ -36,14 +36,20 @@ namespace AlibabaCloud { struct DimensionValueDetailItem { + struct DependentDimension + { + std::string value; + std::string key; + }; std::string value; + std::vector dependentDimensions1; std::string name; }; std::string dimensionKey; std::vector dimensionValues; std::vector dimensionValueDetail; - std::string name; bool requisite; + std::string name; std::vector dependentDimensions; }; diff --git a/quotas/include/alibabacloud/quotas/model/ListProductQuotasRequest.h b/quotas/include/alibabacloud/quotas/model/ListProductQuotasRequest.h index 50335502e..d3cbf00dd 100644 --- a/quotas/include/alibabacloud/quotas/model/ListProductQuotasRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListProductQuotasRequest.h @@ -1,81 +1,76 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_ - -#include -#include -#include -#include - -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 getDimensions()const; - void setDimensions(const std::vector& 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_; - - }; - } - } -} -#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListProductQuotasRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + ListProductQuotasRequest(); + ~ListProductQuotasRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + 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 "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + int getMaxResults() const; + void setMaxResults(int maxResults); + std::string getSortField() const; + void setSortField(const std::string &sortField); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string productCode_; + std::string quotaActionCode_; + std::string groupCode_; + std::string nextToken_; + std::string sortOrder_; + std::string keyWord_; + std::string quotaCategory_; + std::string originalContext_; + int maxResults_; + std::string sortField_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTQUOTASREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListProductQuotasResult.h b/quotas/include/alibabacloud/quotas/model/ListProductQuotasResult.h index 25d936bc4..b2860c5ef 100644 --- a/quotas/include/alibabacloud/quotas/model/ListProductQuotasResult.h +++ b/quotas/include/alibabacloud/quotas/model/ListProductQuotasResult.h @@ -39,28 +39,41 @@ namespace AlibabaCloud int periodValue; std::string periodUnit; }; + struct UsageMetric + { + std::string metricName; + std::string metricDimensions; + std::string metricNamespace; + }; struct QuotaItemsItem { - std::string usage; std::string type; + std::string usage; std::string quota; std::string quotaUnit; }; std::string quotaDescription; - bool consumable; std::string unadjustableDetail; - std::string productCode; + bool consumable; + UsageMetric usageMetric; float totalUsage; + std::string productCode; + std::string effectiveTime; std::string quotaType; Period period; - std::string dimensions; std::string quotaUnit; + std::string dimensions; + bool globalQuota; bool adjustable; std::string quotaActionCode; std::vector quotaItems; std::string quotaName; std::string quotaArn; float totalQuota; + std::string applyReasonTips; + std::string quotaCategory; + std::vector supportedRange; + std::string expireTime; std::string applicableType; std::vector applicableRange; }; diff --git a/quotas/include/alibabacloud/quotas/model/ListProductsRequest.h b/quotas/include/alibabacloud/quotas/model/ListProductsRequest.h index de71fc3ad..79da33c93 100644 --- a/quotas/include/alibabacloud/quotas/model/ListProductsRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListProductsRequest.h @@ -1,51 +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_LISTPRODUCTSREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListProductsRequest : public RpcServiceRequest { +public: + ListProductsRequest(); + ~ListProductsRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::string originalContext_; + std::string nextToken_; + int maxResults_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTPRODUCTSREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListProductsResult.h b/quotas/include/alibabacloud/quotas/model/ListProductsResult.h index 724851fe8..4cf29af32 100644 --- a/quotas/include/alibabacloud/quotas/model/ListProductsResult.h +++ b/quotas/include/alibabacloud/quotas/model/ListProductsResult.h @@ -34,13 +34,14 @@ namespace AlibabaCloud public: struct ProductInfos { - std::string secondCategoryNameEn; bool dynamic; - std::string commonQuotaSupport; + std::string secondCategoryNameEn; std::string productName; - std::string productCode; + std::string commonQuotaSupport; std::string secondCategoryName; + std::string productCode; std::string flowControlSupport; + std::string whiteListLabelQuotaSupport; long secondCategoryId; std::string productNameEn; }; diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsRequest.h b/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsRequest.h index 97b64165f..b9ad8f263 100644 --- a/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsRequest.h @@ -1,69 +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_LISTQUOTAALARMSREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_ - -#include -#include -#include -#include - -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 getQuotaDimensions()const; - void setQuotaDimensions(const std::vector& 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_; - int maxResults_; - std::string alarmName_; - - }; - } - } -} -#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaAlarmsRequest : public RpcServiceRequest { +public: + struct QuotaDimensions { + std::string key; + std::string value; + }; + ListQuotaAlarmsRequest(); + ~ListQuotaAlarmsRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::vector getQuotaDimensions() const; + void setQuotaDimensions(const std::vector "aDimensions); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + 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_; + std::string originalContext_; + int maxResults_; + std::string alarmName_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAALARMSREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsResult.h b/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsResult.h index 34d6ff7c2..dbbee06d5 100644 --- a/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsResult.h +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaAlarmsResult.h @@ -47,8 +47,8 @@ namespace AlibabaCloud float quotaValue; std::string alarmName; std::string notifyTarget; - float threshold; std::string thresholdType; + float threshold; }; diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesRequest.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesRequest.h new file mode 100644 index 000000000..a63f640c1 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesRequest.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_LISTQUOTAAPPLICATIONTEMPLATESREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONTEMPLATESREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationTemplatesRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + ListQuotaApplicationTemplatesRequest(); + ~ListQuotaApplicationTemplatesRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getId() const; + void setId(const std::string &id); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + int getMaxResults() const; + void setMaxResults(int maxResults); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string productCode_; + std::string quotaActionCode_; + std::string nextToken_; + std::string id_; + std::string quotaCategory_; + std::string originalContext_; + int maxResults_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONTEMPLATESREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesResult.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesResult.h new file mode 100644 index 000000000..d8d560949 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationTemplatesResult.h @@ -0,0 +1,80 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONTEMPLATESRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONTEMPLATESRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationTemplatesResult : public ServiceResult + { + public: + struct QuotaApplicationTemplatesItem + { + struct Period + { + int periodValue; + std::string periodUnit; + }; + std::string quotaDescription; + std::string productCode; + std::string effectiveTime; + Period period; + std::string dimensions; + std::string envLanguage; + std::string quotaActionCode; + std::string quotaName; + std::string quotaCategory; + int noticeType; + std::string id; + float desireValue; + std::string expireTime; + std::string applicableType; + std::vector applicableRange; + }; + + + ListQuotaApplicationTemplatesResult(); + explicit ListQuotaApplicationTemplatesResult(const std::string &payload); + ~ListQuotaApplicationTemplatesResult(); + int getTotalCount()const; + std::string getNextToken()const; + int getMaxResults()const; + std::vector getQuotaApplicationTemplates()const; + + protected: + void parse(const std::string &payload); + private: + int totalCount_; + std::string nextToken_; + int maxResults_; + std::vector quotaApplicationTemplates_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONTEMPLATESRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateRequest.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateRequest.h new file mode 100644 index 000000000..155dc81d9 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateRequest.h @@ -0,0 +1,66 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSDETAILFORTEMPLATEREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSDETAILFORTEMPLATEREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationsDetailForTemplateRequest : public RpcServiceRequest { +public: + ListQuotaApplicationsDetailForTemplateRequest(); + ~ListQuotaApplicationsDetailForTemplateRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + std::string getBatchQuotaApplicationId() const; + void setBatchQuotaApplicationId(const std::string &batchQuotaApplicationId); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getAliyunUid() const; + void setAliyunUid(const std::string &aliyunUid); + int getMaxResults() const; + void setMaxResults(int maxResults); + std::string getStatus() const; + void setStatus(const std::string &status); + +private: + std::string productCode_; + std::string quotaActionCode_; + std::string batchQuotaApplicationId_; + std::string nextToken_; + std::string quotaCategory_; + std::string originalContext_; + std::string aliyunUid_; + int maxResults_; + std::string status_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSDETAILFORTEMPLATEREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateResult.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateResult.h new file mode 100644 index 000000000..2cb958fb7 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsDetailForTemplateResult.h @@ -0,0 +1,87 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSDETAILFORTEMPLATERESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSDETAILFORTEMPLATERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationsDetailForTemplateResult : public ServiceResult + { + public: + struct QuotaBatchApplicationDetailVos + { + struct Period + { + int periodValue; + std::string periodUnit; + }; + std::string status; + std::string applyTime; + std::string quotaDescription; + std::string batchQuotaApplicationId; + std::string productCode; + std::string effectiveTime; + Period period; + std::string quotaUnit; + std::string auditReason; + double approveValue; + std::string reason; + std::string envLanguage; + std::string quotaActionCode; + std::string quotaName; + std::string quotaArn; + std::string aliyunUid; + std::string quotaCategory; + int noticeType; + std::string quotaDimension; + std::string applicationId; + double desireValue; + std::string expireTime; + }; + + + ListQuotaApplicationsDetailForTemplateResult(); + explicit ListQuotaApplicationsDetailForTemplateResult(const std::string &payload); + ~ListQuotaApplicationsDetailForTemplateResult(); + std::vector getQuotaApplications()const; + int getTotalCount()const; + std::string getNextToken()const; + int getMaxResults()const; + + protected: + void parse(const std::string &payload); + private: + std::vector quotaApplications_; + int totalCount_; + std::string nextToken_; + int maxResults_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSDETAILFORTEMPLATERESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateRequest.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateRequest.h new file mode 100644 index 000000000..eb955ae9f --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateRequest.h @@ -0,0 +1,66 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSFORTEMPLATEREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSFORTEMPLATEREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationsForTemplateRequest : public RpcServiceRequest { +public: + ListQuotaApplicationsForTemplateRequest(); + ~ListQuotaApplicationsForTemplateRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + std::string getBatchQuotaApplicationId() const; + void setBatchQuotaApplicationId(const std::string &batchQuotaApplicationId); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getApplyStartTime() const; + void setApplyStartTime(const std::string &applyStartTime); + std::string getApplyEndTime() const; + void setApplyEndTime(const std::string &applyEndTime); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::string productCode_; + std::string quotaActionCode_; + std::string batchQuotaApplicationId_; + std::string nextToken_; + std::string quotaCategory_; + std::string originalContext_; + std::string applyStartTime_; + std::string applyEndTime_; + int maxResults_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSFORTEMPLATEREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateResult.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateResult.h new file mode 100644 index 000000000..13564fc1c --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsForTemplateResult.h @@ -0,0 +1,77 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSFORTEMPLATERESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSFORTEMPLATERESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationsForTemplateResult : public ServiceResult + { + public: + struct QuotaBatchApplicationsItem + { + struct AuditStatusVo + { + std::string status; + int count; + }; + std::string quotaActionCode; + std::string applyTime; + std::vector auditStatusVos; + std::string productCode; + std::string batchQuotaApplicationId; + std::string effectiveTime; + std::string quotaCategory; + std::vector aliyunUids; + std::string dimensions; + std::string expireTime; + double desireValue; + std::string reason; + }; + + + ListQuotaApplicationsForTemplateResult(); + explicit ListQuotaApplicationsForTemplateResult(const std::string &payload); + ~ListQuotaApplicationsForTemplateResult(); + int getTotalCount()const; + std::string getNextToken()const; + std::vector getQuotaBatchApplications()const; + int getMaxResults()const; + + protected: + void parse(const std::string &payload); + private: + int totalCount_; + std::string nextToken_; + std::vector quotaBatchApplications_; + int maxResults_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSFORTEMPLATERESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsRequest.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsRequest.h index b3d6b4363..1fe897388 100644 --- a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsRequest.h +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsRequest.h @@ -1,75 +1,70 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_ - -#include -#include -#include -#include - -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 getDimensions()const; - void setDimensions(const std::vector& 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_; - - }; - } - } -} -#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ListQuotaApplicationsRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + ListQuotaApplicationsRequest(); + ~ListQuotaApplicationsRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + 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 "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + int getMaxResults() const; + void setMaxResults(int maxResults); + std::string getStatus() const; + void setStatus(const std::string &status); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string productCode_; + std::string quotaActionCode_; + std::string nextToken_; + std::string keyWord_; + std::string quotaCategory_; + std::string originalContext_; + int maxResults_; + std::string status_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_LISTQUOTAAPPLICATIONSREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsResult.h b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsResult.h index 04904799a..62c4c6629 100644 --- a/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsResult.h +++ b/quotas/include/alibabacloud/quotas/model/ListQuotaApplicationsResult.h @@ -40,14 +40,14 @@ namespace AlibabaCloud std::string periodUnit; }; std::string status; - std::string applyTime; std::string comment; + std::string applyTime; std::string quotaDescription; - std::string productCode; std::string effectiveTime; + std::string productCode; Period period; - std::string auditReason; std::string quotaUnit; + std::string auditReason; std::string dimension; float approveValue; std::string reason; @@ -55,9 +55,9 @@ namespace AlibabaCloud std::string quotaName; std::string quotaArn; int noticeType; - std::string applicationId; - float desireValue; std::string expireTime; + float desireValue; + std::string applicationId; }; diff --git a/quotas/include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusRequest.h b/quotas/include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusRequest.h new file mode 100644 index 000000000..23574296e --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_MODIFYQUOTATEMPLATESERVICESTATUSREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_MODIFYQUOTATEMPLATESERVICESTATUSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ModifyQuotaTemplateServiceStatusRequest : public RpcServiceRequest { +public: + ModifyQuotaTemplateServiceStatusRequest(); + ~ModifyQuotaTemplateServiceStatusRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + int getServiceStatus() const; + void setServiceStatus(int serviceStatus); + +private: + std::string originalContext_; + int serviceStatus_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_MODIFYQUOTATEMPLATESERVICESTATUSREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusResult.h b/quotas/include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusResult.h new file mode 100644 index 000000000..ebfe895af --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ModifyQuotaTemplateServiceStatusResult.h @@ -0,0 +1,56 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_MODIFYQUOTATEMPLATESERVICESTATUSRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_MODIFYQUOTATEMPLATESERVICESTATUSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT ModifyQuotaTemplateServiceStatusResult : public ServiceResult + { + public: + struct TemplateServiceStatus + { + std::string resourceDirectoryId; + int serviceStatus; + }; + + + ModifyQuotaTemplateServiceStatusResult(); + explicit ModifyQuotaTemplateServiceStatusResult(const std::string &payload); + ~ModifyQuotaTemplateServiceStatusResult(); + TemplateServiceStatus getTemplateServiceStatus()const; + + protected: + void parse(const std::string &payload); + private: + TemplateServiceStatus templateServiceStatus_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_MODIFYQUOTATEMPLATESERVICESTATUSRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/ModifyTemplateQuotaItemRequest.h b/quotas/include/alibabacloud/quotas/model/ModifyTemplateQuotaItemRequest.h new file mode 100644 index 000000000..55a968034 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ModifyTemplateQuotaItemRequest.h @@ -0,0 +1,76 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_MODIFYTEMPLATEQUOTAITEMREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_MODIFYTEMPLATEQUOTAITEMREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT ModifyTemplateQuotaItemRequest : public RpcServiceRequest { +public: + struct Dimensions { + std::string key; + std::string value; + }; + ModifyTemplateQuotaItemRequest(); + ~ModifyTemplateQuotaItemRequest(); + std::string getProductCode() const; + void setProductCode(const std::string &productCode); + std::string getQuotaActionCode() const; + void setQuotaActionCode(const std::string "aActionCode); + float getDesireValue() const; + void setDesireValue(float desireValue); + std::string getEffectiveTime() const; + void setEffectiveTime(const std::string &effectiveTime); + std::string getId() const; + void setId(const std::string &id); + std::string getQuotaCategory() const; + void setQuotaCategory(const std::string "aCategory); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getExpireTime() const; + void setExpireTime(const std::string &expireTime); + std::string getEnvLanguage() const; + void setEnvLanguage(const std::string &envLanguage); + long getNoticeType() const; + void setNoticeType(long noticeType); + std::vector getDimensions() const; + void setDimensions(const std::vector &dimensions); + +private: + std::string productCode_; + std::string quotaActionCode_; + float desireValue_; + std::string effectiveTime_; + std::string id_; + std::string quotaCategory_; + std::string originalContext_; + std::string expireTime_; + std::string envLanguage_; + long noticeType_; + std::vector dimensions_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_MODIFYTEMPLATEQUOTAITEMREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/ModifyTemplateQuotaItemResult.h b/quotas/include/alibabacloud/quotas/model/ModifyTemplateQuotaItemResult.h new file mode 100644 index 000000000..40f7af1ff --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/ModifyTemplateQuotaItemResult.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_MODIFYTEMPLATEQUOTAITEMRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_MODIFYTEMPLATEQUOTAITEMRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT ModifyTemplateQuotaItemResult : public ServiceResult + { + public: + + + ModifyTemplateQuotaItemResult(); + explicit ModifyTemplateQuotaItemResult(const std::string &payload); + ~ModifyTemplateQuotaItemResult(); + std::string getId()const; + + protected: + void parse(const std::string &payload); + private: + std::string id_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_MODIFYTEMPLATEQUOTAITEMRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalRequest.h b/quotas/include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalRequest.h new file mode 100644 index 000000000..779e4b8e6 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_REMINDQUOTAAPPLICATIONAPPROVALREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_REMINDQUOTAAPPLICATIONAPPROVALREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Quotas { +namespace Model { +class ALIBABACLOUD_QUOTAS_EXPORT RemindQuotaApplicationApprovalRequest : public RpcServiceRequest { +public: + RemindQuotaApplicationApprovalRequest(); + ~RemindQuotaApplicationApprovalRequest(); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + std::string getApplicationId() const; + void setApplicationId(const std::string &applicationId); + +private: + std::string originalContext_; + std::string applicationId_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_REMINDQUOTAAPPLICATIONAPPROVALREQUEST_H_ diff --git a/quotas/include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalResult.h b/quotas/include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalResult.h new file mode 100644 index 000000000..28334da36 --- /dev/null +++ b/quotas/include/alibabacloud/quotas/model/RemindQuotaApplicationApprovalResult.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_REMINDQUOTAAPPLICATIONAPPROVALRESULT_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_REMINDQUOTAAPPLICATIONAPPROVALRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Quotas + { + namespace Model + { + class ALIBABACLOUD_QUOTAS_EXPORT RemindQuotaApplicationApprovalResult : public ServiceResult + { + public: + + + RemindQuotaApplicationApprovalResult(); + explicit RemindQuotaApplicationApprovalResult(const std::string &payload); + ~RemindQuotaApplicationApprovalResult(); + bool getAllowRetry()const; + std::vector getErrorArgs()const; + int getHttpStatusCode()const; + std::string getErrorMsg()const; + std::string getDynamicCode()const; + std::string getDynamicMessage()const; + std::string getErrorCode()const; + std::string getModule()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + bool allowRetry_; + std::vector errorArgs_; + int httpStatusCode_; + std::string errorMsg_; + std::string dynamicCode_; + std::string dynamicMessage_; + std::string errorCode_; + std::string module_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_QUOTAS_MODEL_REMINDQUOTAAPPLICATIONAPPROVALRESULT_H_ \ No newline at end of file diff --git a/quotas/include/alibabacloud/quotas/model/UpdateQuotaAlarmRequest.h b/quotas/include/alibabacloud/quotas/model/UpdateQuotaAlarmRequest.h index f9d023082..fc80044e1 100644 --- a/quotas/include/alibabacloud/quotas/model/UpdateQuotaAlarmRequest.h +++ b/quotas/include/alibabacloud/quotas/model/UpdateQuotaAlarmRequest.h @@ -1,63 +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_UPDATEQUOTAALARMREQUEST_H_ -#define ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMREQUEST_H_ - -#include -#include -#include -#include - -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_ \ No newline at end of file + */ + +#ifndef ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMREQUEST_H_ +#define ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMREQUEST_H_ + +#include +#include +#include +#include +#include + +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); + std::string getOriginalContext() const; + void setOriginalContext(const std::string &originalContext); + 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_; + std::string originalContext_; + float thresholdPercent_; + std::string alarmId_; + std::string alarmName_; +}; +} // namespace Model +} // namespace Quotas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_QUOTAS_MODEL_UPDATEQUOTAALARMREQUEST_H_ diff --git a/quotas/src/QuotasClient.cc b/quotas/src/QuotasClient.cc index d41c9ecb0..fcb5b3107 100644 --- a/quotas/src/QuotasClient.cc +++ b/quotas/src/QuotasClient.cc @@ -123,6 +123,78 @@ QuotasClient::CreateQuotaApplicationOutcomeCallable QuotasClient::createQuotaApp return task->get_future(); } +QuotasClient::CreateQuotaApplicationsForTemplateOutcome QuotasClient::createQuotaApplicationsForTemplate(const CreateQuotaApplicationsForTemplateRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateQuotaApplicationsForTemplateOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateQuotaApplicationsForTemplateOutcome(CreateQuotaApplicationsForTemplateResult(outcome.result())); + else + return CreateQuotaApplicationsForTemplateOutcome(outcome.error()); +} + +void QuotasClient::createQuotaApplicationsForTemplateAsync(const CreateQuotaApplicationsForTemplateRequest& request, const CreateQuotaApplicationsForTemplateAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createQuotaApplicationsForTemplate(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::CreateQuotaApplicationsForTemplateOutcomeCallable QuotasClient::createQuotaApplicationsForTemplateCallable(const CreateQuotaApplicationsForTemplateRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createQuotaApplicationsForTemplate(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +QuotasClient::CreateTemplateQuotaItemOutcome QuotasClient::createTemplateQuotaItem(const CreateTemplateQuotaItemRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateTemplateQuotaItemOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateTemplateQuotaItemOutcome(CreateTemplateQuotaItemResult(outcome.result())); + else + return CreateTemplateQuotaItemOutcome(outcome.error()); +} + +void QuotasClient::createTemplateQuotaItemAsync(const CreateTemplateQuotaItemRequest& request, const CreateTemplateQuotaItemAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createTemplateQuotaItem(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::CreateTemplateQuotaItemOutcomeCallable QuotasClient::createTemplateQuotaItemCallable(const CreateTemplateQuotaItemRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createTemplateQuotaItem(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + QuotasClient::DeleteQuotaAlarmOutcome QuotasClient::deleteQuotaAlarm(const DeleteQuotaAlarmRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -159,6 +231,42 @@ QuotasClient::DeleteQuotaAlarmOutcomeCallable QuotasClient::deleteQuotaAlarmCall return task->get_future(); } +QuotasClient::DeleteTemplateQuotaItemOutcome QuotasClient::deleteTemplateQuotaItem(const DeleteTemplateQuotaItemRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteTemplateQuotaItemOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteTemplateQuotaItemOutcome(DeleteTemplateQuotaItemResult(outcome.result())); + else + return DeleteTemplateQuotaItemOutcome(outcome.error()); +} + +void QuotasClient::deleteTemplateQuotaItemAsync(const DeleteTemplateQuotaItemRequest& request, const DeleteTemplateQuotaItemAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteTemplateQuotaItem(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::DeleteTemplateQuotaItemOutcomeCallable QuotasClient::deleteTemplateQuotaItemCallable(const DeleteTemplateQuotaItemRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteTemplateQuotaItem(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + QuotasClient::GetProductQuotaOutcome QuotasClient::getProductQuota(const GetProductQuotaRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -303,6 +411,78 @@ QuotasClient::GetQuotaApplicationOutcomeCallable QuotasClient::getQuotaApplicati return task->get_future(); } +QuotasClient::GetQuotaApplicationApprovalOutcome QuotasClient::getQuotaApplicationApproval(const GetQuotaApplicationApprovalRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetQuotaApplicationApprovalOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetQuotaApplicationApprovalOutcome(GetQuotaApplicationApprovalResult(outcome.result())); + else + return GetQuotaApplicationApprovalOutcome(outcome.error()); +} + +void QuotasClient::getQuotaApplicationApprovalAsync(const GetQuotaApplicationApprovalRequest& request, const GetQuotaApplicationApprovalAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getQuotaApplicationApproval(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::GetQuotaApplicationApprovalOutcomeCallable QuotasClient::getQuotaApplicationApprovalCallable(const GetQuotaApplicationApprovalRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getQuotaApplicationApproval(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +QuotasClient::GetQuotaTemplateServiceStatusOutcome QuotasClient::getQuotaTemplateServiceStatus(const GetQuotaTemplateServiceStatusRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetQuotaTemplateServiceStatusOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetQuotaTemplateServiceStatusOutcome(GetQuotaTemplateServiceStatusResult(outcome.result())); + else + return GetQuotaTemplateServiceStatusOutcome(outcome.error()); +} + +void QuotasClient::getQuotaTemplateServiceStatusAsync(const GetQuotaTemplateServiceStatusRequest& request, const GetQuotaTemplateServiceStatusAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getQuotaTemplateServiceStatus(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::GetQuotaTemplateServiceStatusOutcomeCallable QuotasClient::getQuotaTemplateServiceStatusCallable(const GetQuotaTemplateServiceStatusRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getQuotaTemplateServiceStatus(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + QuotasClient::ListAlarmHistoriesOutcome QuotasClient::listAlarmHistories(const ListAlarmHistoriesRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -555,6 +735,42 @@ QuotasClient::ListQuotaAlarmsOutcomeCallable QuotasClient::listQuotaAlarmsCallab return task->get_future(); } +QuotasClient::ListQuotaApplicationTemplatesOutcome QuotasClient::listQuotaApplicationTemplates(const ListQuotaApplicationTemplatesRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListQuotaApplicationTemplatesOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListQuotaApplicationTemplatesOutcome(ListQuotaApplicationTemplatesResult(outcome.result())); + else + return ListQuotaApplicationTemplatesOutcome(outcome.error()); +} + +void QuotasClient::listQuotaApplicationTemplatesAsync(const ListQuotaApplicationTemplatesRequest& request, const ListQuotaApplicationTemplatesAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listQuotaApplicationTemplates(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::ListQuotaApplicationTemplatesOutcomeCallable QuotasClient::listQuotaApplicationTemplatesCallable(const ListQuotaApplicationTemplatesRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listQuotaApplicationTemplates(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + QuotasClient::ListQuotaApplicationsOutcome QuotasClient::listQuotaApplications(const ListQuotaApplicationsRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -591,6 +807,186 @@ QuotasClient::ListQuotaApplicationsOutcomeCallable QuotasClient::listQuotaApplic return task->get_future(); } +QuotasClient::ListQuotaApplicationsDetailForTemplateOutcome QuotasClient::listQuotaApplicationsDetailForTemplate(const ListQuotaApplicationsDetailForTemplateRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListQuotaApplicationsDetailForTemplateOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListQuotaApplicationsDetailForTemplateOutcome(ListQuotaApplicationsDetailForTemplateResult(outcome.result())); + else + return ListQuotaApplicationsDetailForTemplateOutcome(outcome.error()); +} + +void QuotasClient::listQuotaApplicationsDetailForTemplateAsync(const ListQuotaApplicationsDetailForTemplateRequest& request, const ListQuotaApplicationsDetailForTemplateAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listQuotaApplicationsDetailForTemplate(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::ListQuotaApplicationsDetailForTemplateOutcomeCallable QuotasClient::listQuotaApplicationsDetailForTemplateCallable(const ListQuotaApplicationsDetailForTemplateRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listQuotaApplicationsDetailForTemplate(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +QuotasClient::ListQuotaApplicationsForTemplateOutcome QuotasClient::listQuotaApplicationsForTemplate(const ListQuotaApplicationsForTemplateRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ListQuotaApplicationsForTemplateOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ListQuotaApplicationsForTemplateOutcome(ListQuotaApplicationsForTemplateResult(outcome.result())); + else + return ListQuotaApplicationsForTemplateOutcome(outcome.error()); +} + +void QuotasClient::listQuotaApplicationsForTemplateAsync(const ListQuotaApplicationsForTemplateRequest& request, const ListQuotaApplicationsForTemplateAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, listQuotaApplicationsForTemplate(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::ListQuotaApplicationsForTemplateOutcomeCallable QuotasClient::listQuotaApplicationsForTemplateCallable(const ListQuotaApplicationsForTemplateRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->listQuotaApplicationsForTemplate(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +QuotasClient::ModifyQuotaTemplateServiceStatusOutcome QuotasClient::modifyQuotaTemplateServiceStatus(const ModifyQuotaTemplateServiceStatusRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ModifyQuotaTemplateServiceStatusOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ModifyQuotaTemplateServiceStatusOutcome(ModifyQuotaTemplateServiceStatusResult(outcome.result())); + else + return ModifyQuotaTemplateServiceStatusOutcome(outcome.error()); +} + +void QuotasClient::modifyQuotaTemplateServiceStatusAsync(const ModifyQuotaTemplateServiceStatusRequest& request, const ModifyQuotaTemplateServiceStatusAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, modifyQuotaTemplateServiceStatus(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::ModifyQuotaTemplateServiceStatusOutcomeCallable QuotasClient::modifyQuotaTemplateServiceStatusCallable(const ModifyQuotaTemplateServiceStatusRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->modifyQuotaTemplateServiceStatus(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +QuotasClient::ModifyTemplateQuotaItemOutcome QuotasClient::modifyTemplateQuotaItem(const ModifyTemplateQuotaItemRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ModifyTemplateQuotaItemOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ModifyTemplateQuotaItemOutcome(ModifyTemplateQuotaItemResult(outcome.result())); + else + return ModifyTemplateQuotaItemOutcome(outcome.error()); +} + +void QuotasClient::modifyTemplateQuotaItemAsync(const ModifyTemplateQuotaItemRequest& request, const ModifyTemplateQuotaItemAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, modifyTemplateQuotaItem(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::ModifyTemplateQuotaItemOutcomeCallable QuotasClient::modifyTemplateQuotaItemCallable(const ModifyTemplateQuotaItemRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->modifyTemplateQuotaItem(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +QuotasClient::RemindQuotaApplicationApprovalOutcome QuotasClient::remindQuotaApplicationApproval(const RemindQuotaApplicationApprovalRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return RemindQuotaApplicationApprovalOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return RemindQuotaApplicationApprovalOutcome(RemindQuotaApplicationApprovalResult(outcome.result())); + else + return RemindQuotaApplicationApprovalOutcome(outcome.error()); +} + +void QuotasClient::remindQuotaApplicationApprovalAsync(const RemindQuotaApplicationApprovalRequest& request, const RemindQuotaApplicationApprovalAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, remindQuotaApplicationApproval(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +QuotasClient::RemindQuotaApplicationApprovalOutcomeCallable QuotasClient::remindQuotaApplicationApprovalCallable(const RemindQuotaApplicationApprovalRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->remindQuotaApplicationApproval(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + QuotasClient::UpdateQuotaAlarmOutcome QuotasClient::updateQuotaAlarm(const UpdateQuotaAlarmRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); diff --git a/quotas/src/model/CreateQuotaAlarmRequest.cc b/quotas/src/model/CreateQuotaAlarmRequest.cc index c975bb0da..66aacc0c5 100644 --- a/quotas/src/model/CreateQuotaAlarmRequest.cc +++ b/quotas/src/model/CreateQuotaAlarmRequest.cc @@ -1,122 +1,113 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::CreateQuotaAlarmRequest; - -CreateQuotaAlarmRequest::CreateQuotaAlarmRequest() : - RpcServiceRequest("quotas", "2020-05-10", "CreateQuotaAlarm") -{ - setMethod(HttpRequest::Method::Post); -} - -CreateQuotaAlarmRequest::~CreateQuotaAlarmRequest() -{} - -std::string CreateQuotaAlarmRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::CreateQuotaAlarmRequest; + +CreateQuotaAlarmRequest::CreateQuotaAlarmRequest() + : RpcServiceRequest("quotas", "2020-05-10", "CreateQuotaAlarm") { + setMethod(HttpRequest::Method::Post); } -void CreateQuotaAlarmRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +CreateQuotaAlarmRequest::~CreateQuotaAlarmRequest() {} + +std::string CreateQuotaAlarmRequest::getProductCode() const { + return productCode_; } -std::string CreateQuotaAlarmRequest::getWebHook()const -{ - return webHook_; +void CreateQuotaAlarmRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void CreateQuotaAlarmRequest::setWebHook(const std::string& webHook) -{ - webHook_ = webHook; - setBodyParameter("WebHook", webHook); +std::string CreateQuotaAlarmRequest::getWebHook() const { + return webHook_; } -float CreateQuotaAlarmRequest::getThreshold()const -{ - return threshold_; +void CreateQuotaAlarmRequest::setWebHook(const std::string &webHook) { + webHook_ = webHook; + setBodyParameter(std::string("WebHook"), webHook); } -void CreateQuotaAlarmRequest::setThreshold(float threshold) -{ - threshold_ = threshold; - setBodyParameter("Threshold", std::to_string(threshold)); +float CreateQuotaAlarmRequest::getThreshold() const { + return threshold_; } -std::string CreateQuotaAlarmRequest::getQuotaActionCode()const -{ - return quotaActionCode_; +void CreateQuotaAlarmRequest::setThreshold(float threshold) { + threshold_ = threshold; + setBodyParameter(std::string("Threshold"), std::to_string(threshold)); } -void CreateQuotaAlarmRequest::setQuotaActionCode(const std::string& quotaActionCode) -{ - quotaActionCode_ = quotaActionCode; - setBodyParameter("QuotaActionCode", quotaActionCode); +std::string CreateQuotaAlarmRequest::getQuotaActionCode() const { + return quotaActionCode_; } -std::string CreateQuotaAlarmRequest::getThresholdType()const -{ - return thresholdType_; +void CreateQuotaAlarmRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); } -void CreateQuotaAlarmRequest::setThresholdType(const std::string& thresholdType) -{ - thresholdType_ = thresholdType; - setBodyParameter("ThresholdType", thresholdType); +std::string CreateQuotaAlarmRequest::getThresholdType() const { + return thresholdType_; } -std::vector CreateQuotaAlarmRequest::getQuotaDimensions()const -{ - return quotaDimensions_; +void CreateQuotaAlarmRequest::setThresholdType(const std::string &thresholdType) { + thresholdType_ = thresholdType; + setBodyParameter(std::string("ThresholdType"), thresholdType); } -void CreateQuotaAlarmRequest::setQuotaDimensions(const std::vector& 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); - } +std::vector CreateQuotaAlarmRequest::getQuotaDimensions() const { + return quotaDimensions_; } -float CreateQuotaAlarmRequest::getThresholdPercent()const -{ - return thresholdPercent_; +void CreateQuotaAlarmRequest::setQuotaDimensions(const std::vector "aDimensions) { + quotaDimensions_ = quotaDimensions; + for(int dep1 = 0; dep1 != quotaDimensions.size(); dep1++) { + auto quotaDimensionsObj = quotaDimensions.at(dep1); + std::string quotaDimensionsObjStr = std::string("QuotaDimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(quotaDimensionsObjStr + ".Key", quotaDimensionsObj.key); + setBodyParameter(quotaDimensionsObjStr + ".Value", quotaDimensionsObj.value); + } } -void CreateQuotaAlarmRequest::setThresholdPercent(float thresholdPercent) -{ - thresholdPercent_ = thresholdPercent; - setBodyParameter("ThresholdPercent", std::to_string(thresholdPercent)); +std::string CreateQuotaAlarmRequest::getOriginalContext() const { + return originalContext_; } -std::string CreateQuotaAlarmRequest::getAlarmName()const -{ - return alarmName_; +void CreateQuotaAlarmRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void CreateQuotaAlarmRequest::setAlarmName(const std::string& alarmName) -{ - alarmName_ = alarmName; - setBodyParameter("AlarmName", alarmName); +float CreateQuotaAlarmRequest::getThresholdPercent() const { + return thresholdPercent_; +} + +void CreateQuotaAlarmRequest::setThresholdPercent(float thresholdPercent) { + thresholdPercent_ = thresholdPercent; + setBodyParameter(std::string("ThresholdPercent"), std::to_string(thresholdPercent)); +} + +std::string CreateQuotaAlarmRequest::getAlarmName() const { + return alarmName_; +} + +void CreateQuotaAlarmRequest::setAlarmName(const std::string &alarmName) { + alarmName_ = alarmName; + setBodyParameter(std::string("AlarmName"), alarmName); } diff --git a/quotas/src/model/CreateQuotaApplicationRequest.cc b/quotas/src/model/CreateQuotaApplicationRequest.cc index e4fced77e..70357a97c 100644 --- a/quotas/src/model/CreateQuotaApplicationRequest.cc +++ b/quotas/src/model/CreateQuotaApplicationRequest.cc @@ -1,122 +1,140 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::CreateQuotaApplicationRequest; - -CreateQuotaApplicationRequest::CreateQuotaApplicationRequest() : - RpcServiceRequest("quotas", "2020-05-10", "CreateQuotaApplication") -{ - setMethod(HttpRequest::Method::Post); -} - -CreateQuotaApplicationRequest::~CreateQuotaApplicationRequest() -{} - -std::string CreateQuotaApplicationRequest::getReason()const -{ - return reason_; + */ + +#include + +using AlibabaCloud::Quotas::Model::CreateQuotaApplicationRequest; + +CreateQuotaApplicationRequest::CreateQuotaApplicationRequest() + : RpcServiceRequest("quotas", "2020-05-10", "CreateQuotaApplication") { + setMethod(HttpRequest::Method::Post); } -void CreateQuotaApplicationRequest::setReason(const std::string& reason) -{ - reason_ = reason; - setBodyParameter("Reason", reason); +CreateQuotaApplicationRequest::~CreateQuotaApplicationRequest() {} + +std::string CreateQuotaApplicationRequest::getReason() const { + return reason_; } -std::string CreateQuotaApplicationRequest::getProductCode()const -{ - return productCode_; +void CreateQuotaApplicationRequest::setReason(const std::string &reason) { + reason_ = reason; + setBodyParameter(std::string("Reason"), reason); } -void CreateQuotaApplicationRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +std::string CreateQuotaApplicationRequest::getProductCode() const { + return productCode_; } -std::string CreateQuotaApplicationRequest::getQuotaActionCode()const -{ - return quotaActionCode_; +void CreateQuotaApplicationRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void CreateQuotaApplicationRequest::setQuotaActionCode(const std::string& quotaActionCode) -{ - quotaActionCode_ = quotaActionCode; - setBodyParameter("QuotaActionCode", quotaActionCode); +std::string CreateQuotaApplicationRequest::getQuotaActionCode() const { + return quotaActionCode_; } -float CreateQuotaApplicationRequest::getDesireValue()const -{ - return desireValue_; +void CreateQuotaApplicationRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); } -void CreateQuotaApplicationRequest::setDesireValue(float desireValue) -{ - desireValue_ = desireValue; - setBodyParameter("DesireValue", std::to_string(desireValue)); +float CreateQuotaApplicationRequest::getDesireValue() const { + return desireValue_; } -std::string CreateQuotaApplicationRequest::getQuotaCategory()const -{ - return quotaCategory_; +void CreateQuotaApplicationRequest::setDesireValue(float desireValue) { + desireValue_ = desireValue; + setBodyParameter(std::string("DesireValue"), std::to_string(desireValue)); } -void CreateQuotaApplicationRequest::setQuotaCategory(const std::string& quotaCategory) -{ - quotaCategory_ = quotaCategory; - setBodyParameter("QuotaCategory", quotaCategory); +std::string CreateQuotaApplicationRequest::getEffectiveTime() const { + return effectiveTime_; } -int CreateQuotaApplicationRequest::getNoticeType()const -{ - return noticeType_; +void CreateQuotaApplicationRequest::setEffectiveTime(const std::string &effectiveTime) { + effectiveTime_ = effectiveTime; + setBodyParameter(std::string("EffectiveTime"), effectiveTime); } -void CreateQuotaApplicationRequest::setNoticeType(int noticeType) -{ - noticeType_ = noticeType; - setBodyParameter("NoticeType", std::to_string(noticeType)); +std::string CreateQuotaApplicationRequest::getQuotaCategory() const { + return quotaCategory_; } -std::string CreateQuotaApplicationRequest::getAuditMode()const -{ - return auditMode_; +void CreateQuotaApplicationRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); } -void CreateQuotaApplicationRequest::setAuditMode(const std::string& auditMode) -{ - auditMode_ = auditMode; - setBodyParameter("AuditMode", auditMode); +std::string CreateQuotaApplicationRequest::getOriginalContext() const { + return originalContext_; } -std::vector CreateQuotaApplicationRequest::getDimensions()const -{ - return dimensions_; +void CreateQuotaApplicationRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void CreateQuotaApplicationRequest::setDimensions(const std::vector& 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); - } +std::string CreateQuotaApplicationRequest::getExpireTime() const { + return expireTime_; +} + +void CreateQuotaApplicationRequest::setExpireTime(const std::string &expireTime) { + expireTime_ = expireTime; + setBodyParameter(std::string("ExpireTime"), expireTime); +} + +std::string CreateQuotaApplicationRequest::getEnvLanguage() const { + return envLanguage_; +} + +void CreateQuotaApplicationRequest::setEnvLanguage(const std::string &envLanguage) { + envLanguage_ = envLanguage; + setBodyParameter(std::string("EnvLanguage"), envLanguage); +} + +int CreateQuotaApplicationRequest::getNoticeType() const { + return noticeType_; +} + +void CreateQuotaApplicationRequest::setNoticeType(int noticeType) { + noticeType_ = noticeType; + setBodyParameter(std::string("NoticeType"), std::to_string(noticeType)); +} + +std::string CreateQuotaApplicationRequest::getAuditMode() const { + return auditMode_; +} + +void CreateQuotaApplicationRequest::setAuditMode(const std::string &auditMode) { + auditMode_ = auditMode; + setBodyParameter(std::string("AuditMode"), auditMode); +} + +std::vector CreateQuotaApplicationRequest::getDimensions() const { + return dimensions_; +} + +void CreateQuotaApplicationRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } } diff --git a/quotas/src/model/CreateQuotaApplicationResult.cc b/quotas/src/model/CreateQuotaApplicationResult.cc index 4909957ca..56386ee6b 100644 --- a/quotas/src/model/CreateQuotaApplicationResult.cc +++ b/quotas/src/model/CreateQuotaApplicationResult.cc @@ -41,38 +41,38 @@ void CreateQuotaApplicationResult::parse(const std::string &payload) 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["DesireValue"].isNull()) + desireValue_ = std::stoi(value["DesireValue"].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()); + if(!value["Reason"].isNull()) + reason_ = value["Reason"].asString(); + if(!value["AuditReason"].isNull()) + auditReason_ = value["AuditReason"].asString(); + if(!value["QuotaDescription"].isNull()) + quotaDescription_ = value["QuotaDescription"].asString(); + if(!value["ProductCode"].isNull()) + productCode_ = value["ProductCode"].asString(); + if(!value["QuotaArn"].isNull()) + quotaArn_ = value["QuotaArn"].asString(); + if(!value["ApplyTime"].isNull()) + applyTime_ = value["ApplyTime"].asString(); + if(!value["ApproveValue"].isNull()) + approveValue_ = std::stof(value["ApproveValue"].asString()); + if(!value["Dimension"].isNull()) + dimension_ = value["Dimension"].asString(); + if(!value["NoticeType"].isNull()) + noticeType_ = std::stol(value["NoticeType"].asString()); + if(!value["EffectiveTime"].isNull()) + effectiveTime_ = value["EffectiveTime"].asString(); + if(!value["ExpireTime"].isNull()) + expireTime_ = value["ExpireTime"].asString(); + if(!value["QuotaUnit"].isNull()) + quotaUnit_ = value["QuotaUnit"].asString(); } @@ -91,19 +91,14 @@ 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 +std::string CreateQuotaApplicationResult::getEffectiveTime()const { - return quotaUnit_; + return effectiveTime_; } std::string CreateQuotaApplicationResult::getAuditReason()const @@ -111,6 +106,11 @@ std::string CreateQuotaApplicationResult::getAuditReason()const return auditReason_; } +std::string CreateQuotaApplicationResult::getQuotaUnit()const +{ + return quotaUnit_; +} + std::string CreateQuotaApplicationResult::getDimension()const { return dimension_; @@ -146,9 +146,9 @@ long CreateQuotaApplicationResult::getNoticeType()const return noticeType_; } -std::string CreateQuotaApplicationResult::getExpireTime()const +int CreateQuotaApplicationResult::getDesireValue()const { - return expireTime_; + return desireValue_; } std::string CreateQuotaApplicationResult::getApplicationId()const @@ -156,8 +156,8 @@ std::string CreateQuotaApplicationResult::getApplicationId()const return applicationId_; } -int CreateQuotaApplicationResult::getDesireValue()const +std::string CreateQuotaApplicationResult::getExpireTime()const { - return desireValue_; + return expireTime_; } diff --git a/quotas/src/model/CreateQuotaApplicationsForTemplateRequest.cc b/quotas/src/model/CreateQuotaApplicationsForTemplateRequest.cc new file mode 100644 index 000000000..9f0a4020f --- /dev/null +++ b/quotas/src/model/CreateQuotaApplicationsForTemplateRequest.cc @@ -0,0 +1,139 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::CreateQuotaApplicationsForTemplateRequest; + +CreateQuotaApplicationsForTemplateRequest::CreateQuotaApplicationsForTemplateRequest() + : RpcServiceRequest("quotas", "2020-05-10", "CreateQuotaApplicationsForTemplate") { + setMethod(HttpRequest::Method::Post); +} + +CreateQuotaApplicationsForTemplateRequest::~CreateQuotaApplicationsForTemplateRequest() {} + +std::string CreateQuotaApplicationsForTemplateRequest::getReason() const { + return reason_; +} + +void CreateQuotaApplicationsForTemplateRequest::setReason(const std::string &reason) { + reason_ = reason; + setBodyParameter(std::string("Reason"), reason); +} + +std::string CreateQuotaApplicationsForTemplateRequest::getProductCode() const { + return productCode_; +} + +void CreateQuotaApplicationsForTemplateRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); +} + +std::string CreateQuotaApplicationsForTemplateRequest::getQuotaActionCode() const { + return quotaActionCode_; +} + +void CreateQuotaApplicationsForTemplateRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); +} + +double CreateQuotaApplicationsForTemplateRequest::getDesireValue() const { + return desireValue_; +} + +void CreateQuotaApplicationsForTemplateRequest::setDesireValue(double desireValue) { + desireValue_ = desireValue; + setBodyParameter(std::string("DesireValue"), std::to_string(desireValue)); +} + +std::string CreateQuotaApplicationsForTemplateRequest::getEffectiveTime() const { + return effectiveTime_; +} + +void CreateQuotaApplicationsForTemplateRequest::setEffectiveTime(const std::string &effectiveTime) { + effectiveTime_ = effectiveTime; + setBodyParameter(std::string("EffectiveTime"), effectiveTime); +} + +std::vector CreateQuotaApplicationsForTemplateRequest::getAliyunUids() const { + return aliyunUids_; +} + +void CreateQuotaApplicationsForTemplateRequest::setAliyunUids(const std::vector &aliyunUids) { + aliyunUids_ = aliyunUids; +} + +std::string CreateQuotaApplicationsForTemplateRequest::getQuotaCategory() const { + return quotaCategory_; +} + +void CreateQuotaApplicationsForTemplateRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); +} + +std::string CreateQuotaApplicationsForTemplateRequest::getOriginalContext() const { + return originalContext_; +} + +void CreateQuotaApplicationsForTemplateRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string CreateQuotaApplicationsForTemplateRequest::getExpireTime() const { + return expireTime_; +} + +void CreateQuotaApplicationsForTemplateRequest::setExpireTime(const std::string &expireTime) { + expireTime_ = expireTime; + setBodyParameter(std::string("ExpireTime"), expireTime); +} + +std::string CreateQuotaApplicationsForTemplateRequest::getEnvLanguage() const { + return envLanguage_; +} + +void CreateQuotaApplicationsForTemplateRequest::setEnvLanguage(const std::string &envLanguage) { + envLanguage_ = envLanguage; + setBodyParameter(std::string("EnvLanguage"), envLanguage); +} + +int CreateQuotaApplicationsForTemplateRequest::getNoticeType() const { + return noticeType_; +} + +void CreateQuotaApplicationsForTemplateRequest::setNoticeType(int noticeType) { + noticeType_ = noticeType; + setBodyParameter(std::string("NoticeType"), std::to_string(noticeType)); +} + +std::vector CreateQuotaApplicationsForTemplateRequest::getDimensions() const { + return dimensions_; +} + +void CreateQuotaApplicationsForTemplateRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } +} + diff --git a/quotas/src/model/CreateQuotaApplicationsForTemplateResult.cc b/quotas/src/model/CreateQuotaApplicationsForTemplateResult.cc new file mode 100644 index 000000000..b4e95595e --- /dev/null +++ b/quotas/src/model/CreateQuotaApplicationsForTemplateResult.cc @@ -0,0 +1,74 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +CreateQuotaApplicationsForTemplateResult::CreateQuotaApplicationsForTemplateResult() : + ServiceResult() +{} + +CreateQuotaApplicationsForTemplateResult::CreateQuotaApplicationsForTemplateResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateQuotaApplicationsForTemplateResult::~CreateQuotaApplicationsForTemplateResult() +{} + +void CreateQuotaApplicationsForTemplateResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allFailResultsNode = value["FailResults"]["failResultsItem"]; + for (auto valueFailResultsfailResultsItem : allFailResultsNode) + { + FailResultsItem failResultsObject; + if(!valueFailResultsfailResultsItem["AliyunUid"].isNull()) + failResultsObject.aliyunUid = valueFailResultsfailResultsItem["AliyunUid"].asString(); + if(!valueFailResultsfailResultsItem["Reason"].isNull()) + failResultsObject.reason = valueFailResultsfailResultsItem["Reason"].asString(); + failResults_.push_back(failResultsObject); + } + auto allAliyunUids = value["AliyunUids"]["aliyunUids"]; + for (const auto &item : allAliyunUids) + aliyunUids_.push_back(item.asString()); + if(!value["BatchQuotaApplicationId"].isNull()) + batchQuotaApplicationId_ = value["BatchQuotaApplicationId"].asString(); + +} + +std::string CreateQuotaApplicationsForTemplateResult::getBatchQuotaApplicationId()const +{ + return batchQuotaApplicationId_; +} + +std::vector CreateQuotaApplicationsForTemplateResult::getAliyunUids()const +{ + return aliyunUids_; +} + +std::vector CreateQuotaApplicationsForTemplateResult::getFailResults()const +{ + return failResults_; +} + diff --git a/quotas/src/model/CreateTemplateQuotaItemRequest.cc b/quotas/src/model/CreateTemplateQuotaItemRequest.cc new file mode 100644 index 000000000..4e83f31f2 --- /dev/null +++ b/quotas/src/model/CreateTemplateQuotaItemRequest.cc @@ -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 + +using AlibabaCloud::Quotas::Model::CreateTemplateQuotaItemRequest; + +CreateTemplateQuotaItemRequest::CreateTemplateQuotaItemRequest() + : RpcServiceRequest("quotas", "2020-05-10", "CreateTemplateQuotaItem") { + setMethod(HttpRequest::Method::Post); +} + +CreateTemplateQuotaItemRequest::~CreateTemplateQuotaItemRequest() {} + +std::string CreateTemplateQuotaItemRequest::getProductCode() const { + return productCode_; +} + +void CreateTemplateQuotaItemRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); +} + +std::string CreateTemplateQuotaItemRequest::getQuotaActionCode() const { + return quotaActionCode_; +} + +void CreateTemplateQuotaItemRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); +} + +float CreateTemplateQuotaItemRequest::getDesireValue() const { + return desireValue_; +} + +void CreateTemplateQuotaItemRequest::setDesireValue(float desireValue) { + desireValue_ = desireValue; + setBodyParameter(std::string("DesireValue"), std::to_string(desireValue)); +} + +std::string CreateTemplateQuotaItemRequest::getEffectiveTime() const { + return effectiveTime_; +} + +void CreateTemplateQuotaItemRequest::setEffectiveTime(const std::string &effectiveTime) { + effectiveTime_ = effectiveTime; + setBodyParameter(std::string("EffectiveTime"), effectiveTime); +} + +std::string CreateTemplateQuotaItemRequest::getQuotaCategory() const { + return quotaCategory_; +} + +void CreateTemplateQuotaItemRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); +} + +std::string CreateTemplateQuotaItemRequest::getOriginalContext() const { + return originalContext_; +} + +void CreateTemplateQuotaItemRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string CreateTemplateQuotaItemRequest::getExpireTime() const { + return expireTime_; +} + +void CreateTemplateQuotaItemRequest::setExpireTime(const std::string &expireTime) { + expireTime_ = expireTime; + setBodyParameter(std::string("ExpireTime"), expireTime); +} + +std::string CreateTemplateQuotaItemRequest::getEnvLanguage() const { + return envLanguage_; +} + +void CreateTemplateQuotaItemRequest::setEnvLanguage(const std::string &envLanguage) { + envLanguage_ = envLanguage; + setBodyParameter(std::string("EnvLanguage"), envLanguage); +} + +long CreateTemplateQuotaItemRequest::getNoticeType() const { + return noticeType_; +} + +void CreateTemplateQuotaItemRequest::setNoticeType(long noticeType) { + noticeType_ = noticeType; + setBodyParameter(std::string("NoticeType"), std::to_string(noticeType)); +} + +std::vector CreateTemplateQuotaItemRequest::getDimensions() const { + return dimensions_; +} + +void CreateTemplateQuotaItemRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } +} + diff --git a/quotas/src/model/CreateTemplateQuotaItemResult.cc b/quotas/src/model/CreateTemplateQuotaItemResult.cc new file mode 100644 index 000000000..b6ae79b8b --- /dev/null +++ b/quotas/src/model/CreateTemplateQuotaItemResult.cc @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +CreateTemplateQuotaItemResult::CreateTemplateQuotaItemResult() : + ServiceResult() +{} + +CreateTemplateQuotaItemResult::CreateTemplateQuotaItemResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateTemplateQuotaItemResult::~CreateTemplateQuotaItemResult() +{} + +void CreateTemplateQuotaItemResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Id"].isNull()) + id_ = value["Id"].asString(); + +} + +std::string CreateTemplateQuotaItemResult::getId()const +{ + return id_; +} + diff --git a/quotas/src/model/DeleteQuotaAlarmRequest.cc b/quotas/src/model/DeleteQuotaAlarmRequest.cc index 0055ee6e2..ede468e26 100644 --- a/quotas/src/model/DeleteQuotaAlarmRequest.cc +++ b/quotas/src/model/DeleteQuotaAlarmRequest.cc @@ -1,40 +1,45 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::DeleteQuotaAlarmRequest; - -DeleteQuotaAlarmRequest::DeleteQuotaAlarmRequest() : - RpcServiceRequest("quotas", "2020-05-10", "DeleteQuotaAlarm") -{ - setMethod(HttpRequest::Method::Post); -} - -DeleteQuotaAlarmRequest::~DeleteQuotaAlarmRequest() -{} - -std::string DeleteQuotaAlarmRequest::getAlarmId()const -{ - return alarmId_; + */ + +#include + +using AlibabaCloud::Quotas::Model::DeleteQuotaAlarmRequest; + +DeleteQuotaAlarmRequest::DeleteQuotaAlarmRequest() + : RpcServiceRequest("quotas", "2020-05-10", "DeleteQuotaAlarm") { + setMethod(HttpRequest::Method::Post); } -void DeleteQuotaAlarmRequest::setAlarmId(const std::string& alarmId) -{ - alarmId_ = alarmId; - setBodyParameter("AlarmId", alarmId); +DeleteQuotaAlarmRequest::~DeleteQuotaAlarmRequest() {} + +std::string DeleteQuotaAlarmRequest::getOriginalContext() const { + return originalContext_; +} + +void DeleteQuotaAlarmRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string DeleteQuotaAlarmRequest::getAlarmId() const { + return alarmId_; +} + +void DeleteQuotaAlarmRequest::setAlarmId(const std::string &alarmId) { + alarmId_ = alarmId; + setBodyParameter(std::string("AlarmId"), alarmId); } diff --git a/quotas/src/model/DeleteTemplateQuotaItemRequest.cc b/quotas/src/model/DeleteTemplateQuotaItemRequest.cc new file mode 100644 index 000000000..f50fb8d31 --- /dev/null +++ b/quotas/src/model/DeleteTemplateQuotaItemRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::DeleteTemplateQuotaItemRequest; + +DeleteTemplateQuotaItemRequest::DeleteTemplateQuotaItemRequest() + : RpcServiceRequest("quotas", "2020-05-10", "DeleteTemplateQuotaItem") { + setMethod(HttpRequest::Method::Post); +} + +DeleteTemplateQuotaItemRequest::~DeleteTemplateQuotaItemRequest() {} + +std::string DeleteTemplateQuotaItemRequest::getOriginalContext() const { + return originalContext_; +} + +void DeleteTemplateQuotaItemRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string DeleteTemplateQuotaItemRequest::getId() const { + return id_; +} + +void DeleteTemplateQuotaItemRequest::setId(const std::string &id) { + id_ = id; + setBodyParameter(std::string("Id"), id); +} + diff --git a/quotas/src/model/DeleteTemplateQuotaItemResult.cc b/quotas/src/model/DeleteTemplateQuotaItemResult.cc new file mode 100644 index 000000000..6a5e135ff --- /dev/null +++ b/quotas/src/model/DeleteTemplateQuotaItemResult.cc @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +DeleteTemplateQuotaItemResult::DeleteTemplateQuotaItemResult() : + ServiceResult() +{} + +DeleteTemplateQuotaItemResult::DeleteTemplateQuotaItemResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteTemplateQuotaItemResult::~DeleteTemplateQuotaItemResult() +{} + +void DeleteTemplateQuotaItemResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Id"].isNull()) + id_ = value["Id"].asString(); + +} + +std::string DeleteTemplateQuotaItemResult::getId()const +{ + return id_; +} + diff --git a/quotas/src/model/GetProductQuotaDimensionRequest.cc b/quotas/src/model/GetProductQuotaDimensionRequest.cc index 1030cd089..bdbcc0cb3 100644 --- a/quotas/src/model/GetProductQuotaDimensionRequest.cc +++ b/quotas/src/model/GetProductQuotaDimensionRequest.cc @@ -1,67 +1,68 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -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_; + */ + +#include + +using AlibabaCloud::Quotas::Model::GetProductQuotaDimensionRequest; + +GetProductQuotaDimensionRequest::GetProductQuotaDimensionRequest() + : RpcServiceRequest("quotas", "2020-05-10", "GetProductQuotaDimension") { + setMethod(HttpRequest::Method::Post); } -void GetProductQuotaDimensionRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +GetProductQuotaDimensionRequest::~GetProductQuotaDimensionRequest() {} + +std::string GetProductQuotaDimensionRequest::getOriginalContext() const { + return originalContext_; } -std::vector GetProductQuotaDimensionRequest::getDependentDimensions()const -{ - return dependentDimensions_; +void GetProductQuotaDimensionRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void GetProductQuotaDimensionRequest::setDependentDimensions(const std::vector& 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::getProductCode() const { + return productCode_; } -std::string GetProductQuotaDimensionRequest::getDimensionKey()const -{ - return dimensionKey_; +void GetProductQuotaDimensionRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void GetProductQuotaDimensionRequest::setDimensionKey(const std::string& dimensionKey) -{ - dimensionKey_ = dimensionKey; - setBodyParameter("DimensionKey", dimensionKey); +std::vector GetProductQuotaDimensionRequest::getDependentDimensions() const { + return dependentDimensions_; +} + +void GetProductQuotaDimensionRequest::setDependentDimensions(const std::vector &dependentDimensions) { + dependentDimensions_ = dependentDimensions; + for(int dep1 = 0; dep1 != dependentDimensions.size(); dep1++) { + auto dependentDimensionsObj = dependentDimensions.at(dep1); + std::string dependentDimensionsObjStr = std::string("DependentDimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dependentDimensionsObjStr + ".Key", dependentDimensionsObj.key); + setBodyParameter(dependentDimensionsObjStr + ".Value", dependentDimensionsObj.value); + } +} + +std::string GetProductQuotaDimensionRequest::getDimensionKey() const { + return dimensionKey_; +} + +void GetProductQuotaDimensionRequest::setDimensionKey(const std::string &dimensionKey) { + dimensionKey_ = dimensionKey; + setBodyParameter(std::string("DimensionKey"), dimensionKey); } diff --git a/quotas/src/model/GetProductQuotaDimensionResult.cc b/quotas/src/model/GetProductQuotaDimensionResult.cc index 9fc1270b1..5282860ee 100644 --- a/quotas/src/model/GetProductQuotaDimensionResult.cc +++ b/quotas/src/model/GetProductQuotaDimensionResult.cc @@ -48,18 +48,18 @@ void GetProductQuotaDimensionResult::parse(const std::string &payload) 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(); + if(!quotaDimensionNodeDimensionValueDetailDimensionValueDetailItem["Value"].isNull()) + dimensionValueDetailItemObject.value = quotaDimensionNodeDimensionValueDetailDimensionValueDetailItem["Value"].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()); + auto allDimensionValues = quotaDimensionNode["DimensionValues"]["DimensionValues"]; + for (auto value : allDimensionValues) + quotaDimension_.dimensionValues.push_back(value.asString()); } diff --git a/quotas/src/model/GetProductQuotaRequest.cc b/quotas/src/model/GetProductQuotaRequest.cc index d6948fb2f..6c9999489 100644 --- a/quotas/src/model/GetProductQuotaRequest.cc +++ b/quotas/src/model/GetProductQuotaRequest.cc @@ -1,67 +1,68 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -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_; + */ + +#include + +using AlibabaCloud::Quotas::Model::GetProductQuotaRequest; + +GetProductQuotaRequest::GetProductQuotaRequest() + : RpcServiceRequest("quotas", "2020-05-10", "GetProductQuota") { + setMethod(HttpRequest::Method::Post); } -void GetProductQuotaRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +GetProductQuotaRequest::~GetProductQuotaRequest() {} + +std::string GetProductQuotaRequest::getProductCode() const { + return productCode_; } -std::string GetProductQuotaRequest::getQuotaActionCode()const -{ - return quotaActionCode_; +void GetProductQuotaRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void GetProductQuotaRequest::setQuotaActionCode(const std::string& quotaActionCode) -{ - quotaActionCode_ = quotaActionCode; - setBodyParameter("QuotaActionCode", quotaActionCode); +std::string GetProductQuotaRequest::getQuotaActionCode() const { + return quotaActionCode_; } -std::vector GetProductQuotaRequest::getDimensions()const -{ - return dimensions_; +void GetProductQuotaRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); } -void GetProductQuotaRequest::setDimensions(const std::vector& 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); - } +std::string GetProductQuotaRequest::getOriginalContext() const { + return originalContext_; +} + +void GetProductQuotaRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::vector GetProductQuotaRequest::getDimensions() const { + return dimensions_; +} + +void GetProductQuotaRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } } diff --git a/quotas/src/model/GetProductQuotaResult.cc b/quotas/src/model/GetProductQuotaResult.cc index 87c96c04c..90eb80f9c 100644 --- a/quotas/src/model/GetProductQuotaResult.cc +++ b/quotas/src/model/GetProductQuotaResult.cc @@ -40,46 +40,56 @@ void GetProductQuotaResult::parse(const std::string &payload) 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["QuotaUnit"].isNull()) + quota_.quotaUnit = quotaNode["QuotaUnit"].asString(); + if(!quotaNode["QuotaActionCode"].isNull()) + quota_.quotaActionCode = quotaNode["QuotaActionCode"].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["QuotaDescription"].isNull()) + quota_.quotaDescription = quotaNode["QuotaDescription"].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(); + if(!quotaNode["Dimensions"].isNull()) + quota_.dimensions = quotaNode["Dimensions"].asString(); + if(!quotaNode["Adjustable"].isNull()) + quota_.adjustable = quotaNode["Adjustable"].asString() == "true"; + if(!quotaNode["QuotaName"].isNull()) + quota_.quotaName = quotaNode["QuotaName"].asString(); + if(!quotaNode["UnadjustableDetail"].isNull()) + quota_.unadjustableDetail = quotaNode["UnadjustableDetail"].asString(); + if(!quotaNode["Consumable"].isNull()) + quota_.consumable = quotaNode["Consumable"].asString() == "true"; + if(!quotaNode["TotalQuota"].isNull()) + quota_.totalQuota = std::stof(quotaNode["TotalQuota"].asString()); + if(!quotaNode["ProductCode"].isNull()) + quota_.productCode = quotaNode["ProductCode"].asString(); + if(!quotaNode["EffectiveTime"].isNull()) + quota_.effectiveTime = quotaNode["EffectiveTime"].asString(); + if(!quotaNode["ExpireTime"].isNull()) + quota_.expireTime = quotaNode["ExpireTime"].asString(); + if(!quotaNode["QuotaCategory"].isNull()) + quota_.quotaCategory = quotaNode["QuotaCategory"].asString(); + if(!quotaNode["ApplyReasonTips"].isNull()) + quota_.applyReasonTips = quotaNode["ApplyReasonTips"].asString(); + if(!quotaNode["GlobalQuota"].isNull()) + quota_.globalQuota = quotaNode["GlobalQuota"].asString() == "true"; 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(); + if(!quotaNodeQuotaItemsQuotaItemsItem["Usage"].isNull()) + quotaItemsItemObject.usage = quotaNodeQuotaItemsQuotaItemsItem["Usage"].asString(); quota_.quotaItems.push_back(quotaItemsItemObject); } auto periodNode = quotaNode["Period"]; @@ -87,9 +97,19 @@ void GetProductQuotaResult::parse(const std::string &payload) quota_.period.periodValue = std::stoi(periodNode["PeriodValue"].asString()); if(!periodNode["PeriodUnit"].isNull()) quota_.period.periodUnit = periodNode["PeriodUnit"].asString(); + auto usageMetricNode = quotaNode["UsageMetric"]; + if(!usageMetricNode["MetricNamespace"].isNull()) + quota_.usageMetric.metricNamespace = usageMetricNode["MetricNamespace"].asString(); + if(!usageMetricNode["MetricName"].isNull()) + quota_.usageMetric.metricName = usageMetricNode["MetricName"].asString(); + if(!usageMetricNode["MetricDimensions"].isNull()) + quota_.usageMetric.metricDimensions = usageMetricNode["MetricDimensions"].asString(); auto allApplicableRange = quotaNode["ApplicableRange"]["ApplicableRange"]; for (auto value : allApplicableRange) quota_.applicableRange.push_back(value.asString()); + auto allSupportedRange = quotaNode["SupportedRange"]["SupportedRange"]; + for (auto value : allSupportedRange) + quota_.supportedRange.push_back(value.asString()); } diff --git a/quotas/src/model/GetQuotaAlarmRequest.cc b/quotas/src/model/GetQuotaAlarmRequest.cc index d6821913f..3e8648d83 100644 --- a/quotas/src/model/GetQuotaAlarmRequest.cc +++ b/quotas/src/model/GetQuotaAlarmRequest.cc @@ -1,40 +1,45 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::GetQuotaAlarmRequest; - -GetQuotaAlarmRequest::GetQuotaAlarmRequest() : - RpcServiceRequest("quotas", "2020-05-10", "GetQuotaAlarm") -{ - setMethod(HttpRequest::Method::Post); -} - -GetQuotaAlarmRequest::~GetQuotaAlarmRequest() -{} - -std::string GetQuotaAlarmRequest::getAlarmId()const -{ - return alarmId_; + */ + +#include + +using AlibabaCloud::Quotas::Model::GetQuotaAlarmRequest; + +GetQuotaAlarmRequest::GetQuotaAlarmRequest() + : RpcServiceRequest("quotas", "2020-05-10", "GetQuotaAlarm") { + setMethod(HttpRequest::Method::Post); } -void GetQuotaAlarmRequest::setAlarmId(const std::string& alarmId) -{ - alarmId_ = alarmId; - setBodyParameter("AlarmId", alarmId); +GetQuotaAlarmRequest::~GetQuotaAlarmRequest() {} + +std::string GetQuotaAlarmRequest::getOriginalContext() const { + return originalContext_; +} + +void GetQuotaAlarmRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string GetQuotaAlarmRequest::getAlarmId() const { + return alarmId_; +} + +void GetQuotaAlarmRequest::setAlarmId(const std::string &alarmId) { + alarmId_ = alarmId; + setBodyParameter(std::string("AlarmId"), alarmId); } diff --git a/quotas/src/model/GetQuotaAlarmResult.cc b/quotas/src/model/GetQuotaAlarmResult.cc index a31294a50..75ce73130 100644 --- a/quotas/src/model/GetQuotaAlarmResult.cc +++ b/quotas/src/model/GetQuotaAlarmResult.cc @@ -40,30 +40,32 @@ void GetQuotaAlarmResult::parse(const std::string &payload) 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(); + if(!quotaAlarmNode["QuotaDimension"].isNull()) + quotaAlarm_.quotaDimension = quotaAlarmNode["QuotaDimension"].asString(); + if(!quotaAlarmNode["CreateTime"].isNull()) + quotaAlarm_.createTime = quotaAlarmNode["CreateTime"].asString(); + if(!quotaAlarmNode["QuotaActionCode"].isNull()) + quotaAlarm_.quotaActionCode = quotaAlarmNode["QuotaActionCode"].asString(); + if(!quotaAlarmNode["AlarmName"].isNull()) + quotaAlarm_.alarmName = quotaAlarmNode["AlarmName"].asString(); + if(!quotaAlarmNode["NotifyTarget"].isNull()) + quotaAlarm_.notifyTarget = quotaAlarmNode["NotifyTarget"].asString(); + if(!quotaAlarmNode["QuotaUsage"].isNull()) + quotaAlarm_.quotaUsage = std::stof(quotaAlarmNode["QuotaUsage"].asString()); + if(!quotaAlarmNode["QuotaValue"].isNull()) + quotaAlarm_.quotaValue = std::stof(quotaAlarmNode["QuotaValue"].asString()); + if(!quotaAlarmNode["AlarmId"].isNull()) + quotaAlarm_.alarmId = quotaAlarmNode["AlarmId"].asString(); + if(!quotaAlarmNode["Threshold"].isNull()) + quotaAlarm_.threshold = std::stof(quotaAlarmNode["Threshold"].asString()); + if(!quotaAlarmNode["ProductCode"].isNull()) + quotaAlarm_.productCode = quotaAlarmNode["ProductCode"].asString(); + if(!quotaAlarmNode["Webhook"].isNull()) + quotaAlarm_.webhook = quotaAlarmNode["Webhook"].asString(); auto allNotifyChannels = quotaAlarmNode["NotifyChannels"]["NotifyChannels"]; for (auto value : allNotifyChannels) quotaAlarm_.notifyChannels.push_back(value.asString()); diff --git a/quotas/src/model/GetQuotaApplicationApprovalRequest.cc b/quotas/src/model/GetQuotaApplicationApprovalRequest.cc new file mode 100644 index 000000000..0e6ebd426 --- /dev/null +++ b/quotas/src/model/GetQuotaApplicationApprovalRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::GetQuotaApplicationApprovalRequest; + +GetQuotaApplicationApprovalRequest::GetQuotaApplicationApprovalRequest() + : RpcServiceRequest("quotas", "2020-05-10", "GetQuotaApplicationApproval") { + setMethod(HttpRequest::Method::Post); +} + +GetQuotaApplicationApprovalRequest::~GetQuotaApplicationApprovalRequest() {} + +std::string GetQuotaApplicationApprovalRequest::getOriginalContext() const { + return originalContext_; +} + +void GetQuotaApplicationApprovalRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string GetQuotaApplicationApprovalRequest::getApplicationId() const { + return applicationId_; +} + +void GetQuotaApplicationApprovalRequest::setApplicationId(const std::string &applicationId) { + applicationId_ = applicationId; + setBodyParameter(std::string("ApplicationId"), applicationId); +} + diff --git a/quotas/src/model/GetQuotaApplicationApprovalResult.cc b/quotas/src/model/GetQuotaApplicationApprovalResult.cc new file mode 100644 index 000000000..567177101 --- /dev/null +++ b/quotas/src/model/GetQuotaApplicationApprovalResult.cc @@ -0,0 +1,115 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +GetQuotaApplicationApprovalResult::GetQuotaApplicationApprovalResult() : + ServiceResult() +{} + +GetQuotaApplicationApprovalResult::GetQuotaApplicationApprovalResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetQuotaApplicationApprovalResult::~GetQuotaApplicationApprovalResult() +{} + +void GetQuotaApplicationApprovalResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto moduleNode = value["Module"]; + if(!moduleNode["ApprovalHours"].isNull()) + module_.approvalHours = std::stoi(moduleNode["ApprovalHours"].asString()); + if(!moduleNode["SupportReminder"].isNull()) + module_.supportReminder = moduleNode["SupportReminder"].asString() == "true"; + if(!moduleNode["UnsupportReminderReason"].isNull()) + module_.unsupportReminderReason = moduleNode["UnsupportReminderReason"].asString(); + if(!moduleNode["ReminderIntervalHours"].isNull()) + module_.reminderIntervalHours = std::stoi(moduleNode["ReminderIntervalHours"].asString()); + auto allErrorArgs = value["ErrorArgs"]["ErrorArg"]; + for (const auto &item : allErrorArgs) + errorArgs_.push_back(item.asString()); + if(!value["HttpStatusCode"].isNull()) + httpStatusCode_ = std::stoi(value["HttpStatusCode"].asString()); + if(!value["DynamicCode"].isNull()) + dynamicCode_ = value["DynamicCode"].asString(); + if(!value["DynamicMessage"].isNull()) + dynamicMessage_ = value["DynamicMessage"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["ErrorCode"].isNull()) + errorCode_ = value["ErrorCode"].asString(); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["AllowRetry"].isNull()) + allowRetry_ = value["AllowRetry"].asString() == "true"; + +} + +bool GetQuotaApplicationApprovalResult::getAllowRetry()const +{ + return allowRetry_; +} + +std::vector GetQuotaApplicationApprovalResult::getErrorArgs()const +{ + return errorArgs_; +} + +int GetQuotaApplicationApprovalResult::getHttpStatusCode()const +{ + return httpStatusCode_; +} + +std::string GetQuotaApplicationApprovalResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string GetQuotaApplicationApprovalResult::getDynamicCode()const +{ + return dynamicCode_; +} + +std::string GetQuotaApplicationApprovalResult::getDynamicMessage()const +{ + return dynamicMessage_; +} + +std::string GetQuotaApplicationApprovalResult::getErrorCode()const +{ + return errorCode_; +} + +GetQuotaApplicationApprovalResult::Module GetQuotaApplicationApprovalResult::getModule()const +{ + return module_; +} + +bool GetQuotaApplicationApprovalResult::getSuccess()const +{ + return success_; +} + diff --git a/quotas/src/model/GetQuotaApplicationRequest.cc b/quotas/src/model/GetQuotaApplicationRequest.cc index f4336e749..f5924e600 100644 --- a/quotas/src/model/GetQuotaApplicationRequest.cc +++ b/quotas/src/model/GetQuotaApplicationRequest.cc @@ -1,40 +1,45 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::GetQuotaApplicationRequest; - -GetQuotaApplicationRequest::GetQuotaApplicationRequest() : - RpcServiceRequest("quotas", "2020-05-10", "GetQuotaApplication") -{ - setMethod(HttpRequest::Method::Post); -} - -GetQuotaApplicationRequest::~GetQuotaApplicationRequest() -{} - -std::string GetQuotaApplicationRequest::getApplicationId()const -{ - return applicationId_; + */ + +#include + +using AlibabaCloud::Quotas::Model::GetQuotaApplicationRequest; + +GetQuotaApplicationRequest::GetQuotaApplicationRequest() + : RpcServiceRequest("quotas", "2020-05-10", "GetQuotaApplication") { + setMethod(HttpRequest::Method::Post); } -void GetQuotaApplicationRequest::setApplicationId(const std::string& applicationId) -{ - applicationId_ = applicationId; - setBodyParameter("ApplicationId", applicationId); +GetQuotaApplicationRequest::~GetQuotaApplicationRequest() {} + +std::string GetQuotaApplicationRequest::getOriginalContext() const { + return originalContext_; +} + +void GetQuotaApplicationRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string GetQuotaApplicationRequest::getApplicationId() const { + return applicationId_; +} + +void GetQuotaApplicationRequest::setApplicationId(const std::string &applicationId) { + applicationId_ = applicationId; + setBodyParameter(std::string("ApplicationId"), applicationId); } diff --git a/quotas/src/model/GetQuotaApplicationResult.cc b/quotas/src/model/GetQuotaApplicationResult.cc index 4ff254151..3443e54f5 100644 --- a/quotas/src/model/GetQuotaApplicationResult.cc +++ b/quotas/src/model/GetQuotaApplicationResult.cc @@ -42,38 +42,38 @@ void GetQuotaApplicationResult::parse(const std::string &payload) 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["DesireValue"].isNull()) + quotaApplication_.desireValue = std::stoi(quotaApplicationNode["DesireValue"].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()); + if(!quotaApplicationNode["Reason"].isNull()) + quotaApplication_.reason = quotaApplicationNode["Reason"].asString(); + if(!quotaApplicationNode["AuditReason"].isNull()) + quotaApplication_.auditReason = quotaApplicationNode["AuditReason"].asString(); + if(!quotaApplicationNode["QuotaDescription"].isNull()) + quotaApplication_.quotaDescription = quotaApplicationNode["QuotaDescription"].asString(); + if(!quotaApplicationNode["ProductCode"].isNull()) + quotaApplication_.productCode = quotaApplicationNode["ProductCode"].asString(); + if(!quotaApplicationNode["QuotaArn"].isNull()) + quotaApplication_.quotaArn = quotaApplicationNode["QuotaArn"].asString(); + if(!quotaApplicationNode["ApplyTime"].isNull()) + quotaApplication_.applyTime = quotaApplicationNode["ApplyTime"].asString(); + if(!quotaApplicationNode["ApproveValue"].isNull()) + quotaApplication_.approveValue = std::stof(quotaApplicationNode["ApproveValue"].asString()); + if(!quotaApplicationNode["Dimension"].isNull()) + quotaApplication_.dimension = quotaApplicationNode["Dimension"].asString(); + if(!quotaApplicationNode["NoticeType"].isNull()) + quotaApplication_.noticeType = std::stol(quotaApplicationNode["NoticeType"].asString()); + if(!quotaApplicationNode["EffectiveTime"].isNull()) + quotaApplication_.effectiveTime = quotaApplicationNode["EffectiveTime"].asString(); + if(!quotaApplicationNode["ExpireTime"].isNull()) + quotaApplication_.expireTime = quotaApplicationNode["ExpireTime"].asString(); + if(!quotaApplicationNode["QuotaUnit"].isNull()) + quotaApplication_.quotaUnit = quotaApplicationNode["QuotaUnit"].asString(); } diff --git a/quotas/src/model/GetQuotaTemplateServiceStatusRequest.cc b/quotas/src/model/GetQuotaTemplateServiceStatusRequest.cc new file mode 100644 index 000000000..84902f2e8 --- /dev/null +++ b/quotas/src/model/GetQuotaTemplateServiceStatusRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::GetQuotaTemplateServiceStatusRequest; + +GetQuotaTemplateServiceStatusRequest::GetQuotaTemplateServiceStatusRequest() + : RpcServiceRequest("quotas", "2020-05-10", "GetQuotaTemplateServiceStatus") { + setMethod(HttpRequest::Method::Post); +} + +GetQuotaTemplateServiceStatusRequest::~GetQuotaTemplateServiceStatusRequest() {} + +std::string GetQuotaTemplateServiceStatusRequest::getOriginalContext() const { + return originalContext_; +} + +void GetQuotaTemplateServiceStatusRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string GetQuotaTemplateServiceStatusRequest::getResourceDirectoryId() const { + return resourceDirectoryId_; +} + +void GetQuotaTemplateServiceStatusRequest::setResourceDirectoryId(const std::string &resourceDirectoryId) { + resourceDirectoryId_ = resourceDirectoryId; + setBodyParameter(std::string("ResourceDirectoryId"), resourceDirectoryId); +} + diff --git a/quotas/src/model/GetQuotaTemplateServiceStatusResult.cc b/quotas/src/model/GetQuotaTemplateServiceStatusResult.cc new file mode 100644 index 000000000..74e9bdef1 --- /dev/null +++ b/quotas/src/model/GetQuotaTemplateServiceStatusResult.cc @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +GetQuotaTemplateServiceStatusResult::GetQuotaTemplateServiceStatusResult() : + ServiceResult() +{} + +GetQuotaTemplateServiceStatusResult::GetQuotaTemplateServiceStatusResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetQuotaTemplateServiceStatusResult::~GetQuotaTemplateServiceStatusResult() +{} + +void GetQuotaTemplateServiceStatusResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto templateServiceStatusNode = value["TemplateServiceStatus"]; + if(!templateServiceStatusNode["ServiceStatus"].isNull()) + templateServiceStatus_.serviceStatus = std::stoi(templateServiceStatusNode["ServiceStatus"].asString()); + if(!templateServiceStatusNode["ResourceDirectoryId"].isNull()) + templateServiceStatus_.resourceDirectoryId = templateServiceStatusNode["ResourceDirectoryId"].asString(); + +} + +GetQuotaTemplateServiceStatusResult::TemplateServiceStatus GetQuotaTemplateServiceStatusResult::getTemplateServiceStatus()const +{ + return templateServiceStatus_; +} + diff --git a/quotas/src/model/ListAlarmHistoriesRequest.cc b/quotas/src/model/ListAlarmHistoriesRequest.cc index b19487ccb..6107a7d70 100644 --- a/quotas/src/model/ListAlarmHistoriesRequest.cc +++ b/quotas/src/model/ListAlarmHistoriesRequest.cc @@ -1,95 +1,99 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListAlarmHistoriesRequest; - -ListAlarmHistoriesRequest::ListAlarmHistoriesRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListAlarmHistories") -{ - setMethod(HttpRequest::Method::Post); -} - -ListAlarmHistoriesRequest::~ListAlarmHistoriesRequest() -{} - -std::string ListAlarmHistoriesRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListAlarmHistoriesRequest; + +ListAlarmHistoriesRequest::ListAlarmHistoriesRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListAlarmHistories") { + setMethod(HttpRequest::Method::Post); } -void ListAlarmHistoriesRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +ListAlarmHistoriesRequest::~ListAlarmHistoriesRequest() {} + +std::string ListAlarmHistoriesRequest::getProductCode() const { + return productCode_; } -long ListAlarmHistoriesRequest::getStartTime()const -{ - return startTime_; +void ListAlarmHistoriesRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void ListAlarmHistoriesRequest::setStartTime(long startTime) -{ - startTime_ = startTime; - setBodyParameter("StartTime", std::to_string(startTime)); +long ListAlarmHistoriesRequest::getStartTime() const { + return startTime_; } -std::string ListAlarmHistoriesRequest::getNextToken()const -{ - return nextToken_; +void ListAlarmHistoriesRequest::setStartTime(long startTime) { + startTime_ = startTime; + setBodyParameter(std::string("StartTime"), std::to_string(startTime)); } -void ListAlarmHistoriesRequest::setNextToken(const std::string& nextToken) -{ - nextToken_ = nextToken; - setBodyParameter("NextToken", nextToken); +std::string ListAlarmHistoriesRequest::getNextToken() const { + return nextToken_; } -std::string ListAlarmHistoriesRequest::getKeyword()const -{ - return keyword_; +void ListAlarmHistoriesRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); } -void ListAlarmHistoriesRequest::setKeyword(const std::string& keyword) -{ - keyword_ = keyword; - setBodyParameter("Keyword", keyword); +std::string ListAlarmHistoriesRequest::getKeyword() const { + return keyword_; } -long ListAlarmHistoriesRequest::getEndTime()const -{ - return endTime_; +void ListAlarmHistoriesRequest::setKeyword(const std::string &keyword) { + keyword_ = keyword; + setBodyParameter(std::string("Keyword"), keyword); } -void ListAlarmHistoriesRequest::setEndTime(long endTime) -{ - endTime_ = endTime; - setBodyParameter("EndTime", std::to_string(endTime)); +std::string ListAlarmHistoriesRequest::getOriginalContext() const { + return originalContext_; } -int ListAlarmHistoriesRequest::getMaxResults()const -{ - return maxResults_; +void ListAlarmHistoriesRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void ListAlarmHistoriesRequest::setMaxResults(int maxResults) -{ - maxResults_ = maxResults; - setBodyParameter("MaxResults", std::to_string(maxResults)); +long ListAlarmHistoriesRequest::getEndTime() const { + return endTime_; +} + +void ListAlarmHistoriesRequest::setEndTime(long endTime) { + endTime_ = endTime; + setBodyParameter(std::string("EndTime"), std::to_string(endTime)); +} + +std::string ListAlarmHistoriesRequest::getAlarmId() const { + return alarmId_; +} + +void ListAlarmHistoriesRequest::setAlarmId(const std::string &alarmId) { + alarmId_ = alarmId; + setBodyParameter(std::string("AlarmId"), alarmId); +} + +int ListAlarmHistoriesRequest::getMaxResults() const { + return maxResults_; +} + +void ListAlarmHistoriesRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); } diff --git a/quotas/src/model/ListAlarmHistoriesResult.cc b/quotas/src/model/ListAlarmHistoriesResult.cc index 2d9a0a604..9d1593e14 100644 --- a/quotas/src/model/ListAlarmHistoriesResult.cc +++ b/quotas/src/model/ListAlarmHistoriesResult.cc @@ -43,33 +43,33 @@ void ListAlarmHistoriesResult::parse(const std::string &payload) 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["ThresholdPercent"].isNull()) + alarmHistoriesObject.thresholdPercent = std::stof(valueAlarmHistoriesAlarmHistory["ThresholdPercent"].asString()); if(!valueAlarmHistoriesAlarmHistory["CreateTime"].isNull()) alarmHistoriesObject.createTime = valueAlarmHistoriesAlarmHistory["CreateTime"].asString(); + if(!valueAlarmHistoriesAlarmHistory["QuotaActionCode"].isNull()) + alarmHistoriesObject.quotaActionCode = valueAlarmHistoriesAlarmHistory["QuotaActionCode"].asString(); + if(!valueAlarmHistoriesAlarmHistory["AlarmName"].isNull()) + alarmHistoriesObject.alarmName = valueAlarmHistoriesAlarmHistory["AlarmName"].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(); + if(!valueAlarmHistoriesAlarmHistory["ProductCode"].isNull()) + alarmHistoriesObject.productCode = valueAlarmHistoriesAlarmHistory["ProductCode"].asString(); auto allNotifyChannels = value["NotifyChannels"]["NotifyChannels"]; for (auto value : allNotifyChannels) alarmHistoriesObject.notifyChannels.push_back(value.asString()); alarmHistories_.push_back(alarmHistoriesObject); } + 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()); - if(!value["TotalCount"].isNull()) - totalCount_ = std::stoi(value["TotalCount"].asString()); } diff --git a/quotas/src/model/ListDependentQuotasRequest.cc b/quotas/src/model/ListDependentQuotasRequest.cc index 5c19230f7..e70c5bb23 100644 --- a/quotas/src/model/ListDependentQuotasRequest.cc +++ b/quotas/src/model/ListDependentQuotasRequest.cc @@ -1,51 +1,54 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListDependentQuotasRequest; - -ListDependentQuotasRequest::ListDependentQuotasRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListDependentQuotas") -{ - setMethod(HttpRequest::Method::Post); -} - -ListDependentQuotasRequest::~ListDependentQuotasRequest() -{} - -std::string ListDependentQuotasRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListDependentQuotasRequest; + +ListDependentQuotasRequest::ListDependentQuotasRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListDependentQuotas") { + setMethod(HttpRequest::Method::Post); } -void ListDependentQuotasRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +ListDependentQuotasRequest::~ListDependentQuotasRequest() {} + +std::string ListDependentQuotasRequest::getOriginalContext() const { + return originalContext_; } -std::string ListDependentQuotasRequest::getQuotaActionCode()const -{ - return quotaActionCode_; +void ListDependentQuotasRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void ListDependentQuotasRequest::setQuotaActionCode(const std::string& quotaActionCode) -{ - quotaActionCode_ = quotaActionCode; - setBodyParameter("QuotaActionCode", quotaActionCode); +std::string ListDependentQuotasRequest::getProductCode() const { + return productCode_; +} + +void ListDependentQuotasRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); +} + +std::string ListDependentQuotasRequest::getQuotaActionCode() const { + return quotaActionCode_; +} + +void ListDependentQuotasRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); } diff --git a/quotas/src/model/ListDependentQuotasResult.cc b/quotas/src/model/ListDependentQuotasResult.cc index e90bcc0dc..f44d45393 100644 --- a/quotas/src/model/ListDependentQuotasResult.cc +++ b/quotas/src/model/ListDependentQuotasResult.cc @@ -55,12 +55,12 @@ void ListDependentQuotasResult::parse(const std::string &payload) 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()); + auto allDimensionValues = value["DimensionValues"]["DimensionValues"]; + for (auto value : allDimensionValues) + dimensionsObject.dimensionValues.push_back(value.asString()); quotasObject.dimensions.push_back(dimensionsObject); } quotas_.push_back(quotasObject); diff --git a/quotas/src/model/ListProductDimensionGroupsRequest.cc b/quotas/src/model/ListProductDimensionGroupsRequest.cc index 72e793f25..ee8aa2b02 100644 --- a/quotas/src/model/ListProductDimensionGroupsRequest.cc +++ b/quotas/src/model/ListProductDimensionGroupsRequest.cc @@ -1,62 +1,63 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListProductDimensionGroupsRequest; - -ListProductDimensionGroupsRequest::ListProductDimensionGroupsRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListProductDimensionGroups") -{ - setMethod(HttpRequest::Method::Get); -} - -ListProductDimensionGroupsRequest::~ListProductDimensionGroupsRequest() -{} - -std::string ListProductDimensionGroupsRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListProductDimensionGroupsRequest; + +ListProductDimensionGroupsRequest::ListProductDimensionGroupsRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListProductDimensionGroups") { + setMethod(HttpRequest::Method::Post); } -void ListProductDimensionGroupsRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setParameter("ProductCode", productCode); +ListProductDimensionGroupsRequest::~ListProductDimensionGroupsRequest() {} + +std::string ListProductDimensionGroupsRequest::getOriginalContext() const { + return originalContext_; } -std::string ListProductDimensionGroupsRequest::getNextToken()const -{ - return nextToken_; +void ListProductDimensionGroupsRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void ListProductDimensionGroupsRequest::setNextToken(const std::string& nextToken) -{ - nextToken_ = nextToken; - setParameter("NextToken", nextToken); +std::string ListProductDimensionGroupsRequest::getProductCode() const { + return productCode_; } -int ListProductDimensionGroupsRequest::getMaxResults()const -{ - return maxResults_; +void ListProductDimensionGroupsRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setParameter(std::string("ProductCode"), productCode); } -void ListProductDimensionGroupsRequest::setMaxResults(int maxResults) -{ - maxResults_ = maxResults; - setParameter("MaxResults", std::to_string(maxResults)); +std::string ListProductDimensionGroupsRequest::getNextToken() const { + return nextToken_; +} + +void ListProductDimensionGroupsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +int ListProductDimensionGroupsRequest::getMaxResults() const { + return maxResults_; +} + +void ListProductDimensionGroupsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); } diff --git a/quotas/src/model/ListProductDimensionGroupsResult.cc b/quotas/src/model/ListProductDimensionGroupsResult.cc index 0e16e84b1..9e1ef83df 100644 --- a/quotas/src/model/ListProductDimensionGroupsResult.cc +++ b/quotas/src/model/ListProductDimensionGroupsResult.cc @@ -43,12 +43,12 @@ void ListProductDimensionGroupsResult::parse(const std::string &payload) 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(); + if(!valueDimensionGroupsDimensionGroupsItem["GroupName"].isNull()) + dimensionGroupsObject.groupName = valueDimensionGroupsDimensionGroupsItem["GroupName"].asString(); auto allDimensionKeys = value["DimensionKeys"]["DimensionKeys"]; for (auto value : allDimensionKeys) dimensionGroupsObject.dimensionKeys.push_back(value.asString()); diff --git a/quotas/src/model/ListProductQuotaDimensionsRequest.cc b/quotas/src/model/ListProductQuotaDimensionsRequest.cc index f10d4aed2..a19ab6071 100644 --- a/quotas/src/model/ListProductQuotaDimensionsRequest.cc +++ b/quotas/src/model/ListProductQuotaDimensionsRequest.cc @@ -1,73 +1,72 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListProductQuotaDimensionsRequest; - -ListProductQuotaDimensionsRequest::ListProductQuotaDimensionsRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListProductQuotaDimensions") -{ - setMethod(HttpRequest::Method::Post); -} - -ListProductQuotaDimensionsRequest::~ListProductQuotaDimensionsRequest() -{} - -std::string ListProductQuotaDimensionsRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListProductQuotaDimensionsRequest; + +ListProductQuotaDimensionsRequest::ListProductQuotaDimensionsRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListProductQuotaDimensions") { + setMethod(HttpRequest::Method::Post); } -void ListProductQuotaDimensionsRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +ListProductQuotaDimensionsRequest::~ListProductQuotaDimensionsRequest() {} + +std::string ListProductQuotaDimensionsRequest::getProductCode() const { + return productCode_; } -std::string ListProductQuotaDimensionsRequest::getNextToken()const -{ - return nextToken_; +void ListProductQuotaDimensionsRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void ListProductQuotaDimensionsRequest::setNextToken(const std::string& nextToken) -{ - nextToken_ = nextToken; - setBodyParameter("NextToken", nextToken); +std::string ListProductQuotaDimensionsRequest::getNextToken() const { + return nextToken_; } -int ListProductQuotaDimensionsRequest::getMaxResults()const -{ - return maxResults_; +void ListProductQuotaDimensionsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); } -void ListProductQuotaDimensionsRequest::setMaxResults(int maxResults) -{ - maxResults_ = maxResults; - setBodyParameter("MaxResults", std::to_string(maxResults)); +std::string ListProductQuotaDimensionsRequest::getQuotaCategory() const { + return quotaCategory_; } -std::string ListProductQuotaDimensionsRequest::getQuotaCategory()const -{ - return quotaCategory_; +void ListProductQuotaDimensionsRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); } -void ListProductQuotaDimensionsRequest::setQuotaCategory(const std::string& quotaCategory) -{ - quotaCategory_ = quotaCategory; - setBodyParameter("QuotaCategory", quotaCategory); +std::string ListProductQuotaDimensionsRequest::getOriginalContext() const { + return originalContext_; +} + +void ListProductQuotaDimensionsRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +int ListProductQuotaDimensionsRequest::getMaxResults() const { + return maxResults_; +} + +void ListProductQuotaDimensionsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); } diff --git a/quotas/src/model/ListProductQuotaDimensionsResult.cc b/quotas/src/model/ListProductQuotaDimensionsResult.cc index f9bdd8854..94bab342d 100644 --- a/quotas/src/model/ListProductQuotaDimensionsResult.cc +++ b/quotas/src/model/ListProductQuotaDimensionsResult.cc @@ -43,28 +43,38 @@ void ListProductQuotaDimensionsResult::parse(const std::string &payload) for (auto valueQuotaDimensionsQuotaDimensionsItem : allQuotaDimensionsNode) { QuotaDimensionsItem quotaDimensionsObject; + if(!valueQuotaDimensionsQuotaDimensionsItem["Requisite"].isNull()) + quotaDimensionsObject.requisite = valueQuotaDimensionsQuotaDimensionsItem["Requisite"].asString() == "true"; 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(); + if(!valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem["Value"].isNull()) + dimensionValueDetailObject.value = valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem["Value"].asString(); + auto allDependentDimensions1Node = valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItem["DependentDimensions"]["DependentDimension"]; + for (auto valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItemDependentDimensionsDependentDimension : allDependentDimensions1Node) + { + QuotaDimensionsItem::DimensionValueDetailItem::DependentDimension dependentDimensions1Object; + if(!valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItemDependentDimensionsDependentDimension["Key"].isNull()) + dependentDimensions1Object.key = valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItemDependentDimensionsDependentDimension["Key"].asString(); + if(!valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItemDependentDimensionsDependentDimension["Value"].isNull()) + dependentDimensions1Object.value = valueQuotaDimensionsQuotaDimensionsItemDimensionValueDetailDimensionValueDetailItemDependentDimensionsDependentDimension["Value"].asString(); + dimensionValueDetailObject.dependentDimensions1.push_back(dependentDimensions1Object); + } 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()); + auto allDimensionValues = value["DimensionValues"]["DimensionValues"]; + for (auto value : allDimensionValues) + quotaDimensionsObject.dimensionValues.push_back(value.asString()); quotaDimensions_.push_back(quotaDimensionsObject); } if(!value["TotalCount"].isNull()) diff --git a/quotas/src/model/ListProductQuotasRequest.cc b/quotas/src/model/ListProductQuotasRequest.cc index 7435ddd22..5b5f7f5b5 100644 --- a/quotas/src/model/ListProductQuotasRequest.cc +++ b/quotas/src/model/ListProductQuotasRequest.cc @@ -1,144 +1,131 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListProductQuotasRequest; - -ListProductQuotasRequest::ListProductQuotasRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListProductQuotas") -{ - setMethod(HttpRequest::Method::Post); -} - -ListProductQuotasRequest::~ListProductQuotasRequest() -{} - -std::string ListProductQuotasRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListProductQuotasRequest; + +ListProductQuotasRequest::ListProductQuotasRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListProductQuotas") { + setMethod(HttpRequest::Method::Post); } -void ListProductQuotasRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +ListProductQuotasRequest::~ListProductQuotasRequest() {} + +std::string ListProductQuotasRequest::getProductCode() const { + return productCode_; } -std::string ListProductQuotasRequest::getQuotaActionCode()const -{ - return quotaActionCode_; +void ListProductQuotasRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void ListProductQuotasRequest::setQuotaActionCode(const std::string& quotaActionCode) -{ - quotaActionCode_ = quotaActionCode; - setBodyParameter("QuotaActionCode", quotaActionCode); +std::string ListProductQuotasRequest::getQuotaActionCode() const { + return quotaActionCode_; } -std::string ListProductQuotasRequest::getGroupCode()const -{ - return groupCode_; +void ListProductQuotasRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); } -void ListProductQuotasRequest::setGroupCode(const std::string& groupCode) -{ - groupCode_ = groupCode; - setBodyParameter("GroupCode", groupCode); +std::string ListProductQuotasRequest::getGroupCode() const { + return groupCode_; } -std::string ListProductQuotasRequest::getNextToken()const -{ - return nextToken_; +void ListProductQuotasRequest::setGroupCode(const std::string &groupCode) { + groupCode_ = groupCode; + setBodyParameter(std::string("GroupCode"), groupCode); } -void ListProductQuotasRequest::setNextToken(const std::string& nextToken) -{ - nextToken_ = nextToken; - setBodyParameter("NextToken", nextToken); +std::string ListProductQuotasRequest::getNextToken() const { + return nextToken_; } -std::string ListProductQuotasRequest::getSortOrder()const -{ - return sortOrder_; +void ListProductQuotasRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); } -void ListProductQuotasRequest::setSortOrder(const std::string& sortOrder) -{ - sortOrder_ = sortOrder; - setBodyParameter("SortOrder", sortOrder); +std::string ListProductQuotasRequest::getSortOrder() const { + return sortOrder_; } -std::string ListProductQuotasRequest::getKeyWord()const -{ - return keyWord_; +void ListProductQuotasRequest::setSortOrder(const std::string &sortOrder) { + sortOrder_ = sortOrder; + setBodyParameter(std::string("SortOrder"), sortOrder); } -void ListProductQuotasRequest::setKeyWord(const std::string& keyWord) -{ - keyWord_ = keyWord; - setBodyParameter("KeyWord", keyWord); +std::string ListProductQuotasRequest::getKeyWord() const { + return keyWord_; } -std::string ListProductQuotasRequest::getQuotaCategory()const -{ - return quotaCategory_; +void ListProductQuotasRequest::setKeyWord(const std::string &keyWord) { + keyWord_ = keyWord; + setBodyParameter(std::string("KeyWord"), keyWord); } -void ListProductQuotasRequest::setQuotaCategory(const std::string& quotaCategory) -{ - quotaCategory_ = quotaCategory; - setBodyParameter("QuotaCategory", quotaCategory); +std::string ListProductQuotasRequest::getQuotaCategory() const { + return quotaCategory_; } -int ListProductQuotasRequest::getMaxResults()const -{ - return maxResults_; +void ListProductQuotasRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); } -void ListProductQuotasRequest::setMaxResults(int maxResults) -{ - maxResults_ = maxResults; - setBodyParameter("MaxResults", std::to_string(maxResults)); +std::string ListProductQuotasRequest::getOriginalContext() const { + return originalContext_; } -std::string ListProductQuotasRequest::getSortField()const -{ - return sortField_; +void ListProductQuotasRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void ListProductQuotasRequest::setSortField(const std::string& sortField) -{ - sortField_ = sortField; - setBodyParameter("SortField", sortField); +int ListProductQuotasRequest::getMaxResults() const { + return maxResults_; } -std::vector ListProductQuotasRequest::getDimensions()const -{ - return dimensions_; +void ListProductQuotasRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); } -void ListProductQuotasRequest::setDimensions(const std::vector& 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); - } +std::string ListProductQuotasRequest::getSortField() const { + return sortField_; +} + +void ListProductQuotasRequest::setSortField(const std::string &sortField) { + sortField_ = sortField; + setBodyParameter(std::string("SortField"), sortField); +} + +std::vector ListProductQuotasRequest::getDimensions() const { + return dimensions_; +} + +void ListProductQuotasRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } } diff --git a/quotas/src/model/ListProductQuotasResult.cc b/quotas/src/model/ListProductQuotasResult.cc index 3dfd6abe9..389a93ea5 100644 --- a/quotas/src/model/ListProductQuotasResult.cc +++ b/quotas/src/model/ListProductQuotasResult.cc @@ -43,46 +43,56 @@ void ListProductQuotasResult::parse(const std::string &payload) 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["QuotaUnit"].isNull()) + quotasObject.quotaUnit = valueQuotasQuotasItem["QuotaUnit"].asString(); + if(!valueQuotasQuotasItem["QuotaActionCode"].isNull()) + quotasObject.quotaActionCode = valueQuotasQuotasItem["QuotaActionCode"].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["QuotaDescription"].isNull()) + quotasObject.quotaDescription = valueQuotasQuotasItem["QuotaDescription"].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(); + if(!valueQuotasQuotasItem["Dimensions"].isNull()) + quotasObject.dimensions = valueQuotasQuotasItem["Dimensions"].asString(); + if(!valueQuotasQuotasItem["Adjustable"].isNull()) + quotasObject.adjustable = valueQuotasQuotasItem["Adjustable"].asString() == "true"; + if(!valueQuotasQuotasItem["QuotaName"].isNull()) + quotasObject.quotaName = valueQuotasQuotasItem["QuotaName"].asString(); + if(!valueQuotasQuotasItem["UnadjustableDetail"].isNull()) + quotasObject.unadjustableDetail = valueQuotasQuotasItem["UnadjustableDetail"].asString(); + if(!valueQuotasQuotasItem["Consumable"].isNull()) + quotasObject.consumable = valueQuotasQuotasItem["Consumable"].asString() == "true"; + if(!valueQuotasQuotasItem["TotalQuota"].isNull()) + quotasObject.totalQuota = std::stof(valueQuotasQuotasItem["TotalQuota"].asString()); + if(!valueQuotasQuotasItem["ProductCode"].isNull()) + quotasObject.productCode = valueQuotasQuotasItem["ProductCode"].asString(); + if(!valueQuotasQuotasItem["EffectiveTime"].isNull()) + quotasObject.effectiveTime = valueQuotasQuotasItem["EffectiveTime"].asString(); + if(!valueQuotasQuotasItem["ExpireTime"].isNull()) + quotasObject.expireTime = valueQuotasQuotasItem["ExpireTime"].asString(); + if(!valueQuotasQuotasItem["QuotaCategory"].isNull()) + quotasObject.quotaCategory = valueQuotasQuotasItem["QuotaCategory"].asString(); + if(!valueQuotasQuotasItem["ApplyReasonTips"].isNull()) + quotasObject.applyReasonTips = valueQuotasQuotasItem["ApplyReasonTips"].asString(); + if(!valueQuotasQuotasItem["GlobalQuota"].isNull()) + quotasObject.globalQuota = valueQuotasQuotasItem["GlobalQuota"].asString() == "true"; 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(); + if(!valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Usage"].isNull()) + quotaItemsObject.usage = valueQuotasQuotasItemQuotaItemsQuotaItemsItem["Usage"].asString(); quotasObject.quotaItems.push_back(quotaItemsObject); } auto periodNode = value["Period"]; @@ -90,9 +100,19 @@ void ListProductQuotasResult::parse(const std::string &payload) quotasObject.period.periodValue = std::stoi(periodNode["PeriodValue"].asString()); if(!periodNode["PeriodUnit"].isNull()) quotasObject.period.periodUnit = periodNode["PeriodUnit"].asString(); + auto usageMetricNode = value["UsageMetric"]; + if(!usageMetricNode["MetricNamespace"].isNull()) + quotasObject.usageMetric.metricNamespace = usageMetricNode["MetricNamespace"].asString(); + if(!usageMetricNode["MetricName"].isNull()) + quotasObject.usageMetric.metricName = usageMetricNode["MetricName"].asString(); + if(!usageMetricNode["MetricDimensions"].isNull()) + quotasObject.usageMetric.metricDimensions = usageMetricNode["MetricDimensions"].asString(); auto allApplicableRange = value["ApplicableRange"]["ApplicableRange"]; for (auto value : allApplicableRange) quotasObject.applicableRange.push_back(value.asString()); + auto allSupportedRange = value["SupportedRange"]["SupportedRange"]; + for (auto value : allSupportedRange) + quotasObject.supportedRange.push_back(value.asString()); quotas_.push_back(quotasObject); } if(!value["TotalCount"].isNull()) diff --git a/quotas/src/model/ListProductsRequest.cc b/quotas/src/model/ListProductsRequest.cc index e21962e1b..8fca47721 100644 --- a/quotas/src/model/ListProductsRequest.cc +++ b/quotas/src/model/ListProductsRequest.cc @@ -1,51 +1,54 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListProductsRequest; - -ListProductsRequest::ListProductsRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListProducts") -{ - setMethod(HttpRequest::Method::Post); -} - -ListProductsRequest::~ListProductsRequest() -{} - -std::string ListProductsRequest::getNextToken()const -{ - return nextToken_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListProductsRequest; + +ListProductsRequest::ListProductsRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListProducts") { + setMethod(HttpRequest::Method::Post); } -void ListProductsRequest::setNextToken(const std::string& nextToken) -{ - nextToken_ = nextToken; - setBodyParameter("NextToken", nextToken); +ListProductsRequest::~ListProductsRequest() {} + +std::string ListProductsRequest::getOriginalContext() const { + return originalContext_; } -int ListProductsRequest::getMaxResults()const -{ - return maxResults_; +void ListProductsRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void ListProductsRequest::setMaxResults(int maxResults) -{ - maxResults_ = maxResults; - setBodyParameter("MaxResults", std::to_string(maxResults)); +std::string ListProductsRequest::getNextToken() const { + return nextToken_; +} + +void ListProductsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); +} + +int ListProductsRequest::getMaxResults() const { + return maxResults_; +} + +void ListProductsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); } diff --git a/quotas/src/model/ListProductsResult.cc b/quotas/src/model/ListProductsResult.cc index 589639105..2d27b0444 100644 --- a/quotas/src/model/ListProductsResult.cc +++ b/quotas/src/model/ListProductsResult.cc @@ -43,24 +43,26 @@ void ListProductsResult::parse(const std::string &payload) 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(); + if(!valueProductInfoProductInfos["Dynamic"].isNull()) + productInfoObject.dynamic = valueProductInfoProductInfos["Dynamic"].asString() == "true"; + if(!valueProductInfoProductInfos["SecondCategoryNameEn"].isNull()) + productInfoObject.secondCategoryNameEn = valueProductInfoProductInfos["SecondCategoryNameEn"].asString(); + if(!valueProductInfoProductInfos["SecondCategoryName"].isNull()) + productInfoObject.secondCategoryName = valueProductInfoProductInfos["SecondCategoryName"].asString(); + if(!valueProductInfoProductInfos["ProductCode"].isNull()) + productInfoObject.productCode = valueProductInfoProductInfos["ProductCode"].asString(); + if(!valueProductInfoProductInfos["FlowControlSupport"].isNull()) + productInfoObject.flowControlSupport = valueProductInfoProductInfos["FlowControlSupport"].asString(); + if(!valueProductInfoProductInfos["CommonQuotaSupport"].isNull()) + productInfoObject.commonQuotaSupport = valueProductInfoProductInfos["CommonQuotaSupport"].asString(); + if(!valueProductInfoProductInfos["WhiteListLabelQuotaSupport"].isNull()) + productInfoObject.whiteListLabelQuotaSupport = valueProductInfoProductInfos["WhiteListLabelQuotaSupport"].asString(); productInfo_.push_back(productInfoObject); } if(!value["TotalCount"].isNull()) diff --git a/quotas/src/model/ListQuotaAlarmsRequest.cc b/quotas/src/model/ListQuotaAlarmsRequest.cc index a9fa1c96e..08499d547 100644 --- a/quotas/src/model/ListQuotaAlarmsRequest.cc +++ b/quotas/src/model/ListQuotaAlarmsRequest.cc @@ -1,100 +1,95 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListQuotaAlarmsRequest; - -ListQuotaAlarmsRequest::ListQuotaAlarmsRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListQuotaAlarms") -{ - setMethod(HttpRequest::Method::Post); -} - -ListQuotaAlarmsRequest::~ListQuotaAlarmsRequest() -{} - -std::string ListQuotaAlarmsRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListQuotaAlarmsRequest; + +ListQuotaAlarmsRequest::ListQuotaAlarmsRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListQuotaAlarms") { + setMethod(HttpRequest::Method::Post); } -void ListQuotaAlarmsRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +ListQuotaAlarmsRequest::~ListQuotaAlarmsRequest() {} + +std::string ListQuotaAlarmsRequest::getProductCode() const { + return productCode_; } -std::string ListQuotaAlarmsRequest::getQuotaActionCode()const -{ - return quotaActionCode_; +void ListQuotaAlarmsRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void ListQuotaAlarmsRequest::setQuotaActionCode(const std::string& quotaActionCode) -{ - quotaActionCode_ = quotaActionCode; - setBodyParameter("QuotaActionCode", quotaActionCode); +std::string ListQuotaAlarmsRequest::getQuotaActionCode() const { + return quotaActionCode_; } -std::string ListQuotaAlarmsRequest::getNextToken()const -{ - return nextToken_; +void ListQuotaAlarmsRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); } -void ListQuotaAlarmsRequest::setNextToken(const std::string& nextToken) -{ - nextToken_ = nextToken; - setBodyParameter("NextToken", nextToken); +std::string ListQuotaAlarmsRequest::getNextToken() const { + return nextToken_; } -std::vector ListQuotaAlarmsRequest::getQuotaDimensions()const -{ - return quotaDimensions_; +void ListQuotaAlarmsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); } -void ListQuotaAlarmsRequest::setQuotaDimensions(const std::vector& 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); - } +std::vector ListQuotaAlarmsRequest::getQuotaDimensions() const { + return quotaDimensions_; } -int ListQuotaAlarmsRequest::getMaxResults()const -{ - return maxResults_; +void ListQuotaAlarmsRequest::setQuotaDimensions(const std::vector "aDimensions) { + quotaDimensions_ = quotaDimensions; + for(int dep1 = 0; dep1 != quotaDimensions.size(); dep1++) { + auto quotaDimensionsObj = quotaDimensions.at(dep1); + std::string quotaDimensionsObjStr = std::string("QuotaDimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(quotaDimensionsObjStr + ".Key", quotaDimensionsObj.key); + setBodyParameter(quotaDimensionsObjStr + ".Value", quotaDimensionsObj.value); + } } -void ListQuotaAlarmsRequest::setMaxResults(int maxResults) -{ - maxResults_ = maxResults; - setBodyParameter("MaxResults", std::to_string(maxResults)); +std::string ListQuotaAlarmsRequest::getOriginalContext() const { + return originalContext_; } -std::string ListQuotaAlarmsRequest::getAlarmName()const -{ - return alarmName_; +void ListQuotaAlarmsRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void ListQuotaAlarmsRequest::setAlarmName(const std::string& alarmName) -{ - alarmName_ = alarmName; - setBodyParameter("AlarmName", alarmName); +int ListQuotaAlarmsRequest::getMaxResults() const { + return maxResults_; +} + +void ListQuotaAlarmsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + +std::string ListQuotaAlarmsRequest::getAlarmName() const { + return alarmName_; +} + +void ListQuotaAlarmsRequest::setAlarmName(const std::string &alarmName) { + alarmName_ = alarmName; + setBodyParameter(std::string("AlarmName"), alarmName); } diff --git a/quotas/src/model/ListQuotaAlarmsResult.cc b/quotas/src/model/ListQuotaAlarmsResult.cc index 0ec713081..ba510659e 100644 --- a/quotas/src/model/ListQuotaAlarmsResult.cc +++ b/quotas/src/model/ListQuotaAlarmsResult.cc @@ -43,34 +43,34 @@ void ListQuotaAlarmsResult::parse(const std::string &payload) 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["ThresholdType"].isNull()) + quotaAlarmsObject.thresholdType = valueQuotaAlarmsQuotaAlarm["ThresholdType"].asString(); + if(!valueQuotaAlarmsQuotaAlarm["QuotaDimensions"].isNull()) + quotaAlarmsObject.quotaDimensions = valueQuotaAlarmsQuotaAlarm["QuotaDimensions"].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["QuotaUsage"].isNull()) + quotaAlarmsObject.quotaUsage = std::stof(valueQuotaAlarmsQuotaAlarm["QuotaUsage"].asString()); + if(!valueQuotaAlarmsQuotaAlarm["QuotaValue"].isNull()) + quotaAlarmsObject.quotaValue = std::stof(valueQuotaAlarmsQuotaAlarm["QuotaValue"].asString()); + if(!valueQuotaAlarmsQuotaAlarm["AlarmId"].isNull()) + quotaAlarmsObject.alarmId = valueQuotaAlarmsQuotaAlarm["AlarmId"].asString(); if(!valueQuotaAlarmsQuotaAlarm["Threshold"].isNull()) quotaAlarmsObject.threshold = std::stof(valueQuotaAlarmsQuotaAlarm["Threshold"].asString()); - if(!valueQuotaAlarmsQuotaAlarm["ThresholdType"].isNull()) - quotaAlarmsObject.thresholdType = valueQuotaAlarmsQuotaAlarm["ThresholdType"].asString(); + if(!valueQuotaAlarmsQuotaAlarm["ProductCode"].isNull()) + quotaAlarmsObject.productCode = valueQuotaAlarmsQuotaAlarm["ProductCode"].asString(); + if(!valueQuotaAlarmsQuotaAlarm["WebHook"].isNull()) + quotaAlarmsObject.webHook = valueQuotaAlarmsQuotaAlarm["WebHook"].asString(); + if(!valueQuotaAlarmsQuotaAlarm["ExceedThreshold"].isNull()) + quotaAlarmsObject.exceedThreshold = valueQuotaAlarmsQuotaAlarm["ExceedThreshold"].asString() == "true"; auto allNotifyChannels = value["NotifyChannels"]["NotifyChannels"]; for (auto value : allNotifyChannels) quotaAlarmsObject.notifyChannels.push_back(value.asString()); diff --git a/quotas/src/model/ListQuotaApplicationTemplatesRequest.cc b/quotas/src/model/ListQuotaApplicationTemplatesRequest.cc new file mode 100644 index 000000000..20adb98fe --- /dev/null +++ b/quotas/src/model/ListQuotaApplicationTemplatesRequest.cc @@ -0,0 +1,104 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::ListQuotaApplicationTemplatesRequest; + +ListQuotaApplicationTemplatesRequest::ListQuotaApplicationTemplatesRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListQuotaApplicationTemplates") { + setMethod(HttpRequest::Method::Post); +} + +ListQuotaApplicationTemplatesRequest::~ListQuotaApplicationTemplatesRequest() {} + +std::string ListQuotaApplicationTemplatesRequest::getProductCode() const { + return productCode_; +} + +void ListQuotaApplicationTemplatesRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); +} + +std::string ListQuotaApplicationTemplatesRequest::getQuotaActionCode() const { + return quotaActionCode_; +} + +void ListQuotaApplicationTemplatesRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); +} + +std::string ListQuotaApplicationTemplatesRequest::getNextToken() const { + return nextToken_; +} + +void ListQuotaApplicationTemplatesRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +std::string ListQuotaApplicationTemplatesRequest::getId() const { + return id_; +} + +void ListQuotaApplicationTemplatesRequest::setId(const std::string &id) { + id_ = id; + setBodyParameter(std::string("Id"), id); +} + +std::string ListQuotaApplicationTemplatesRequest::getQuotaCategory() const { + return quotaCategory_; +} + +void ListQuotaApplicationTemplatesRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); +} + +std::string ListQuotaApplicationTemplatesRequest::getOriginalContext() const { + return originalContext_; +} + +void ListQuotaApplicationTemplatesRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +int ListQuotaApplicationTemplatesRequest::getMaxResults() const { + return maxResults_; +} + +void ListQuotaApplicationTemplatesRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + +std::vector ListQuotaApplicationTemplatesRequest::getDimensions() const { + return dimensions_; +} + +void ListQuotaApplicationTemplatesRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } +} + diff --git a/quotas/src/model/ListQuotaApplicationTemplatesResult.cc b/quotas/src/model/ListQuotaApplicationTemplatesResult.cc new file mode 100644 index 000000000..e9b2c7bd0 --- /dev/null +++ b/quotas/src/model/ListQuotaApplicationTemplatesResult.cc @@ -0,0 +1,110 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +ListQuotaApplicationTemplatesResult::ListQuotaApplicationTemplatesResult() : + ServiceResult() +{} + +ListQuotaApplicationTemplatesResult::ListQuotaApplicationTemplatesResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListQuotaApplicationTemplatesResult::~ListQuotaApplicationTemplatesResult() +{} + +void ListQuotaApplicationTemplatesResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allQuotaApplicationTemplatesNode = value["QuotaApplicationTemplates"]["QuotaApplicationTemplatesItem"]; + for (auto valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem : allQuotaApplicationTemplatesNode) + { + QuotaApplicationTemplatesItem quotaApplicationTemplatesObject; + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["Id"].isNull()) + quotaApplicationTemplatesObject.id = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["Id"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["ProductCode"].isNull()) + quotaApplicationTemplatesObject.productCode = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["ProductCode"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["Dimensions"].isNull()) + quotaApplicationTemplatesObject.dimensions = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["Dimensions"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["DesireValue"].isNull()) + quotaApplicationTemplatesObject.desireValue = std::stof(valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["DesireValue"].asString()); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["NoticeType"].isNull()) + quotaApplicationTemplatesObject.noticeType = std::stoi(valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["NoticeType"].asString()); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaActionCode"].isNull()) + quotaApplicationTemplatesObject.quotaActionCode = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaActionCode"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["ApplicableType"].isNull()) + quotaApplicationTemplatesObject.applicableType = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["ApplicableType"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["EnvLanguage"].isNull()) + quotaApplicationTemplatesObject.envLanguage = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["EnvLanguage"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaName"].isNull()) + quotaApplicationTemplatesObject.quotaName = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaName"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaDescription"].isNull()) + quotaApplicationTemplatesObject.quotaDescription = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaDescription"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["EffectiveTime"].isNull()) + quotaApplicationTemplatesObject.effectiveTime = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["EffectiveTime"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["ExpireTime"].isNull()) + quotaApplicationTemplatesObject.expireTime = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["ExpireTime"].asString(); + if(!valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaCategory"].isNull()) + quotaApplicationTemplatesObject.quotaCategory = valueQuotaApplicationTemplatesQuotaApplicationTemplatesItem["QuotaCategory"].asString(); + auto periodNode = value["Period"]; + if(!periodNode["PeriodValue"].isNull()) + quotaApplicationTemplatesObject.period.periodValue = std::stoi(periodNode["PeriodValue"].asString()); + if(!periodNode["PeriodUnit"].isNull()) + quotaApplicationTemplatesObject.period.periodUnit = periodNode["PeriodUnit"].asString(); + auto allApplicableRange = value["ApplicableRange"]["Applicable"]; + for (auto value : allApplicableRange) + quotaApplicationTemplatesObject.applicableRange.push_back(value.asString()); + quotaApplicationTemplates_.push_back(quotaApplicationTemplatesObject); + } + if(!value["MaxResults"].isNull()) + maxResults_ = std::stoi(value["MaxResults"].asString()); + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + if(!value["TotalCount"].isNull()) + totalCount_ = std::stoi(value["TotalCount"].asString()); + +} + +int ListQuotaApplicationTemplatesResult::getTotalCount()const +{ + return totalCount_; +} + +std::string ListQuotaApplicationTemplatesResult::getNextToken()const +{ + return nextToken_; +} + +int ListQuotaApplicationTemplatesResult::getMaxResults()const +{ + return maxResults_; +} + +std::vector ListQuotaApplicationTemplatesResult::getQuotaApplicationTemplates()const +{ + return quotaApplicationTemplates_; +} + diff --git a/quotas/src/model/ListQuotaApplicationsDetailForTemplateRequest.cc b/quotas/src/model/ListQuotaApplicationsDetailForTemplateRequest.cc new file mode 100644 index 000000000..b9c226b39 --- /dev/null +++ b/quotas/src/model/ListQuotaApplicationsDetailForTemplateRequest.cc @@ -0,0 +1,108 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::ListQuotaApplicationsDetailForTemplateRequest; + +ListQuotaApplicationsDetailForTemplateRequest::ListQuotaApplicationsDetailForTemplateRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListQuotaApplicationsDetailForTemplate") { + setMethod(HttpRequest::Method::Post); +} + +ListQuotaApplicationsDetailForTemplateRequest::~ListQuotaApplicationsDetailForTemplateRequest() {} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getProductCode() const { + return productCode_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); +} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getQuotaActionCode() const { + return quotaActionCode_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); +} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getBatchQuotaApplicationId() const { + return batchQuotaApplicationId_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setBatchQuotaApplicationId(const std::string &batchQuotaApplicationId) { + batchQuotaApplicationId_ = batchQuotaApplicationId; + setBodyParameter(std::string("BatchQuotaApplicationId"), batchQuotaApplicationId); +} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getNextToken() const { + return nextToken_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); +} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getQuotaCategory() const { + return quotaCategory_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); +} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getOriginalContext() const { + return originalContext_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getAliyunUid() const { + return aliyunUid_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setAliyunUid(const std::string &aliyunUid) { + aliyunUid_ = aliyunUid; + setBodyParameter(std::string("AliyunUid"), aliyunUid); +} + +int ListQuotaApplicationsDetailForTemplateRequest::getMaxResults() const { + return maxResults_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + +std::string ListQuotaApplicationsDetailForTemplateRequest::getStatus() const { + return status_; +} + +void ListQuotaApplicationsDetailForTemplateRequest::setStatus(const std::string &status) { + status_ = status; + setBodyParameter(std::string("Status"), status); +} + diff --git a/quotas/src/model/ListQuotaApplicationsDetailForTemplateResult.cc b/quotas/src/model/ListQuotaApplicationsDetailForTemplateResult.cc new file mode 100644 index 000000000..6b48b63e7 --- /dev/null +++ b/quotas/src/model/ListQuotaApplicationsDetailForTemplateResult.cc @@ -0,0 +1,123 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +ListQuotaApplicationsDetailForTemplateResult::ListQuotaApplicationsDetailForTemplateResult() : + ServiceResult() +{} + +ListQuotaApplicationsDetailForTemplateResult::ListQuotaApplicationsDetailForTemplateResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListQuotaApplicationsDetailForTemplateResult::~ListQuotaApplicationsDetailForTemplateResult() +{} + +void ListQuotaApplicationsDetailForTemplateResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allQuotaApplicationsNode = value["QuotaApplications"]["QuotaBatchApplicationDetailVos"]; + for (auto valueQuotaApplicationsQuotaBatchApplicationDetailVos : allQuotaApplicationsNode) + { + QuotaBatchApplicationDetailVos quotaApplicationsObject; + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["BatchQuotaApplicationId"].isNull()) + quotaApplicationsObject.batchQuotaApplicationId = valueQuotaApplicationsQuotaBatchApplicationDetailVos["BatchQuotaApplicationId"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["ProductCode"].isNull()) + quotaApplicationsObject.productCode = valueQuotaApplicationsQuotaBatchApplicationDetailVos["ProductCode"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaActionCode"].isNull()) + quotaApplicationsObject.quotaActionCode = valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaActionCode"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaName"].isNull()) + quotaApplicationsObject.quotaName = valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaName"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaDescription"].isNull()) + quotaApplicationsObject.quotaDescription = valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaDescription"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaUnit"].isNull()) + quotaApplicationsObject.quotaUnit = valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaUnit"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaArn"].isNull()) + quotaApplicationsObject.quotaArn = valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaArn"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaDimension"].isNull()) + quotaApplicationsObject.quotaDimension = valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaDimension"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["ApplicationId"].isNull()) + quotaApplicationsObject.applicationId = valueQuotaApplicationsQuotaBatchApplicationDetailVos["ApplicationId"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["DesireValue"].isNull()) + quotaApplicationsObject.desireValue = valueQuotaApplicationsQuotaBatchApplicationDetailVos["DesireValue"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["Reason"].isNull()) + quotaApplicationsObject.reason = valueQuotaApplicationsQuotaBatchApplicationDetailVos["Reason"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["Status"].isNull()) + quotaApplicationsObject.status = valueQuotaApplicationsQuotaBatchApplicationDetailVos["Status"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["ApproveValue"].isNull()) + quotaApplicationsObject.approveValue = valueQuotaApplicationsQuotaBatchApplicationDetailVos["ApproveValue"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["EffectiveTime"].isNull()) + quotaApplicationsObject.effectiveTime = valueQuotaApplicationsQuotaBatchApplicationDetailVos["EffectiveTime"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["ExpireTime"].isNull()) + quotaApplicationsObject.expireTime = valueQuotaApplicationsQuotaBatchApplicationDetailVos["ExpireTime"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["ApplyTime"].isNull()) + quotaApplicationsObject.applyTime = valueQuotaApplicationsQuotaBatchApplicationDetailVos["ApplyTime"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["AuditReason"].isNull()) + quotaApplicationsObject.auditReason = valueQuotaApplicationsQuotaBatchApplicationDetailVos["AuditReason"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["NoticeType"].isNull()) + quotaApplicationsObject.noticeType = std::stoi(valueQuotaApplicationsQuotaBatchApplicationDetailVos["NoticeType"].asString()); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["AliyunUid"].isNull()) + quotaApplicationsObject.aliyunUid = valueQuotaApplicationsQuotaBatchApplicationDetailVos["AliyunUid"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaCategory"].isNull()) + quotaApplicationsObject.quotaCategory = valueQuotaApplicationsQuotaBatchApplicationDetailVos["QuotaCategory"].asString(); + if(!valueQuotaApplicationsQuotaBatchApplicationDetailVos["EnvLanguage"].isNull()) + quotaApplicationsObject.envLanguage = valueQuotaApplicationsQuotaBatchApplicationDetailVos["EnvLanguage"].asString(); + auto periodNode = value["Period"]; + if(!periodNode["PeriodUnit"].isNull()) + quotaApplicationsObject.period.periodUnit = periodNode["PeriodUnit"].asString(); + if(!periodNode["PeriodValue"].isNull()) + quotaApplicationsObject.period.periodValue = std::stoi(periodNode["PeriodValue"].asString()); + quotaApplications_.push_back(quotaApplicationsObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + if(!value["TotalCount"].isNull()) + totalCount_ = std::stoi(value["TotalCount"].asString()); + if(!value["MaxResults"].isNull()) + maxResults_ = std::stoi(value["MaxResults"].asString()); + +} + +std::vector ListQuotaApplicationsDetailForTemplateResult::getQuotaApplications()const +{ + return quotaApplications_; +} + +int ListQuotaApplicationsDetailForTemplateResult::getTotalCount()const +{ + return totalCount_; +} + +std::string ListQuotaApplicationsDetailForTemplateResult::getNextToken()const +{ + return nextToken_; +} + +int ListQuotaApplicationsDetailForTemplateResult::getMaxResults()const +{ + return maxResults_; +} + diff --git a/quotas/src/model/ListQuotaApplicationsForTemplateRequest.cc b/quotas/src/model/ListQuotaApplicationsForTemplateRequest.cc new file mode 100644 index 000000000..7594af45f --- /dev/null +++ b/quotas/src/model/ListQuotaApplicationsForTemplateRequest.cc @@ -0,0 +1,108 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::ListQuotaApplicationsForTemplateRequest; + +ListQuotaApplicationsForTemplateRequest::ListQuotaApplicationsForTemplateRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListQuotaApplicationsForTemplate") { + setMethod(HttpRequest::Method::Post); +} + +ListQuotaApplicationsForTemplateRequest::~ListQuotaApplicationsForTemplateRequest() {} + +std::string ListQuotaApplicationsForTemplateRequest::getProductCode() const { + return productCode_; +} + +void ListQuotaApplicationsForTemplateRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); +} + +std::string ListQuotaApplicationsForTemplateRequest::getQuotaActionCode() const { + return quotaActionCode_; +} + +void ListQuotaApplicationsForTemplateRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); +} + +std::string ListQuotaApplicationsForTemplateRequest::getBatchQuotaApplicationId() const { + return batchQuotaApplicationId_; +} + +void ListQuotaApplicationsForTemplateRequest::setBatchQuotaApplicationId(const std::string &batchQuotaApplicationId) { + batchQuotaApplicationId_ = batchQuotaApplicationId; + setBodyParameter(std::string("BatchQuotaApplicationId"), batchQuotaApplicationId); +} + +std::string ListQuotaApplicationsForTemplateRequest::getNextToken() const { + return nextToken_; +} + +void ListQuotaApplicationsForTemplateRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); +} + +std::string ListQuotaApplicationsForTemplateRequest::getQuotaCategory() const { + return quotaCategory_; +} + +void ListQuotaApplicationsForTemplateRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); +} + +std::string ListQuotaApplicationsForTemplateRequest::getOriginalContext() const { + return originalContext_; +} + +void ListQuotaApplicationsForTemplateRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string ListQuotaApplicationsForTemplateRequest::getApplyStartTime() const { + return applyStartTime_; +} + +void ListQuotaApplicationsForTemplateRequest::setApplyStartTime(const std::string &applyStartTime) { + applyStartTime_ = applyStartTime; + setBodyParameter(std::string("ApplyStartTime"), applyStartTime); +} + +std::string ListQuotaApplicationsForTemplateRequest::getApplyEndTime() const { + return applyEndTime_; +} + +void ListQuotaApplicationsForTemplateRequest::setApplyEndTime(const std::string &applyEndTime) { + applyEndTime_ = applyEndTime; + setBodyParameter(std::string("ApplyEndTime"), applyEndTime); +} + +int ListQuotaApplicationsForTemplateRequest::getMaxResults() const { + return maxResults_; +} + +void ListQuotaApplicationsForTemplateRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + diff --git a/quotas/src/model/ListQuotaApplicationsForTemplateResult.cc b/quotas/src/model/ListQuotaApplicationsForTemplateResult.cc new file mode 100644 index 000000000..ad56700f5 --- /dev/null +++ b/quotas/src/model/ListQuotaApplicationsForTemplateResult.cc @@ -0,0 +1,109 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +ListQuotaApplicationsForTemplateResult::ListQuotaApplicationsForTemplateResult() : + ServiceResult() +{} + +ListQuotaApplicationsForTemplateResult::ListQuotaApplicationsForTemplateResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ListQuotaApplicationsForTemplateResult::~ListQuotaApplicationsForTemplateResult() +{} + +void ListQuotaApplicationsForTemplateResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allQuotaBatchApplicationsNode = value["QuotaBatchApplications"]["QuotaBatchApplicationsItem"]; + for (auto valueQuotaBatchApplicationsQuotaBatchApplicationsItem : allQuotaBatchApplicationsNode) + { + QuotaBatchApplicationsItem quotaBatchApplicationsObject; + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["ProductCode"].isNull()) + quotaBatchApplicationsObject.productCode = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["ProductCode"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["QuotaActionCode"].isNull()) + quotaBatchApplicationsObject.quotaActionCode = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["QuotaActionCode"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["BatchQuotaApplicationId"].isNull()) + quotaBatchApplicationsObject.batchQuotaApplicationId = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["BatchQuotaApplicationId"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["EffectiveTime"].isNull()) + quotaBatchApplicationsObject.effectiveTime = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["EffectiveTime"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["ExpireTime"].isNull()) + quotaBatchApplicationsObject.expireTime = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["ExpireTime"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["ApplyTime"].isNull()) + quotaBatchApplicationsObject.applyTime = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["ApplyTime"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["DesireValue"].isNull()) + quotaBatchApplicationsObject.desireValue = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["DesireValue"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["QuotaCategory"].isNull()) + quotaBatchApplicationsObject.quotaCategory = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["QuotaCategory"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["Dimensions"].isNull()) + quotaBatchApplicationsObject.dimensions = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["Dimensions"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItem["Reason"].isNull()) + quotaBatchApplicationsObject.reason = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["Reason"].asString(); + auto allAuditStatusVosNode = valueQuotaBatchApplicationsQuotaBatchApplicationsItem["AuditStatusVos"]["AuditStatusVo"]; + for (auto valueQuotaBatchApplicationsQuotaBatchApplicationsItemAuditStatusVosAuditStatusVo : allAuditStatusVosNode) + { + QuotaBatchApplicationsItem::AuditStatusVo auditStatusVosObject; + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItemAuditStatusVosAuditStatusVo["Status"].isNull()) + auditStatusVosObject.status = valueQuotaBatchApplicationsQuotaBatchApplicationsItemAuditStatusVosAuditStatusVo["Status"].asString(); + if(!valueQuotaBatchApplicationsQuotaBatchApplicationsItemAuditStatusVosAuditStatusVo["Count"].isNull()) + auditStatusVosObject.count = std::stoi(valueQuotaBatchApplicationsQuotaBatchApplicationsItemAuditStatusVosAuditStatusVo["Count"].asString()); + quotaBatchApplicationsObject.auditStatusVos.push_back(auditStatusVosObject); + } + auto allAliyunUids = value["AliyunUids"]["AliyunUids"]; + for (auto value : allAliyunUids) + quotaBatchApplicationsObject.aliyunUids.push_back(value.asString()); + quotaBatchApplications_.push_back(quotaBatchApplicationsObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + if(!value["TotalCount"].isNull()) + totalCount_ = std::stoi(value["TotalCount"].asString()); + if(!value["MaxResults"].isNull()) + maxResults_ = std::stoi(value["MaxResults"].asString()); + +} + +int ListQuotaApplicationsForTemplateResult::getTotalCount()const +{ + return totalCount_; +} + +std::string ListQuotaApplicationsForTemplateResult::getNextToken()const +{ + return nextToken_; +} + +std::vector ListQuotaApplicationsForTemplateResult::getQuotaBatchApplications()const +{ + return quotaBatchApplications_; +} + +int ListQuotaApplicationsForTemplateResult::getMaxResults()const +{ + return maxResults_; +} + diff --git a/quotas/src/model/ListQuotaApplicationsRequest.cc b/quotas/src/model/ListQuotaApplicationsRequest.cc index 68915ac3e..82d6822f8 100644 --- a/quotas/src/model/ListQuotaApplicationsRequest.cc +++ b/quotas/src/model/ListQuotaApplicationsRequest.cc @@ -1,122 +1,113 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::ListQuotaApplicationsRequest; - -ListQuotaApplicationsRequest::ListQuotaApplicationsRequest() : - RpcServiceRequest("quotas", "2020-05-10", "ListQuotaApplications") -{ - setMethod(HttpRequest::Method::Post); -} - -ListQuotaApplicationsRequest::~ListQuotaApplicationsRequest() -{} - -std::string ListQuotaApplicationsRequest::getProductCode()const -{ - return productCode_; + */ + +#include + +using AlibabaCloud::Quotas::Model::ListQuotaApplicationsRequest; + +ListQuotaApplicationsRequest::ListQuotaApplicationsRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ListQuotaApplications") { + setMethod(HttpRequest::Method::Post); } -void ListQuotaApplicationsRequest::setProductCode(const std::string& productCode) -{ - productCode_ = productCode; - setBodyParameter("ProductCode", productCode); +ListQuotaApplicationsRequest::~ListQuotaApplicationsRequest() {} + +std::string ListQuotaApplicationsRequest::getProductCode() const { + return productCode_; } -std::string ListQuotaApplicationsRequest::getQuotaActionCode()const -{ - return quotaActionCode_; +void ListQuotaApplicationsRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); } -void ListQuotaApplicationsRequest::setQuotaActionCode(const std::string& quotaActionCode) -{ - quotaActionCode_ = quotaActionCode; - setBodyParameter("QuotaActionCode", quotaActionCode); +std::string ListQuotaApplicationsRequest::getQuotaActionCode() const { + return quotaActionCode_; } -std::string ListQuotaApplicationsRequest::getNextToken()const -{ - return nextToken_; +void ListQuotaApplicationsRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); } -void ListQuotaApplicationsRequest::setNextToken(const std::string& nextToken) -{ - nextToken_ = nextToken; - setBodyParameter("NextToken", nextToken); +std::string ListQuotaApplicationsRequest::getNextToken() const { + return nextToken_; } -std::string ListQuotaApplicationsRequest::getKeyWord()const -{ - return keyWord_; +void ListQuotaApplicationsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setBodyParameter(std::string("NextToken"), nextToken); } -void ListQuotaApplicationsRequest::setKeyWord(const std::string& keyWord) -{ - keyWord_ = keyWord; - setBodyParameter("KeyWord", keyWord); +std::string ListQuotaApplicationsRequest::getKeyWord() const { + return keyWord_; } -std::string ListQuotaApplicationsRequest::getQuotaCategory()const -{ - return quotaCategory_; +void ListQuotaApplicationsRequest::setKeyWord(const std::string &keyWord) { + keyWord_ = keyWord; + setBodyParameter(std::string("KeyWord"), keyWord); } -void ListQuotaApplicationsRequest::setQuotaCategory(const std::string& quotaCategory) -{ - quotaCategory_ = quotaCategory; - setBodyParameter("QuotaCategory", quotaCategory); +std::string ListQuotaApplicationsRequest::getQuotaCategory() const { + return quotaCategory_; } -int ListQuotaApplicationsRequest::getMaxResults()const -{ - return maxResults_; +void ListQuotaApplicationsRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setBodyParameter(std::string("QuotaCategory"), quotaCategory); } -void ListQuotaApplicationsRequest::setMaxResults(int maxResults) -{ - maxResults_ = maxResults; - setBodyParameter("MaxResults", std::to_string(maxResults)); +std::string ListQuotaApplicationsRequest::getOriginalContext() const { + return originalContext_; } -std::string ListQuotaApplicationsRequest::getStatus()const -{ - return status_; +void ListQuotaApplicationsRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void ListQuotaApplicationsRequest::setStatus(const std::string& status) -{ - status_ = status; - setBodyParameter("Status", status); +int ListQuotaApplicationsRequest::getMaxResults() const { + return maxResults_; } -std::vector ListQuotaApplicationsRequest::getDimensions()const -{ - return dimensions_; +void ListQuotaApplicationsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setBodyParameter(std::string("MaxResults"), std::to_string(maxResults)); } -void ListQuotaApplicationsRequest::setDimensions(const std::vector& 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); - } +std::string ListQuotaApplicationsRequest::getStatus() const { + return status_; +} + +void ListQuotaApplicationsRequest::setStatus(const std::string &status) { + status_ = status; + setBodyParameter(std::string("Status"), status); +} + +std::vector ListQuotaApplicationsRequest::getDimensions() const { + return dimensions_; +} + +void ListQuotaApplicationsRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } } diff --git a/quotas/src/model/ListQuotaApplicationsResult.cc b/quotas/src/model/ListQuotaApplicationsResult.cc index b296932c6..1f04a3781 100644 --- a/quotas/src/model/ListQuotaApplicationsResult.cc +++ b/quotas/src/model/ListQuotaApplicationsResult.cc @@ -45,40 +45,40 @@ void ListQuotaApplicationsResult::parse(const std::string &payload) 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(); + if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaUnit"].isNull()) + quotaApplicationsObject.quotaUnit = valueQuotaApplicationsQuotaApplicationsItem["QuotaUnit"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["DesireValue"].isNull()) + quotaApplicationsObject.desireValue = std::stof(valueQuotaApplicationsQuotaApplicationsItem["DesireValue"].asString()); + if(!valueQuotaApplicationsQuotaApplicationsItem["NoticeType"].isNull()) + quotaApplicationsObject.noticeType = std::stoi(valueQuotaApplicationsQuotaApplicationsItem["NoticeType"].asString()); + if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaActionCode"].isNull()) + quotaApplicationsObject.quotaActionCode = valueQuotaApplicationsQuotaApplicationsItem["QuotaActionCode"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["Dimension"].isNull()) + quotaApplicationsObject.dimension = valueQuotaApplicationsQuotaApplicationsItem["Dimension"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaDescription"].isNull()) + quotaApplicationsObject.quotaDescription = valueQuotaApplicationsQuotaApplicationsItem["QuotaDescription"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaArn"].isNull()) + quotaApplicationsObject.quotaArn = valueQuotaApplicationsQuotaApplicationsItem["QuotaArn"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["EffectiveTime"].isNull()) + quotaApplicationsObject.effectiveTime = valueQuotaApplicationsQuotaApplicationsItem["EffectiveTime"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["ApproveValue"].isNull()) + quotaApplicationsObject.approveValue = std::stof(valueQuotaApplicationsQuotaApplicationsItem["ApproveValue"].asString()); + if(!valueQuotaApplicationsQuotaApplicationsItem["QuotaName"].isNull()) + quotaApplicationsObject.quotaName = valueQuotaApplicationsQuotaApplicationsItem["QuotaName"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["ApplicationId"].isNull()) + quotaApplicationsObject.applicationId = valueQuotaApplicationsQuotaApplicationsItem["ApplicationId"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["AuditReason"].isNull()) + quotaApplicationsObject.auditReason = valueQuotaApplicationsQuotaApplicationsItem["AuditReason"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["Reason"].isNull()) + quotaApplicationsObject.reason = valueQuotaApplicationsQuotaApplicationsItem["Reason"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["ApplyTime"].isNull()) + quotaApplicationsObject.applyTime = valueQuotaApplicationsQuotaApplicationsItem["ApplyTime"].asString(); + if(!valueQuotaApplicationsQuotaApplicationsItem["ProductCode"].isNull()) + quotaApplicationsObject.productCode = valueQuotaApplicationsQuotaApplicationsItem["ProductCode"].asString(); auto periodNode = value["Period"]; if(!periodNode["PeriodValue"].isNull()) quotaApplicationsObject.period.periodValue = std::stol(periodNode["PeriodValue"].asString()); diff --git a/quotas/src/model/ModifyQuotaTemplateServiceStatusRequest.cc b/quotas/src/model/ModifyQuotaTemplateServiceStatusRequest.cc new file mode 100644 index 000000000..02b54417f --- /dev/null +++ b/quotas/src/model/ModifyQuotaTemplateServiceStatusRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::ModifyQuotaTemplateServiceStatusRequest; + +ModifyQuotaTemplateServiceStatusRequest::ModifyQuotaTemplateServiceStatusRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ModifyQuotaTemplateServiceStatus") { + setMethod(HttpRequest::Method::Post); +} + +ModifyQuotaTemplateServiceStatusRequest::~ModifyQuotaTemplateServiceStatusRequest() {} + +std::string ModifyQuotaTemplateServiceStatusRequest::getOriginalContext() const { + return originalContext_; +} + +void ModifyQuotaTemplateServiceStatusRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +int ModifyQuotaTemplateServiceStatusRequest::getServiceStatus() const { + return serviceStatus_; +} + +void ModifyQuotaTemplateServiceStatusRequest::setServiceStatus(int serviceStatus) { + serviceStatus_ = serviceStatus; + setBodyParameter(std::string("ServiceStatus"), std::to_string(serviceStatus)); +} + diff --git a/quotas/src/model/ModifyQuotaTemplateServiceStatusResult.cc b/quotas/src/model/ModifyQuotaTemplateServiceStatusResult.cc new file mode 100644 index 000000000..9c5a3faca --- /dev/null +++ b/quotas/src/model/ModifyQuotaTemplateServiceStatusResult.cc @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +ModifyQuotaTemplateServiceStatusResult::ModifyQuotaTemplateServiceStatusResult() : + ServiceResult() +{} + +ModifyQuotaTemplateServiceStatusResult::ModifyQuotaTemplateServiceStatusResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ModifyQuotaTemplateServiceStatusResult::~ModifyQuotaTemplateServiceStatusResult() +{} + +void ModifyQuotaTemplateServiceStatusResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto templateServiceStatusNode = value["TemplateServiceStatus"]; + if(!templateServiceStatusNode["ServiceStatus"].isNull()) + templateServiceStatus_.serviceStatus = std::stoi(templateServiceStatusNode["ServiceStatus"].asString()); + if(!templateServiceStatusNode["ResourceDirectoryId"].isNull()) + templateServiceStatus_.resourceDirectoryId = templateServiceStatusNode["ResourceDirectoryId"].asString(); + +} + +ModifyQuotaTemplateServiceStatusResult::TemplateServiceStatus ModifyQuotaTemplateServiceStatusResult::getTemplateServiceStatus()const +{ + return templateServiceStatus_; +} + diff --git a/quotas/src/model/ModifyTemplateQuotaItemRequest.cc b/quotas/src/model/ModifyTemplateQuotaItemRequest.cc new file mode 100644 index 000000000..c6c1d8f9d --- /dev/null +++ b/quotas/src/model/ModifyTemplateQuotaItemRequest.cc @@ -0,0 +1,131 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::ModifyTemplateQuotaItemRequest; + +ModifyTemplateQuotaItemRequest::ModifyTemplateQuotaItemRequest() + : RpcServiceRequest("quotas", "2020-05-10", "ModifyTemplateQuotaItem") { + setMethod(HttpRequest::Method::Post); +} + +ModifyTemplateQuotaItemRequest::~ModifyTemplateQuotaItemRequest() {} + +std::string ModifyTemplateQuotaItemRequest::getProductCode() const { + return productCode_; +} + +void ModifyTemplateQuotaItemRequest::setProductCode(const std::string &productCode) { + productCode_ = productCode; + setBodyParameter(std::string("ProductCode"), productCode); +} + +std::string ModifyTemplateQuotaItemRequest::getQuotaActionCode() const { + return quotaActionCode_; +} + +void ModifyTemplateQuotaItemRequest::setQuotaActionCode(const std::string "aActionCode) { + quotaActionCode_ = quotaActionCode; + setBodyParameter(std::string("QuotaActionCode"), quotaActionCode); +} + +float ModifyTemplateQuotaItemRequest::getDesireValue() const { + return desireValue_; +} + +void ModifyTemplateQuotaItemRequest::setDesireValue(float desireValue) { + desireValue_ = desireValue; + setBodyParameter(std::string("DesireValue"), std::to_string(desireValue)); +} + +std::string ModifyTemplateQuotaItemRequest::getEffectiveTime() const { + return effectiveTime_; +} + +void ModifyTemplateQuotaItemRequest::setEffectiveTime(const std::string &effectiveTime) { + effectiveTime_ = effectiveTime; + setBodyParameter(std::string("EffectiveTime"), effectiveTime); +} + +std::string ModifyTemplateQuotaItemRequest::getId() const { + return id_; +} + +void ModifyTemplateQuotaItemRequest::setId(const std::string &id) { + id_ = id; + setBodyParameter(std::string("Id"), id); +} + +std::string ModifyTemplateQuotaItemRequest::getQuotaCategory() const { + return quotaCategory_; +} + +void ModifyTemplateQuotaItemRequest::setQuotaCategory(const std::string "aCategory) { + quotaCategory_ = quotaCategory; + setParameter(std::string("QuotaCategory"), quotaCategory); +} + +std::string ModifyTemplateQuotaItemRequest::getOriginalContext() const { + return originalContext_; +} + +void ModifyTemplateQuotaItemRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string ModifyTemplateQuotaItemRequest::getExpireTime() const { + return expireTime_; +} + +void ModifyTemplateQuotaItemRequest::setExpireTime(const std::string &expireTime) { + expireTime_ = expireTime; + setBodyParameter(std::string("ExpireTime"), expireTime); +} + +std::string ModifyTemplateQuotaItemRequest::getEnvLanguage() const { + return envLanguage_; +} + +void ModifyTemplateQuotaItemRequest::setEnvLanguage(const std::string &envLanguage) { + envLanguage_ = envLanguage; + setBodyParameter(std::string("EnvLanguage"), envLanguage); +} + +long ModifyTemplateQuotaItemRequest::getNoticeType() const { + return noticeType_; +} + +void ModifyTemplateQuotaItemRequest::setNoticeType(long noticeType) { + noticeType_ = noticeType; + setBodyParameter(std::string("NoticeType"), std::to_string(noticeType)); +} + +std::vector ModifyTemplateQuotaItemRequest::getDimensions() const { + return dimensions_; +} + +void ModifyTemplateQuotaItemRequest::setDimensions(const std::vector &dimensions) { + dimensions_ = dimensions; + for(int dep1 = 0; dep1 != dimensions.size(); dep1++) { + auto dimensionsObj = dimensions.at(dep1); + std::string dimensionsObjStr = std::string("Dimensions") + "." + std::to_string(dep1 + 1); + setBodyParameter(dimensionsObjStr + ".Key", dimensionsObj.key); + setBodyParameter(dimensionsObjStr + ".Value", dimensionsObj.value); + } +} + diff --git a/quotas/src/model/ModifyTemplateQuotaItemResult.cc b/quotas/src/model/ModifyTemplateQuotaItemResult.cc new file mode 100644 index 000000000..82a3491ba --- /dev/null +++ b/quotas/src/model/ModifyTemplateQuotaItemResult.cc @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +ModifyTemplateQuotaItemResult::ModifyTemplateQuotaItemResult() : + ServiceResult() +{} + +ModifyTemplateQuotaItemResult::ModifyTemplateQuotaItemResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ModifyTemplateQuotaItemResult::~ModifyTemplateQuotaItemResult() +{} + +void ModifyTemplateQuotaItemResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Id"].isNull()) + id_ = value["Id"].asString(); + +} + +std::string ModifyTemplateQuotaItemResult::getId()const +{ + return id_; +} + diff --git a/quotas/src/model/RemindQuotaApplicationApprovalRequest.cc b/quotas/src/model/RemindQuotaApplicationApprovalRequest.cc new file mode 100644 index 000000000..dded811ca --- /dev/null +++ b/quotas/src/model/RemindQuotaApplicationApprovalRequest.cc @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Quotas::Model::RemindQuotaApplicationApprovalRequest; + +RemindQuotaApplicationApprovalRequest::RemindQuotaApplicationApprovalRequest() + : RpcServiceRequest("quotas", "2020-05-10", "RemindQuotaApplicationApproval") { + setMethod(HttpRequest::Method::Post); +} + +RemindQuotaApplicationApprovalRequest::~RemindQuotaApplicationApprovalRequest() {} + +std::string RemindQuotaApplicationApprovalRequest::getOriginalContext() const { + return originalContext_; +} + +void RemindQuotaApplicationApprovalRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); +} + +std::string RemindQuotaApplicationApprovalRequest::getApplicationId() const { + return applicationId_; +} + +void RemindQuotaApplicationApprovalRequest::setApplicationId(const std::string &applicationId) { + applicationId_ = applicationId; + setBodyParameter(std::string("ApplicationId"), applicationId); +} + diff --git a/quotas/src/model/RemindQuotaApplicationApprovalResult.cc b/quotas/src/model/RemindQuotaApplicationApprovalResult.cc new file mode 100644 index 000000000..a2eefbac3 --- /dev/null +++ b/quotas/src/model/RemindQuotaApplicationApprovalResult.cc @@ -0,0 +1,108 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Quotas; +using namespace AlibabaCloud::Quotas::Model; + +RemindQuotaApplicationApprovalResult::RemindQuotaApplicationApprovalResult() : + ServiceResult() +{} + +RemindQuotaApplicationApprovalResult::RemindQuotaApplicationApprovalResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +RemindQuotaApplicationApprovalResult::~RemindQuotaApplicationApprovalResult() +{} + +void RemindQuotaApplicationApprovalResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allErrorArgs = value["ErrorArgs"]["ErrorArg"]; + for (const auto &item : allErrorArgs) + errorArgs_.push_back(item.asString()); + if(!value["HttpStatusCode"].isNull()) + httpStatusCode_ = std::stoi(value["HttpStatusCode"].asString()); + if(!value["DynamicCode"].isNull()) + dynamicCode_ = value["DynamicCode"].asString(); + if(!value["DynamicMessage"].isNull()) + dynamicMessage_ = value["DynamicMessage"].asString(); + if(!value["ErrorMsg"].isNull()) + errorMsg_ = value["ErrorMsg"].asString(); + if(!value["ErrorCode"].isNull()) + errorCode_ = value["ErrorCode"].asString(); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Module"].isNull()) + module_ = value["Module"].asString(); + if(!value["AllowRetry"].isNull()) + allowRetry_ = value["AllowRetry"].asString() == "true"; + +} + +bool RemindQuotaApplicationApprovalResult::getAllowRetry()const +{ + return allowRetry_; +} + +std::vector RemindQuotaApplicationApprovalResult::getErrorArgs()const +{ + return errorArgs_; +} + +int RemindQuotaApplicationApprovalResult::getHttpStatusCode()const +{ + return httpStatusCode_; +} + +std::string RemindQuotaApplicationApprovalResult::getErrorMsg()const +{ + return errorMsg_; +} + +std::string RemindQuotaApplicationApprovalResult::getDynamicCode()const +{ + return dynamicCode_; +} + +std::string RemindQuotaApplicationApprovalResult::getDynamicMessage()const +{ + return dynamicMessage_; +} + +std::string RemindQuotaApplicationApprovalResult::getErrorCode()const +{ + return errorCode_; +} + +std::string RemindQuotaApplicationApprovalResult::getModule()const +{ + return module_; +} + +bool RemindQuotaApplicationApprovalResult::getSuccess()const +{ + return success_; +} + diff --git a/quotas/src/model/UpdateQuotaAlarmRequest.cc b/quotas/src/model/UpdateQuotaAlarmRequest.cc index 4509465b3..4b08d7409 100644 --- a/quotas/src/model/UpdateQuotaAlarmRequest.cc +++ b/quotas/src/model/UpdateQuotaAlarmRequest.cc @@ -1,95 +1,90 @@ /* * Copyright 2009-2017 Alibaba Cloud All rights reserved. - * + * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at - * + * * http://www.apache.org/licenses/LICENSE-2.0 - * + * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. - */ - -#include - -using AlibabaCloud::Quotas::Model::UpdateQuotaAlarmRequest; - -UpdateQuotaAlarmRequest::UpdateQuotaAlarmRequest() : - RpcServiceRequest("quotas", "2020-05-10", "UpdateQuotaAlarm") -{ - setMethod(HttpRequest::Method::Post); -} - -UpdateQuotaAlarmRequest::~UpdateQuotaAlarmRequest() -{} - -std::string UpdateQuotaAlarmRequest::getWebHook()const -{ - return webHook_; + */ + +#include + +using AlibabaCloud::Quotas::Model::UpdateQuotaAlarmRequest; + +UpdateQuotaAlarmRequest::UpdateQuotaAlarmRequest() + : RpcServiceRequest("quotas", "2020-05-10", "UpdateQuotaAlarm") { + setMethod(HttpRequest::Method::Post); } -void UpdateQuotaAlarmRequest::setWebHook(const std::string& webHook) -{ - webHook_ = webHook; - setBodyParameter("WebHook", webHook); +UpdateQuotaAlarmRequest::~UpdateQuotaAlarmRequest() {} + +std::string UpdateQuotaAlarmRequest::getWebHook() const { + return webHook_; } -float UpdateQuotaAlarmRequest::getThreshold()const -{ - return threshold_; +void UpdateQuotaAlarmRequest::setWebHook(const std::string &webHook) { + webHook_ = webHook; + setBodyParameter(std::string("WebHook"), webHook); } -void UpdateQuotaAlarmRequest::setThreshold(float threshold) -{ - threshold_ = threshold; - setBodyParameter("Threshold", std::to_string(threshold)); +float UpdateQuotaAlarmRequest::getThreshold() const { + return threshold_; } -std::string UpdateQuotaAlarmRequest::getThresholdType()const -{ - return thresholdType_; +void UpdateQuotaAlarmRequest::setThreshold(float threshold) { + threshold_ = threshold; + setBodyParameter(std::string("Threshold"), std::to_string(threshold)); } -void UpdateQuotaAlarmRequest::setThresholdType(const std::string& thresholdType) -{ - thresholdType_ = thresholdType; - setBodyParameter("ThresholdType", thresholdType); +std::string UpdateQuotaAlarmRequest::getThresholdType() const { + return thresholdType_; } -float UpdateQuotaAlarmRequest::getThresholdPercent()const -{ - return thresholdPercent_; +void UpdateQuotaAlarmRequest::setThresholdType(const std::string &thresholdType) { + thresholdType_ = thresholdType; + setBodyParameter(std::string("ThresholdType"), thresholdType); } -void UpdateQuotaAlarmRequest::setThresholdPercent(float thresholdPercent) -{ - thresholdPercent_ = thresholdPercent; - setBodyParameter("ThresholdPercent", std::to_string(thresholdPercent)); +std::string UpdateQuotaAlarmRequest::getOriginalContext() const { + return originalContext_; } -std::string UpdateQuotaAlarmRequest::getAlarmId()const -{ - return alarmId_; +void UpdateQuotaAlarmRequest::setOriginalContext(const std::string &originalContext) { + originalContext_ = originalContext; + setBodyParameter(std::string("OriginalContext"), originalContext); } -void UpdateQuotaAlarmRequest::setAlarmId(const std::string& alarmId) -{ - alarmId_ = alarmId; - setBodyParameter("AlarmId", alarmId); +float UpdateQuotaAlarmRequest::getThresholdPercent() const { + return thresholdPercent_; } -std::string UpdateQuotaAlarmRequest::getAlarmName()const -{ - return alarmName_; +void UpdateQuotaAlarmRequest::setThresholdPercent(float thresholdPercent) { + thresholdPercent_ = thresholdPercent; + setBodyParameter(std::string("ThresholdPercent"), std::to_string(thresholdPercent)); } -void UpdateQuotaAlarmRequest::setAlarmName(const std::string& alarmName) -{ - alarmName_ = alarmName; - setBodyParameter("AlarmName", alarmName); +std::string UpdateQuotaAlarmRequest::getAlarmId() const { + return alarmId_; +} + +void UpdateQuotaAlarmRequest::setAlarmId(const std::string &alarmId) { + alarmId_ = alarmId; + setBodyParameter(std::string("AlarmId"), alarmId); +} + +std::string UpdateQuotaAlarmRequest::getAlarmName() const { + return alarmName_; +} + +void UpdateQuotaAlarmRequest::setAlarmName(const std::string &alarmName) { + alarmName_ = alarmName; + setBodyParameter(std::string("AlarmName"), alarmName); }