diff --git a/CHANGELOG b/CHANGELOG index c6a8be4f1..c89056055 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +2022-08-02 Version: 1.36.1216 +- Support ecs instance diagnostic features. + 2022-08-01 Version: 1.36.1215 - Update CreateKey and CreateSecret. diff --git a/VERSION b/VERSION index 81c724b46..d22f0efe7 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.36.1215 \ No newline at end of file +1.36.1216 \ No newline at end of file diff --git a/ecs/CMakeLists.txt b/ecs/CMakeLists.txt index 358e00fdb..3641ec8d8 100644 --- a/ecs/CMakeLists.txt +++ b/ecs/CMakeLists.txt @@ -97,6 +97,10 @@ set(ecs_public_header_model include/alibabacloud/ecs/model/CreateDemandResult.h include/alibabacloud/ecs/model/CreateDeploymentSetRequest.h include/alibabacloud/ecs/model/CreateDeploymentSetResult.h + include/alibabacloud/ecs/model/CreateDiagnosticMetricSetRequest.h + include/alibabacloud/ecs/model/CreateDiagnosticMetricSetResult.h + include/alibabacloud/ecs/model/CreateDiagnosticReportRequest.h + include/alibabacloud/ecs/model/CreateDiagnosticReportResult.h include/alibabacloud/ecs/model/CreateDiskRequest.h include/alibabacloud/ecs/model/CreateDiskResult.h include/alibabacloud/ecs/model/CreateElasticityAssuranceRequest.h @@ -169,6 +173,10 @@ set(ecs_public_header_model include/alibabacloud/ecs/model/DeleteDemandResult.h include/alibabacloud/ecs/model/DeleteDeploymentSetRequest.h include/alibabacloud/ecs/model/DeleteDeploymentSetResult.h + include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsRequest.h + include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsResult.h + include/alibabacloud/ecs/model/DeleteDiagnosticReportsRequest.h + include/alibabacloud/ecs/model/DeleteDiagnosticReportsResult.h include/alibabacloud/ecs/model/DeleteDiskRequest.h include/alibabacloud/ecs/model/DeleteDiskResult.h include/alibabacloud/ecs/model/DeleteForwardEntryRequest.h @@ -271,6 +279,12 @@ set(ecs_public_header_model include/alibabacloud/ecs/model/DescribeDeploymentSetSupportedInstanceTypeFamilyResult.h include/alibabacloud/ecs/model/DescribeDeploymentSetsRequest.h include/alibabacloud/ecs/model/DescribeDeploymentSetsResult.h + include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsRequest.h + include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsResult.h + include/alibabacloud/ecs/model/DescribeDiagnosticMetricsRequest.h + include/alibabacloud/ecs/model/DescribeDiagnosticMetricsResult.h + include/alibabacloud/ecs/model/DescribeDiagnosticReportsRequest.h + include/alibabacloud/ecs/model/DescribeDiagnosticReportsResult.h include/alibabacloud/ecs/model/DescribeDiskMonitorDataRequest.h include/alibabacloud/ecs/model/DescribeDiskMonitorDataResult.h include/alibabacloud/ecs/model/DescribeDisksRequest.h @@ -513,6 +527,8 @@ set(ecs_public_header_model include/alibabacloud/ecs/model/ModifyDemandResult.h include/alibabacloud/ecs/model/ModifyDeploymentSetAttributeRequest.h include/alibabacloud/ecs/model/ModifyDeploymentSetAttributeResult.h + include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetRequest.h + include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetResult.h include/alibabacloud/ecs/model/ModifyDiskAttributeRequest.h include/alibabacloud/ecs/model/ModifyDiskAttributeResult.h include/alibabacloud/ecs/model/ModifyDiskChargeTypeRequest.h @@ -770,6 +786,10 @@ set(ecs_src src/model/CreateDemandResult.cc src/model/CreateDeploymentSetRequest.cc src/model/CreateDeploymentSetResult.cc + src/model/CreateDiagnosticMetricSetRequest.cc + src/model/CreateDiagnosticMetricSetResult.cc + src/model/CreateDiagnosticReportRequest.cc + src/model/CreateDiagnosticReportResult.cc src/model/CreateDiskRequest.cc src/model/CreateDiskResult.cc src/model/CreateElasticityAssuranceRequest.cc @@ -842,6 +862,10 @@ set(ecs_src src/model/DeleteDemandResult.cc src/model/DeleteDeploymentSetRequest.cc src/model/DeleteDeploymentSetResult.cc + src/model/DeleteDiagnosticMetricSetsRequest.cc + src/model/DeleteDiagnosticMetricSetsResult.cc + src/model/DeleteDiagnosticReportsRequest.cc + src/model/DeleteDiagnosticReportsResult.cc src/model/DeleteDiskRequest.cc src/model/DeleteDiskResult.cc src/model/DeleteForwardEntryRequest.cc @@ -944,6 +968,12 @@ set(ecs_src src/model/DescribeDeploymentSetSupportedInstanceTypeFamilyResult.cc src/model/DescribeDeploymentSetsRequest.cc src/model/DescribeDeploymentSetsResult.cc + src/model/DescribeDiagnosticMetricSetsRequest.cc + src/model/DescribeDiagnosticMetricSetsResult.cc + src/model/DescribeDiagnosticMetricsRequest.cc + src/model/DescribeDiagnosticMetricsResult.cc + src/model/DescribeDiagnosticReportsRequest.cc + src/model/DescribeDiagnosticReportsResult.cc src/model/DescribeDiskMonitorDataRequest.cc src/model/DescribeDiskMonitorDataResult.cc src/model/DescribeDisksRequest.cc @@ -1186,6 +1216,8 @@ set(ecs_src src/model/ModifyDemandResult.cc src/model/ModifyDeploymentSetAttributeRequest.cc src/model/ModifyDeploymentSetAttributeResult.cc + src/model/ModifyDiagnosticMetricSetRequest.cc + src/model/ModifyDiagnosticMetricSetResult.cc src/model/ModifyDiskAttributeRequest.cc src/model/ModifyDiskAttributeResult.cc src/model/ModifyDiskChargeTypeRequest.cc diff --git a/ecs/include/alibabacloud/ecs/EcsClient.h b/ecs/include/alibabacloud/ecs/EcsClient.h index d7823066e..2eb1815bd 100644 --- a/ecs/include/alibabacloud/ecs/EcsClient.h +++ b/ecs/include/alibabacloud/ecs/EcsClient.h @@ -98,6 +98,10 @@ #include "model/CreateDemandResult.h" #include "model/CreateDeploymentSetRequest.h" #include "model/CreateDeploymentSetResult.h" +#include "model/CreateDiagnosticMetricSetRequest.h" +#include "model/CreateDiagnosticMetricSetResult.h" +#include "model/CreateDiagnosticReportRequest.h" +#include "model/CreateDiagnosticReportResult.h" #include "model/CreateDiskRequest.h" #include "model/CreateDiskResult.h" #include "model/CreateElasticityAssuranceRequest.h" @@ -170,6 +174,10 @@ #include "model/DeleteDemandResult.h" #include "model/DeleteDeploymentSetRequest.h" #include "model/DeleteDeploymentSetResult.h" +#include "model/DeleteDiagnosticMetricSetsRequest.h" +#include "model/DeleteDiagnosticMetricSetsResult.h" +#include "model/DeleteDiagnosticReportsRequest.h" +#include "model/DeleteDiagnosticReportsResult.h" #include "model/DeleteDiskRequest.h" #include "model/DeleteDiskResult.h" #include "model/DeleteForwardEntryRequest.h" @@ -272,6 +280,12 @@ #include "model/DescribeDeploymentSetSupportedInstanceTypeFamilyResult.h" #include "model/DescribeDeploymentSetsRequest.h" #include "model/DescribeDeploymentSetsResult.h" +#include "model/DescribeDiagnosticMetricSetsRequest.h" +#include "model/DescribeDiagnosticMetricSetsResult.h" +#include "model/DescribeDiagnosticMetricsRequest.h" +#include "model/DescribeDiagnosticMetricsResult.h" +#include "model/DescribeDiagnosticReportsRequest.h" +#include "model/DescribeDiagnosticReportsResult.h" #include "model/DescribeDiskMonitorDataRequest.h" #include "model/DescribeDiskMonitorDataResult.h" #include "model/DescribeDisksRequest.h" @@ -514,6 +528,8 @@ #include "model/ModifyDemandResult.h" #include "model/ModifyDeploymentSetAttributeRequest.h" #include "model/ModifyDeploymentSetAttributeResult.h" +#include "model/ModifyDiagnosticMetricSetRequest.h" +#include "model/ModifyDiagnosticMetricSetResult.h" #include "model/ModifyDiskAttributeRequest.h" #include "model/ModifyDiskAttributeResult.h" #include "model/ModifyDiskChargeTypeRequest.h" @@ -815,6 +831,12 @@ namespace AlibabaCloud typedef Outcome CreateDeploymentSetOutcome; typedef std::future CreateDeploymentSetOutcomeCallable; typedef std::function&)> CreateDeploymentSetAsyncHandler; + typedef Outcome CreateDiagnosticMetricSetOutcome; + typedef std::future CreateDiagnosticMetricSetOutcomeCallable; + typedef std::function&)> CreateDiagnosticMetricSetAsyncHandler; + typedef Outcome CreateDiagnosticReportOutcome; + typedef std::future CreateDiagnosticReportOutcomeCallable; + typedef std::function&)> CreateDiagnosticReportAsyncHandler; typedef Outcome CreateDiskOutcome; typedef std::future CreateDiskOutcomeCallable; typedef std::function&)> CreateDiskAsyncHandler; @@ -923,6 +945,12 @@ namespace AlibabaCloud typedef Outcome DeleteDeploymentSetOutcome; typedef std::future DeleteDeploymentSetOutcomeCallable; typedef std::function&)> DeleteDeploymentSetAsyncHandler; + typedef Outcome DeleteDiagnosticMetricSetsOutcome; + typedef std::future DeleteDiagnosticMetricSetsOutcomeCallable; + typedef std::function&)> DeleteDiagnosticMetricSetsAsyncHandler; + typedef Outcome DeleteDiagnosticReportsOutcome; + typedef std::future DeleteDiagnosticReportsOutcomeCallable; + typedef std::function&)> DeleteDiagnosticReportsAsyncHandler; typedef Outcome DeleteDiskOutcome; typedef std::future DeleteDiskOutcomeCallable; typedef std::function&)> DeleteDiskAsyncHandler; @@ -1076,6 +1104,15 @@ namespace AlibabaCloud typedef Outcome DescribeDeploymentSetsOutcome; typedef std::future DescribeDeploymentSetsOutcomeCallable; typedef std::function&)> DescribeDeploymentSetsAsyncHandler; + typedef Outcome DescribeDiagnosticMetricSetsOutcome; + typedef std::future DescribeDiagnosticMetricSetsOutcomeCallable; + typedef std::function&)> DescribeDiagnosticMetricSetsAsyncHandler; + typedef Outcome DescribeDiagnosticMetricsOutcome; + typedef std::future DescribeDiagnosticMetricsOutcomeCallable; + typedef std::function&)> DescribeDiagnosticMetricsAsyncHandler; + typedef Outcome DescribeDiagnosticReportsOutcome; + typedef std::future DescribeDiagnosticReportsOutcomeCallable; + typedef std::function&)> DescribeDiagnosticReportsAsyncHandler; typedef Outcome DescribeDiskMonitorDataOutcome; typedef std::future DescribeDiskMonitorDataOutcomeCallable; typedef std::function&)> DescribeDiskMonitorDataAsyncHandler; @@ -1439,6 +1476,9 @@ namespace AlibabaCloud typedef Outcome ModifyDeploymentSetAttributeOutcome; typedef std::future ModifyDeploymentSetAttributeOutcomeCallable; typedef std::function&)> ModifyDeploymentSetAttributeAsyncHandler; + typedef Outcome ModifyDiagnosticMetricSetOutcome; + typedef std::future ModifyDiagnosticMetricSetOutcomeCallable; + typedef std::function&)> ModifyDiagnosticMetricSetAsyncHandler; typedef Outcome ModifyDiskAttributeOutcome; typedef std::future ModifyDiskAttributeOutcomeCallable; typedef std::function&)> ModifyDiskAttributeAsyncHandler; @@ -1825,6 +1865,12 @@ namespace AlibabaCloud CreateDeploymentSetOutcome createDeploymentSet(const Model::CreateDeploymentSetRequest &request)const; void createDeploymentSetAsync(const Model::CreateDeploymentSetRequest& request, const CreateDeploymentSetAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateDeploymentSetOutcomeCallable createDeploymentSetCallable(const Model::CreateDeploymentSetRequest& request) const; + CreateDiagnosticMetricSetOutcome createDiagnosticMetricSet(const Model::CreateDiagnosticMetricSetRequest &request)const; + void createDiagnosticMetricSetAsync(const Model::CreateDiagnosticMetricSetRequest& request, const CreateDiagnosticMetricSetAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateDiagnosticMetricSetOutcomeCallable createDiagnosticMetricSetCallable(const Model::CreateDiagnosticMetricSetRequest& request) const; + CreateDiagnosticReportOutcome createDiagnosticReport(const Model::CreateDiagnosticReportRequest &request)const; + void createDiagnosticReportAsync(const Model::CreateDiagnosticReportRequest& request, const CreateDiagnosticReportAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateDiagnosticReportOutcomeCallable createDiagnosticReportCallable(const Model::CreateDiagnosticReportRequest& request) const; CreateDiskOutcome createDisk(const Model::CreateDiskRequest &request)const; void createDiskAsync(const Model::CreateDiskRequest& request, const CreateDiskAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateDiskOutcomeCallable createDiskCallable(const Model::CreateDiskRequest& request) const; @@ -1933,6 +1979,12 @@ namespace AlibabaCloud DeleteDeploymentSetOutcome deleteDeploymentSet(const Model::DeleteDeploymentSetRequest &request)const; void deleteDeploymentSetAsync(const Model::DeleteDeploymentSetRequest& request, const DeleteDeploymentSetAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DeleteDeploymentSetOutcomeCallable deleteDeploymentSetCallable(const Model::DeleteDeploymentSetRequest& request) const; + DeleteDiagnosticMetricSetsOutcome deleteDiagnosticMetricSets(const Model::DeleteDiagnosticMetricSetsRequest &request)const; + void deleteDiagnosticMetricSetsAsync(const Model::DeleteDiagnosticMetricSetsRequest& request, const DeleteDiagnosticMetricSetsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteDiagnosticMetricSetsOutcomeCallable deleteDiagnosticMetricSetsCallable(const Model::DeleteDiagnosticMetricSetsRequest& request) const; + DeleteDiagnosticReportsOutcome deleteDiagnosticReports(const Model::DeleteDiagnosticReportsRequest &request)const; + void deleteDiagnosticReportsAsync(const Model::DeleteDiagnosticReportsRequest& request, const DeleteDiagnosticReportsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteDiagnosticReportsOutcomeCallable deleteDiagnosticReportsCallable(const Model::DeleteDiagnosticReportsRequest& request) const; DeleteDiskOutcome deleteDisk(const Model::DeleteDiskRequest &request)const; void deleteDiskAsync(const Model::DeleteDiskRequest& request, const DeleteDiskAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DeleteDiskOutcomeCallable deleteDiskCallable(const Model::DeleteDiskRequest& request) const; @@ -2086,6 +2138,15 @@ namespace AlibabaCloud DescribeDeploymentSetsOutcome describeDeploymentSets(const Model::DescribeDeploymentSetsRequest &request)const; void describeDeploymentSetsAsync(const Model::DescribeDeploymentSetsRequest& request, const DescribeDeploymentSetsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DescribeDeploymentSetsOutcomeCallable describeDeploymentSetsCallable(const Model::DescribeDeploymentSetsRequest& request) const; + DescribeDiagnosticMetricSetsOutcome describeDiagnosticMetricSets(const Model::DescribeDiagnosticMetricSetsRequest &request)const; + void describeDiagnosticMetricSetsAsync(const Model::DescribeDiagnosticMetricSetsRequest& request, const DescribeDiagnosticMetricSetsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeDiagnosticMetricSetsOutcomeCallable describeDiagnosticMetricSetsCallable(const Model::DescribeDiagnosticMetricSetsRequest& request) const; + DescribeDiagnosticMetricsOutcome describeDiagnosticMetrics(const Model::DescribeDiagnosticMetricsRequest &request)const; + void describeDiagnosticMetricsAsync(const Model::DescribeDiagnosticMetricsRequest& request, const DescribeDiagnosticMetricsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeDiagnosticMetricsOutcomeCallable describeDiagnosticMetricsCallable(const Model::DescribeDiagnosticMetricsRequest& request) const; + DescribeDiagnosticReportsOutcome describeDiagnosticReports(const Model::DescribeDiagnosticReportsRequest &request)const; + void describeDiagnosticReportsAsync(const Model::DescribeDiagnosticReportsRequest& request, const DescribeDiagnosticReportsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeDiagnosticReportsOutcomeCallable describeDiagnosticReportsCallable(const Model::DescribeDiagnosticReportsRequest& request) const; DescribeDiskMonitorDataOutcome describeDiskMonitorData(const Model::DescribeDiskMonitorDataRequest &request)const; void describeDiskMonitorDataAsync(const Model::DescribeDiskMonitorDataRequest& request, const DescribeDiskMonitorDataAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DescribeDiskMonitorDataOutcomeCallable describeDiskMonitorDataCallable(const Model::DescribeDiskMonitorDataRequest& request) const; @@ -2449,6 +2510,9 @@ namespace AlibabaCloud ModifyDeploymentSetAttributeOutcome modifyDeploymentSetAttribute(const Model::ModifyDeploymentSetAttributeRequest &request)const; void modifyDeploymentSetAttributeAsync(const Model::ModifyDeploymentSetAttributeRequest& request, const ModifyDeploymentSetAttributeAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; ModifyDeploymentSetAttributeOutcomeCallable modifyDeploymentSetAttributeCallable(const Model::ModifyDeploymentSetAttributeRequest& request) const; + ModifyDiagnosticMetricSetOutcome modifyDiagnosticMetricSet(const Model::ModifyDiagnosticMetricSetRequest &request)const; + void modifyDiagnosticMetricSetAsync(const Model::ModifyDiagnosticMetricSetRequest& request, const ModifyDiagnosticMetricSetAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ModifyDiagnosticMetricSetOutcomeCallable modifyDiagnosticMetricSetCallable(const Model::ModifyDiagnosticMetricSetRequest& request) const; ModifyDiskAttributeOutcome modifyDiskAttribute(const Model::ModifyDiskAttributeRequest &request)const; void modifyDiskAttributeAsync(const Model::ModifyDiskAttributeRequest& request, const ModifyDiskAttributeAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; ModifyDiskAttributeOutcomeCallable modifyDiskAttributeCallable(const Model::ModifyDiskAttributeRequest& request) const; diff --git a/ecs/include/alibabacloud/ecs/model/CreateDiagnosticMetricSetRequest.h b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticMetricSetRequest.h new file mode 100644 index 000000000..f41a0ddbd --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticMetricSetRequest.h @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICMETRICSETREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICMETRICSETREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT CreateDiagnosticMetricSetRequest : public RpcServiceRequest { +public: + CreateDiagnosticMetricSetRequest(); + ~CreateDiagnosticMetricSetRequest(); + std::vector getMetricIds() const; + void setMetricIds(const std::vector &metricIds); + std::string getDescription() const; + void setDescription(const std::string &description); + std::string getMetricSetName() const; + void setMetricSetName(const std::string &metricSetName); + std::string getResourceType() const; + void setResourceType(const std::string &resourceType); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + +private: + std::vector metricIds_; + std::string description_; + std::string metricSetName_; + std::string resourceType_; + std::string regionId_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICMETRICSETREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/CreateDiagnosticMetricSetResult.h b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticMetricSetResult.h new file mode 100644 index 000000000..80e8bc7b0 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticMetricSetResult.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_ECS_MODEL_CREATEDIAGNOSTICMETRICSETRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICMETRICSETRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT CreateDiagnosticMetricSetResult : public ServiceResult + { + public: + + + CreateDiagnosticMetricSetResult(); + explicit CreateDiagnosticMetricSetResult(const std::string &payload); + ~CreateDiagnosticMetricSetResult(); + std::string getMetricSetId()const; + + protected: + void parse(const std::string &payload); + private: + std::string metricSetId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICMETRICSETRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/CreateDiagnosticReportRequest.h b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticReportRequest.h new file mode 100644 index 000000000..712c72c63 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticReportRequest.h @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICREPORTREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICREPORTREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT CreateDiagnosticReportRequest : public RpcServiceRequest { +public: + CreateDiagnosticReportRequest(); + ~CreateDiagnosticReportRequest(); + std::string getResourceId() const; + void setResourceId(const std::string &resourceId); + std::string getMetricSetId() const; + void setMetricSetId(const std::string &metricSetId); + std::string getEndTime() const; + void setEndTime(const std::string &endTime); + std::string getStartTime() const; + void setStartTime(const std::string &startTime); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + +private: + std::string resourceId_; + std::string metricSetId_; + std::string endTime_; + std::string startTime_; + std::string regionId_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICREPORTREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/CreateDiagnosticReportResult.h b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticReportResult.h new file mode 100644 index 000000000..f04c4af3b --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/CreateDiagnosticReportResult.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_ECS_MODEL_CREATEDIAGNOSTICREPORTRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICREPORTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT CreateDiagnosticReportResult : public ServiceResult + { + public: + + + CreateDiagnosticReportResult(); + explicit CreateDiagnosticReportResult(const std::string &payload); + ~CreateDiagnosticReportResult(); + std::string getReportId()const; + + protected: + void parse(const std::string &payload); + private: + std::string reportId_; + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_CREATEDIAGNOSTICREPORTRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsRequest.h b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsRequest.h new file mode 100644 index 000000000..a6df9d5b7 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsRequest.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_ECS_MODEL_DELETEDIAGNOSTICMETRICSETSREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICMETRICSETSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT DeleteDiagnosticMetricSetsRequest : public RpcServiceRequest { +public: + DeleteDiagnosticMetricSetsRequest(); + ~DeleteDiagnosticMetricSetsRequest(); + std::vector getMetricSetIds() const; + void setMetricSetIds(const std::vector &metricSetIds); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + +private: + std::vector metricSetIds_; + std::string regionId_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICMETRICSETSREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsResult.h b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsResult.h new file mode 100644 index 000000000..16fe6c840 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticMetricSetsResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICMETRICSETSRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICMETRICSETSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT DeleteDiagnosticMetricSetsResult : public ServiceResult + { + public: + + + DeleteDiagnosticMetricSetsResult(); + explicit DeleteDiagnosticMetricSetsResult(const std::string &payload); + ~DeleteDiagnosticMetricSetsResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICMETRICSETSRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticReportsRequest.h b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticReportsRequest.h new file mode 100644 index 000000000..8474178a2 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticReportsRequest.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_ECS_MODEL_DELETEDIAGNOSTICREPORTSREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICREPORTSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT DeleteDiagnosticReportsRequest : public RpcServiceRequest { +public: + DeleteDiagnosticReportsRequest(); + ~DeleteDiagnosticReportsRequest(); + std::vector getReportIds() const; + void setReportIds(const std::vector &reportIds); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + +private: + std::vector reportIds_; + std::string regionId_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICREPORTSREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticReportsResult.h b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticReportsResult.h new file mode 100644 index 000000000..69f9e5c22 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DeleteDiagnosticReportsResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICREPORTSRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICREPORTSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT DeleteDiagnosticReportsResult : public ServiceResult + { + public: + + + DeleteDiagnosticReportsResult(); + explicit DeleteDiagnosticReportsResult(const std::string &payload); + ~DeleteDiagnosticReportsResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_DELETEDIAGNOSTICREPORTSRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/DescribeCommandsRequest.h b/ecs/include/alibabacloud/ecs/model/DescribeCommandsRequest.h index 04a082d27..9f018ce57 100644 --- a/ecs/include/alibabacloud/ecs/model/DescribeCommandsRequest.h +++ b/ecs/include/alibabacloud/ecs/model/DescribeCommandsRequest.h @@ -28,6 +28,10 @@ namespace Ecs { namespace Model { class ALIBABACLOUD_ECS_EXPORT DescribeCommandsRequest : public RpcServiceRequest { public: + struct Tag { + std::string key; + std::string value; + }; DescribeCommandsRequest(); ~DescribeCommandsRequest(); long getResourceOwnerId() const; @@ -48,6 +52,8 @@ public: void setContentEncoding(const std::string &contentEncoding); long getPageSize() const; void setPageSize(long pageSize); + std::vector getTag() const; + void setTag(const std::vector &tag); bool getLatest() const; void setLatest(bool latest); std::string getResourceOwnerAccount() const; @@ -69,6 +75,7 @@ private: std::string provider_; std::string contentEncoding_; long pageSize_; + std::vector tag_; bool latest_; std::string resourceOwnerAccount_; std::string ownerAccount_; diff --git a/ecs/include/alibabacloud/ecs/model/DescribeCommandsResult.h b/ecs/include/alibabacloud/ecs/model/DescribeCommandsResult.h index 6a2e5c676..7d1873905 100644 --- a/ecs/include/alibabacloud/ecs/model/DescribeCommandsResult.h +++ b/ecs/include/alibabacloud/ecs/model/DescribeCommandsResult.h @@ -42,6 +42,11 @@ namespace AlibabaCloud std::string parameterName; std::vector possibleValues; }; + struct Tag + { + std::string tagKey; + std::string tagValue; + }; std::vector parameterDefinitions; std::string description; std::string category; @@ -58,6 +63,7 @@ namespace AlibabaCloud bool latest; bool enableParameter; std::string commandId; + std::vector tags; }; diff --git a/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsRequest.h b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsRequest.h new file mode 100644 index 000000000..d6741d894 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsRequest.h @@ -0,0 +1,57 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSETSREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSETSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT DescribeDiagnosticMetricSetsRequest : public RpcServiceRequest { +public: + DescribeDiagnosticMetricSetsRequest(); + ~DescribeDiagnosticMetricSetsRequest(); + std::vector getMetricSetIds() const; + void setMetricSetIds(const std::vector &metricSetIds); + std::string getType() const; + void setType(const std::string &type); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getResourceType() const; + void setResourceType(const std::string &resourceType); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::vector metricSetIds_; + std::string type_; + std::string regionId_; + std::string nextToken_; + std::string resourceType_; + int maxResults_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSETSREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsResult.h b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsResult.h new file mode 100644 index 000000000..58b3e3f2a --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricSetsResult.h @@ -0,0 +1,62 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSETSRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSETSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT DescribeDiagnosticMetricSetsResult : public ServiceResult + { + public: + struct MetricSet + { + std::string type; + std::string description; + std::vector metricIds; + std::string metricSetId; + std::string resourceType; + std::string metricSetName; + }; + + + DescribeDiagnosticMetricSetsResult(); + explicit DescribeDiagnosticMetricSetsResult(const std::string &payload); + ~DescribeDiagnosticMetricSetsResult(); + std::string getNextToken()const; + std::vector getMetricSets()const; + + protected: + void parse(const std::string &payload); + private: + std::string nextToken_; + std::vector metricSets_; + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSETSRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricsRequest.h b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricsRequest.h new file mode 100644 index 000000000..10691cb68 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricsRequest.h @@ -0,0 +1,54 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT DescribeDiagnosticMetricsRequest : public RpcServiceRequest { +public: + DescribeDiagnosticMetricsRequest(); + ~DescribeDiagnosticMetricsRequest(); + std::vector getMetricIds() const; + void setMetricIds(const std::vector &metricIds); + std::string getResourceType() const; + void setResourceType(const std::string &resourceType); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + int getMaxResults() const; + void setMaxResults(int maxResults); + +private: + std::vector metricIds_; + std::string resourceType_; + std::string regionId_; + std::string nextToken_; + int maxResults_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricsResult.h b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricsResult.h new file mode 100644 index 000000000..48aec6017 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticMetricsResult.h @@ -0,0 +1,63 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT DescribeDiagnosticMetricsResult : public ServiceResult + { + public: + struct Metric + { + std::string metricName; + std::string metricId; + std::string description; + std::string resourceType; + bool guestMetric; + std::string supportedOperatingSystem; + std::string metricCategory; + }; + + + DescribeDiagnosticMetricsResult(); + explicit DescribeDiagnosticMetricsResult(const std::string &payload); + ~DescribeDiagnosticMetricsResult(); + std::vector getMetrics()const; + std::string getNextToken()const; + + protected: + void parse(const std::string &payload); + private: + std::vector metrics_; + std::string nextToken_; + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICMETRICSRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticReportsRequest.h b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticReportsRequest.h new file mode 100644 index 000000000..c18d8d232 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticReportsRequest.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_ECS_MODEL_DESCRIBEDIAGNOSTICREPORTSREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICREPORTSREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT DescribeDiagnosticReportsRequest : public RpcServiceRequest { +public: + DescribeDiagnosticReportsRequest(); + ~DescribeDiagnosticReportsRequest(); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getNextToken() const; + void setNextToken(const std::string &nextToken); + std::string getSeverity() const; + void setSeverity(const std::string &severity); + std::vector getReportIds() const; + void setReportIds(const std::vector &reportIds); + int getMaxResults() const; + void setMaxResults(int maxResults); + std::string getStatus() const; + void setStatus(const std::string &status); + std::vector getResourceIds() const; + void setResourceIds(const std::vector &resourceIds); + +private: + std::string regionId_; + std::string nextToken_; + std::string severity_; + std::vector reportIds_; + int maxResults_; + std::string status_; + std::vector resourceIds_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICREPORTSREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticReportsResult.h b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticReportsResult.h new file mode 100644 index 000000000..f76ea95c8 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/DescribeDiagnosticReportsResult.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_ECS_MODEL_DESCRIBEDIAGNOSTICREPORTSRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICREPORTSRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT DescribeDiagnosticReportsResult : public ServiceResult + { + public: + struct Report + { + struct Issue + { + std::string metricId; + std::string severity; + std::string issueId; + std::string metricCategory; + }; + std::string status; + std::string endTime; + std::string resourceId; + std::vector issues; + std::string metricSetId; + std::string startTime; + std::string creationTime; + std::string reportId; + std::string resourceType; + std::string severity; + std::string finishedTime; + }; + + + DescribeDiagnosticReportsResult(); + explicit DescribeDiagnosticReportsResult(const std::string &payload); + ~DescribeDiagnosticReportsResult(); + std::string getNextToken()const; + std::vector getReports()const; + + protected: + void parse(const std::string &payload); + private: + std::string nextToken_; + std::vector reports_; + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_DESCRIBEDIAGNOSTICREPORTSRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsRequest.h b/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsRequest.h index 05e78da32..aef6b746a 100644 --- a/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsRequest.h +++ b/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsRequest.h @@ -28,6 +28,10 @@ namespace Ecs { namespace Model { class ALIBABACLOUD_ECS_EXPORT DescribeInvocationResultsRequest : public RpcServiceRequest { public: + struct Tag { + std::string key; + std::string value; + }; DescribeInvocationResultsRequest(); ~DescribeInvocationResultsRequest(); long getResourceOwnerId() const; @@ -42,6 +46,8 @@ public: void setContentEncoding(const std::string &contentEncoding); long getPageSize() const; void setPageSize(long pageSize); + std::vector getTag() const; + void setTag(const std::vector &tag); std::string getInvokeId() const; void setInvokeId(const std::string &invokeId); std::string getResourceOwnerAccount() const; @@ -64,6 +70,7 @@ private: std::string regionId_; std::string contentEncoding_; long pageSize_; + std::vector tag_; std::string invokeId_; std::string resourceOwnerAccount_; std::string ownerAccount_; diff --git a/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsResult.h b/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsResult.h index 6ab98d56b..1e3d95694 100644 --- a/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsResult.h +++ b/ecs/include/alibabacloud/ecs/model/DescribeInvocationResultsResult.h @@ -36,6 +36,11 @@ namespace AlibabaCloud { struct InvocationResult { + struct Tag + { + std::string tagKey; + std::string tagValue; + }; int dropped; std::string invocationStatus; std::string instanceId; @@ -49,6 +54,7 @@ namespace AlibabaCloud std::string output; std::string commandId; std::string errorCode; + std::vector tags; std::string invokeId; std::string stopTime; }; diff --git a/ecs/include/alibabacloud/ecs/model/DescribeInvocationsRequest.h b/ecs/include/alibabacloud/ecs/model/DescribeInvocationsRequest.h index 1d2086583..fc90b44c1 100644 --- a/ecs/include/alibabacloud/ecs/model/DescribeInvocationsRequest.h +++ b/ecs/include/alibabacloud/ecs/model/DescribeInvocationsRequest.h @@ -28,6 +28,10 @@ namespace Ecs { namespace Model { class ALIBABACLOUD_ECS_EXPORT DescribeInvocationsRequest : public RpcServiceRequest { public: + struct Tag { + std::string key; + std::string value; + }; DescribeInvocationsRequest(); ~DescribeInvocationsRequest(); long getResourceOwnerId() const; @@ -48,6 +52,8 @@ public: void setRepeatMode(const std::string &repeatMode); long getPageSize() const; void setPageSize(long pageSize); + std::vector getTag() const; + void setTag(const std::vector &tag); std::string getInvokeId() const; void setInvokeId(const std::string &invokeId); bool getTimed() const; @@ -75,6 +81,7 @@ private: std::string contentEncoding_; std::string repeatMode_; long pageSize_; + std::vector tag_; std::string invokeId_; bool timed_; std::string commandName_; diff --git a/ecs/include/alibabacloud/ecs/model/DescribeInvocationsResult.h b/ecs/include/alibabacloud/ecs/model/DescribeInvocationsResult.h index 27498966a..40ad4d090 100644 --- a/ecs/include/alibabacloud/ecs/model/DescribeInvocationsResult.h +++ b/ecs/include/alibabacloud/ecs/model/DescribeInvocationsResult.h @@ -52,6 +52,11 @@ namespace AlibabaCloud std::string errorCode; std::string stopTime; }; + struct Tag + { + std::string tagKey; + std::string tagValue; + }; std::string invocationStatus; std::string parameters; bool timed; @@ -68,6 +73,7 @@ namespace AlibabaCloud std::string frequency; std::string commandId; std::string commandName; + std::vector tags; std::string invokeId; }; diff --git a/ecs/include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetRequest.h b/ecs/include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetRequest.h new file mode 100644 index 000000000..4b6e62938 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetRequest.h @@ -0,0 +1,57 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_MODIFYDIAGNOSTICMETRICSETREQUEST_H_ +#define ALIBABACLOUD_ECS_MODEL_MODIFYDIAGNOSTICMETRICSETREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Ecs { +namespace Model { +class ALIBABACLOUD_ECS_EXPORT ModifyDiagnosticMetricSetRequest : public RpcServiceRequest { +public: + ModifyDiagnosticMetricSetRequest(); + ~ModifyDiagnosticMetricSetRequest(); + std::vector getMetricIds() const; + void setMetricIds(const std::vector &metricIds); + std::string getMetricSetId() const; + void setMetricSetId(const std::string &metricSetId); + std::string getDescription() const; + void setDescription(const std::string &description); + std::string getMetricSetName() const; + void setMetricSetName(const std::string &metricSetName); + std::string getRegionId() const; + void setRegionId(const std::string ®ionId); + std::string getResourceType() const; + void setResourceType(const std::string &resourceType); + +private: + std::vector metricIds_; + std::string metricSetId_; + std::string description_; + std::string metricSetName_; + std::string regionId_; + std::string resourceType_; +}; +} // namespace Model +} // namespace Ecs +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_ECS_MODEL_MODIFYDIAGNOSTICMETRICSETREQUEST_H_ diff --git a/ecs/include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetResult.h b/ecs/include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetResult.h new file mode 100644 index 000000000..7dda705a0 --- /dev/null +++ b/ecs/include/alibabacloud/ecs/model/ModifyDiagnosticMetricSetResult.h @@ -0,0 +1,49 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_ECS_MODEL_MODIFYDIAGNOSTICMETRICSETRESULT_H_ +#define ALIBABACLOUD_ECS_MODEL_MODIFYDIAGNOSTICMETRICSETRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Ecs + { + namespace Model + { + class ALIBABACLOUD_ECS_EXPORT ModifyDiagnosticMetricSetResult : public ServiceResult + { + public: + + + ModifyDiagnosticMetricSetResult(); + explicit ModifyDiagnosticMetricSetResult(const std::string &payload); + ~ModifyDiagnosticMetricSetResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_ECS_MODEL_MODIFYDIAGNOSTICMETRICSETRESULT_H_ \ No newline at end of file diff --git a/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupEgressRuleRequest.h b/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupEgressRuleRequest.h index ea46be0af..53355762f 100644 --- a/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupEgressRuleRequest.h +++ b/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupEgressRuleRequest.h @@ -46,12 +46,12 @@ public: void setDescription(const std::string &description); std::string getRegionId() const; void setRegionId(const std::string ®ionId); + std::string getPolicy() const; + void setPolicy(const std::string &policy); std::string getIpv6DestCidrIp() const; void setIpv6DestCidrIp(const std::string &ipv6DestCidrIp); std::string getIpv6SourceCidrIp() const; void setIpv6SourceCidrIp(const std::string &ipv6SourceCidrIp); - std::string getPolicy() const; - void setPolicy(const std::string &policy); std::string getPortRange() const; void setPortRange(const std::string &portRange); std::string getResourceOwnerAccount() const; @@ -66,10 +66,10 @@ public: void setDestGroupId(const std::string &destGroupId); long getOwnerId() const; void setOwnerId(long ownerId); - std::string getDestGroupOwnerAccount() const; - void setDestGroupOwnerAccount(const std::string &destGroupOwnerAccount); std::string getPriority() const; void setPriority(const std::string &priority); + std::string getDestGroupOwnerAccount() const; + void setDestGroupOwnerAccount(const std::string &destGroupOwnerAccount); std::string getDestCidrIp() const; void setDestCidrIp(const std::string &destCidrIp); long getDestGroupOwnerId() const; @@ -84,9 +84,9 @@ private: std::string securityGroupId_; std::string description_; std::string regionId_; + std::string policy_; std::string ipv6DestCidrIp_; std::string ipv6SourceCidrIp_; - std::string policy_; std::string portRange_; std::string resourceOwnerAccount_; std::string ipProtocol_; @@ -94,8 +94,8 @@ private: std::string sourceCidrIp_; std::string destGroupId_; long ownerId_; - std::string destGroupOwnerAccount_; std::string priority_; + std::string destGroupOwnerAccount_; std::string destCidrIp_; long destGroupOwnerId_; }; diff --git a/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupRuleRequest.h b/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupRuleRequest.h index 7edccd33d..f62897835 100644 --- a/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupRuleRequest.h +++ b/ecs/include/alibabacloud/ecs/model/ModifySecurityGroupRuleRequest.h @@ -50,12 +50,12 @@ public: void setSourceGroupOwnerAccount(const std::string &sourceGroupOwnerAccount); std::string getRegionId() const; void setRegionId(const std::string ®ionId); + std::string getPolicy() const; + void setPolicy(const std::string &policy); std::string getIpv6SourceCidrIp() const; void setIpv6SourceCidrIp(const std::string &ipv6SourceCidrIp); std::string getIpv6DestCidrIp() const; void setIpv6DestCidrIp(const std::string &ipv6DestCidrIp); - std::string getPolicy() const; - void setPolicy(const std::string &policy); std::string getPortRange() const; void setPortRange(const std::string &portRange); std::string getResourceOwnerAccount() const; @@ -86,9 +86,9 @@ private: long sourceGroupOwnerId_; std::string sourceGroupOwnerAccount_; std::string regionId_; + std::string policy_; std::string ipv6SourceCidrIp_; std::string ipv6DestCidrIp_; - std::string policy_; std::string portRange_; std::string resourceOwnerAccount_; std::string ipProtocol_; diff --git a/ecs/include/alibabacloud/ecs/model/RunCommandRequest.h b/ecs/include/alibabacloud/ecs/model/RunCommandRequest.h index 5703e97c3..c091d0b9b 100644 --- a/ecs/include/alibabacloud/ecs/model/RunCommandRequest.h +++ b/ecs/include/alibabacloud/ecs/model/RunCommandRequest.h @@ -28,6 +28,10 @@ namespace Ecs { namespace Model { class ALIBABACLOUD_ECS_EXPORT RunCommandRequest : public RpcServiceRequest { public: + struct Tag { + std::string key; + std::string value; + }; RunCommandRequest(); ~RunCommandRequest(); long getResourceOwnerId() const; @@ -52,6 +56,8 @@ public: void setRepeatMode(const std::string &repeatMode); std::string getWindowsPasswordName() const; void setWindowsPasswordName(const std::string &windowsPasswordName); + std::vector getTag() const; + void setTag(const std::vector &tag); bool getKeepCommand() const; void setKeepCommand(bool keepCommand); bool getTimed() const; @@ -85,6 +91,7 @@ private: std::string contentEncoding_; std::string repeatMode_; std::string windowsPasswordName_; + std::vector tag_; bool keepCommand_; bool timed_; std::string resourceOwnerAccount_; diff --git a/ecs/src/EcsClient.cc b/ecs/src/EcsClient.cc index 155e387d9..521761cf1 100644 --- a/ecs/src/EcsClient.cc +++ b/ecs/src/EcsClient.cc @@ -1419,6 +1419,78 @@ EcsClient::CreateDeploymentSetOutcomeCallable EcsClient::createDeploymentSetCall return task->get_future(); } +EcsClient::CreateDiagnosticMetricSetOutcome EcsClient::createDiagnosticMetricSet(const CreateDiagnosticMetricSetRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateDiagnosticMetricSetOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateDiagnosticMetricSetOutcome(CreateDiagnosticMetricSetResult(outcome.result())); + else + return CreateDiagnosticMetricSetOutcome(outcome.error()); +} + +void EcsClient::createDiagnosticMetricSetAsync(const CreateDiagnosticMetricSetRequest& request, const CreateDiagnosticMetricSetAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createDiagnosticMetricSet(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::CreateDiagnosticMetricSetOutcomeCallable EcsClient::createDiagnosticMetricSetCallable(const CreateDiagnosticMetricSetRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createDiagnosticMetricSet(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +EcsClient::CreateDiagnosticReportOutcome EcsClient::createDiagnosticReport(const CreateDiagnosticReportRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateDiagnosticReportOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateDiagnosticReportOutcome(CreateDiagnosticReportResult(outcome.result())); + else + return CreateDiagnosticReportOutcome(outcome.error()); +} + +void EcsClient::createDiagnosticReportAsync(const CreateDiagnosticReportRequest& request, const CreateDiagnosticReportAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createDiagnosticReport(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::CreateDiagnosticReportOutcomeCallable EcsClient::createDiagnosticReportCallable(const CreateDiagnosticReportRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createDiagnosticReport(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + EcsClient::CreateDiskOutcome EcsClient::createDisk(const CreateDiskRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -2715,6 +2787,78 @@ EcsClient::DeleteDeploymentSetOutcomeCallable EcsClient::deleteDeploymentSetCall return task->get_future(); } +EcsClient::DeleteDiagnosticMetricSetsOutcome EcsClient::deleteDiagnosticMetricSets(const DeleteDiagnosticMetricSetsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteDiagnosticMetricSetsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteDiagnosticMetricSetsOutcome(DeleteDiagnosticMetricSetsResult(outcome.result())); + else + return DeleteDiagnosticMetricSetsOutcome(outcome.error()); +} + +void EcsClient::deleteDiagnosticMetricSetsAsync(const DeleteDiagnosticMetricSetsRequest& request, const DeleteDiagnosticMetricSetsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteDiagnosticMetricSets(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::DeleteDiagnosticMetricSetsOutcomeCallable EcsClient::deleteDiagnosticMetricSetsCallable(const DeleteDiagnosticMetricSetsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteDiagnosticMetricSets(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +EcsClient::DeleteDiagnosticReportsOutcome EcsClient::deleteDiagnosticReports(const DeleteDiagnosticReportsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteDiagnosticReportsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteDiagnosticReportsOutcome(DeleteDiagnosticReportsResult(outcome.result())); + else + return DeleteDiagnosticReportsOutcome(outcome.error()); +} + +void EcsClient::deleteDiagnosticReportsAsync(const DeleteDiagnosticReportsRequest& request, const DeleteDiagnosticReportsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteDiagnosticReports(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::DeleteDiagnosticReportsOutcomeCallable EcsClient::deleteDiagnosticReportsCallable(const DeleteDiagnosticReportsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteDiagnosticReports(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + EcsClient::DeleteDiskOutcome EcsClient::deleteDisk(const DeleteDiskRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -4551,6 +4695,114 @@ EcsClient::DescribeDeploymentSetsOutcomeCallable EcsClient::describeDeploymentSe return task->get_future(); } +EcsClient::DescribeDiagnosticMetricSetsOutcome EcsClient::describeDiagnosticMetricSets(const DescribeDiagnosticMetricSetsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeDiagnosticMetricSetsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeDiagnosticMetricSetsOutcome(DescribeDiagnosticMetricSetsResult(outcome.result())); + else + return DescribeDiagnosticMetricSetsOutcome(outcome.error()); +} + +void EcsClient::describeDiagnosticMetricSetsAsync(const DescribeDiagnosticMetricSetsRequest& request, const DescribeDiagnosticMetricSetsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeDiagnosticMetricSets(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::DescribeDiagnosticMetricSetsOutcomeCallable EcsClient::describeDiagnosticMetricSetsCallable(const DescribeDiagnosticMetricSetsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeDiagnosticMetricSets(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +EcsClient::DescribeDiagnosticMetricsOutcome EcsClient::describeDiagnosticMetrics(const DescribeDiagnosticMetricsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeDiagnosticMetricsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeDiagnosticMetricsOutcome(DescribeDiagnosticMetricsResult(outcome.result())); + else + return DescribeDiagnosticMetricsOutcome(outcome.error()); +} + +void EcsClient::describeDiagnosticMetricsAsync(const DescribeDiagnosticMetricsRequest& request, const DescribeDiagnosticMetricsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeDiagnosticMetrics(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::DescribeDiagnosticMetricsOutcomeCallable EcsClient::describeDiagnosticMetricsCallable(const DescribeDiagnosticMetricsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeDiagnosticMetrics(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +EcsClient::DescribeDiagnosticReportsOutcome EcsClient::describeDiagnosticReports(const DescribeDiagnosticReportsRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeDiagnosticReportsOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeDiagnosticReportsOutcome(DescribeDiagnosticReportsResult(outcome.result())); + else + return DescribeDiagnosticReportsOutcome(outcome.error()); +} + +void EcsClient::describeDiagnosticReportsAsync(const DescribeDiagnosticReportsRequest& request, const DescribeDiagnosticReportsAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeDiagnosticReports(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::DescribeDiagnosticReportsOutcomeCallable EcsClient::describeDiagnosticReportsCallable(const DescribeDiagnosticReportsRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeDiagnosticReports(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + EcsClient::DescribeDiskMonitorDataOutcome EcsClient::describeDiskMonitorData(const DescribeDiskMonitorDataRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -8907,6 +9159,42 @@ EcsClient::ModifyDeploymentSetAttributeOutcomeCallable EcsClient::modifyDeployme return task->get_future(); } +EcsClient::ModifyDiagnosticMetricSetOutcome EcsClient::modifyDiagnosticMetricSet(const ModifyDiagnosticMetricSetRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ModifyDiagnosticMetricSetOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ModifyDiagnosticMetricSetOutcome(ModifyDiagnosticMetricSetResult(outcome.result())); + else + return ModifyDiagnosticMetricSetOutcome(outcome.error()); +} + +void EcsClient::modifyDiagnosticMetricSetAsync(const ModifyDiagnosticMetricSetRequest& request, const ModifyDiagnosticMetricSetAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, modifyDiagnosticMetricSet(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +EcsClient::ModifyDiagnosticMetricSetOutcomeCallable EcsClient::modifyDiagnosticMetricSetCallable(const ModifyDiagnosticMetricSetRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->modifyDiagnosticMetricSet(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + EcsClient::ModifyDiskAttributeOutcome EcsClient::modifyDiskAttribute(const ModifyDiskAttributeRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); diff --git a/ecs/src/model/CreateDiagnosticMetricSetRequest.cc b/ecs/src/model/CreateDiagnosticMetricSetRequest.cc new file mode 100644 index 000000000..93d533105 --- /dev/null +++ b/ecs/src/model/CreateDiagnosticMetricSetRequest.cc @@ -0,0 +1,71 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Ecs::Model::CreateDiagnosticMetricSetRequest; + +CreateDiagnosticMetricSetRequest::CreateDiagnosticMetricSetRequest() + : RpcServiceRequest("ecs", "2014-05-26", "CreateDiagnosticMetricSet") { + setMethod(HttpRequest::Method::Post); +} + +CreateDiagnosticMetricSetRequest::~CreateDiagnosticMetricSetRequest() {} + +std::vector CreateDiagnosticMetricSetRequest::getMetricIds() const { + return metricIds_; +} + +void CreateDiagnosticMetricSetRequest::setMetricIds(const std::vector &metricIds) { + metricIds_ = metricIds; +} + +std::string CreateDiagnosticMetricSetRequest::getDescription() const { + return description_; +} + +void CreateDiagnosticMetricSetRequest::setDescription(const std::string &description) { + description_ = description; + setParameter(std::string("Description"), description); +} + +std::string CreateDiagnosticMetricSetRequest::getMetricSetName() const { + return metricSetName_; +} + +void CreateDiagnosticMetricSetRequest::setMetricSetName(const std::string &metricSetName) { + metricSetName_ = metricSetName; + setParameter(std::string("MetricSetName"), metricSetName); +} + +std::string CreateDiagnosticMetricSetRequest::getResourceType() const { + return resourceType_; +} + +void CreateDiagnosticMetricSetRequest::setResourceType(const std::string &resourceType) { + resourceType_ = resourceType; + setParameter(std::string("ResourceType"), resourceType); +} + +std::string CreateDiagnosticMetricSetRequest::getRegionId() const { + return regionId_; +} + +void CreateDiagnosticMetricSetRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + diff --git a/ecs/src/model/CreateDiagnosticMetricSetResult.cc b/ecs/src/model/CreateDiagnosticMetricSetResult.cc new file mode 100644 index 000000000..745fcd4bc --- /dev/null +++ b/ecs/src/model/CreateDiagnosticMetricSetResult.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::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +CreateDiagnosticMetricSetResult::CreateDiagnosticMetricSetResult() : + ServiceResult() +{} + +CreateDiagnosticMetricSetResult::CreateDiagnosticMetricSetResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateDiagnosticMetricSetResult::~CreateDiagnosticMetricSetResult() +{} + +void CreateDiagnosticMetricSetResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["MetricSetId"].isNull()) + metricSetId_ = value["MetricSetId"].asString(); + +} + +std::string CreateDiagnosticMetricSetResult::getMetricSetId()const +{ + return metricSetId_; +} + diff --git a/ecs/src/model/CreateDiagnosticReportRequest.cc b/ecs/src/model/CreateDiagnosticReportRequest.cc new file mode 100644 index 000000000..c2be02b88 --- /dev/null +++ b/ecs/src/model/CreateDiagnosticReportRequest.cc @@ -0,0 +1,72 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Ecs::Model::CreateDiagnosticReportRequest; + +CreateDiagnosticReportRequest::CreateDiagnosticReportRequest() + : RpcServiceRequest("ecs", "2014-05-26", "CreateDiagnosticReport") { + setMethod(HttpRequest::Method::Post); +} + +CreateDiagnosticReportRequest::~CreateDiagnosticReportRequest() {} + +std::string CreateDiagnosticReportRequest::getResourceId() const { + return resourceId_; +} + +void CreateDiagnosticReportRequest::setResourceId(const std::string &resourceId) { + resourceId_ = resourceId; + setParameter(std::string("ResourceId"), resourceId); +} + +std::string CreateDiagnosticReportRequest::getMetricSetId() const { + return metricSetId_; +} + +void CreateDiagnosticReportRequest::setMetricSetId(const std::string &metricSetId) { + metricSetId_ = metricSetId; + setParameter(std::string("MetricSetId"), metricSetId); +} + +std::string CreateDiagnosticReportRequest::getEndTime() const { + return endTime_; +} + +void CreateDiagnosticReportRequest::setEndTime(const std::string &endTime) { + endTime_ = endTime; + setParameter(std::string("EndTime"), endTime); +} + +std::string CreateDiagnosticReportRequest::getStartTime() const { + return startTime_; +} + +void CreateDiagnosticReportRequest::setStartTime(const std::string &startTime) { + startTime_ = startTime; + setParameter(std::string("StartTime"), startTime); +} + +std::string CreateDiagnosticReportRequest::getRegionId() const { + return regionId_; +} + +void CreateDiagnosticReportRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + diff --git a/ecs/src/model/CreateDiagnosticReportResult.cc b/ecs/src/model/CreateDiagnosticReportResult.cc new file mode 100644 index 000000000..6856c29bb --- /dev/null +++ b/ecs/src/model/CreateDiagnosticReportResult.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::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +CreateDiagnosticReportResult::CreateDiagnosticReportResult() : + ServiceResult() +{} + +CreateDiagnosticReportResult::CreateDiagnosticReportResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateDiagnosticReportResult::~CreateDiagnosticReportResult() +{} + +void CreateDiagnosticReportResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["ReportId"].isNull()) + reportId_ = value["ReportId"].asString(); + +} + +std::string CreateDiagnosticReportResult::getReportId()const +{ + return reportId_; +} + diff --git a/ecs/src/model/DeleteDiagnosticMetricSetsRequest.cc b/ecs/src/model/DeleteDiagnosticMetricSetsRequest.cc new file mode 100644 index 000000000..63f61f238 --- /dev/null +++ b/ecs/src/model/DeleteDiagnosticMetricSetsRequest.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Ecs::Model::DeleteDiagnosticMetricSetsRequest; + +DeleteDiagnosticMetricSetsRequest::DeleteDiagnosticMetricSetsRequest() + : RpcServiceRequest("ecs", "2014-05-26", "DeleteDiagnosticMetricSets") { + setMethod(HttpRequest::Method::Post); +} + +DeleteDiagnosticMetricSetsRequest::~DeleteDiagnosticMetricSetsRequest() {} + +std::vector DeleteDiagnosticMetricSetsRequest::getMetricSetIds() const { + return metricSetIds_; +} + +void DeleteDiagnosticMetricSetsRequest::setMetricSetIds(const std::vector &metricSetIds) { + metricSetIds_ = metricSetIds; +} + +std::string DeleteDiagnosticMetricSetsRequest::getRegionId() const { + return regionId_; +} + +void DeleteDiagnosticMetricSetsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + diff --git a/ecs/src/model/DeleteDiagnosticMetricSetsResult.cc b/ecs/src/model/DeleteDiagnosticMetricSetsResult.cc new file mode 100644 index 000000000..bd0b83412 --- /dev/null +++ b/ecs/src/model/DeleteDiagnosticMetricSetsResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +DeleteDiagnosticMetricSetsResult::DeleteDiagnosticMetricSetsResult() : + ServiceResult() +{} + +DeleteDiagnosticMetricSetsResult::DeleteDiagnosticMetricSetsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteDiagnosticMetricSetsResult::~DeleteDiagnosticMetricSetsResult() +{} + +void DeleteDiagnosticMetricSetsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/ecs/src/model/DeleteDiagnosticReportsRequest.cc b/ecs/src/model/DeleteDiagnosticReportsRequest.cc new file mode 100644 index 000000000..7c7e14aa0 --- /dev/null +++ b/ecs/src/model/DeleteDiagnosticReportsRequest.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Ecs::Model::DeleteDiagnosticReportsRequest; + +DeleteDiagnosticReportsRequest::DeleteDiagnosticReportsRequest() + : RpcServiceRequest("ecs", "2014-05-26", "DeleteDiagnosticReports") { + setMethod(HttpRequest::Method::Post); +} + +DeleteDiagnosticReportsRequest::~DeleteDiagnosticReportsRequest() {} + +std::vector DeleteDiagnosticReportsRequest::getReportIds() const { + return reportIds_; +} + +void DeleteDiagnosticReportsRequest::setReportIds(const std::vector &reportIds) { + reportIds_ = reportIds; +} + +std::string DeleteDiagnosticReportsRequest::getRegionId() const { + return regionId_; +} + +void DeleteDiagnosticReportsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + diff --git a/ecs/src/model/DeleteDiagnosticReportsResult.cc b/ecs/src/model/DeleteDiagnosticReportsResult.cc new file mode 100644 index 000000000..3a9411437 --- /dev/null +++ b/ecs/src/model/DeleteDiagnosticReportsResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +DeleteDiagnosticReportsResult::DeleteDiagnosticReportsResult() : + ServiceResult() +{} + +DeleteDiagnosticReportsResult::DeleteDiagnosticReportsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteDiagnosticReportsResult::~DeleteDiagnosticReportsResult() +{} + +void DeleteDiagnosticReportsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/ecs/src/model/DescribeCommandsRequest.cc b/ecs/src/model/DescribeCommandsRequest.cc index e10bf51f3..2e16f3e6b 100644 --- a/ecs/src/model/DescribeCommandsRequest.cc +++ b/ecs/src/model/DescribeCommandsRequest.cc @@ -106,6 +106,20 @@ void DescribeCommandsRequest::setPageSize(long pageSize) { setParameter(std::string("PageSize"), std::to_string(pageSize)); } +std::vector DescribeCommandsRequest::getTag() const { + return tag_; +} + +void DescribeCommandsRequest::setTag(const std::vector &tag) { + tag_ = tag; + for(int dep1 = 0; dep1 != tag.size(); dep1++) { + auto tagObj = tag.at(dep1); + std::string tagObjStr = std::string("Tag") + "." + std::to_string(dep1 + 1); + setParameter(tagObjStr + ".Key", tagObj.key); + setParameter(tagObjStr + ".Value", tagObj.value); + } +} + bool DescribeCommandsRequest::getLatest() const { return latest_; } diff --git a/ecs/src/model/DescribeCommandsResult.cc b/ecs/src/model/DescribeCommandsResult.cc index 574695fef..d9d396d7d 100644 --- a/ecs/src/model/DescribeCommandsResult.cc +++ b/ecs/src/model/DescribeCommandsResult.cc @@ -88,6 +88,16 @@ void DescribeCommandsResult::parse(const std::string &payload) parameterDefinitionsObject.possibleValues.push_back(value.asString()); commandsObject.parameterDefinitions.push_back(parameterDefinitionsObject); } + auto allTagsNode = valueCommandsCommand["Tags"]["Tag"]; + for (auto valueCommandsCommandTagsTag : allTagsNode) + { + Command::Tag tagsObject; + if(!valueCommandsCommandTagsTag["TagKey"].isNull()) + tagsObject.tagKey = valueCommandsCommandTagsTag["TagKey"].asString(); + if(!valueCommandsCommandTagsTag["TagValue"].isNull()) + tagsObject.tagValue = valueCommandsCommandTagsTag["TagValue"].asString(); + commandsObject.tags.push_back(tagsObject); + } auto allParameterNames = value["ParameterNames"]["ParameterName"]; for (auto value : allParameterNames) commandsObject.parameterNames.push_back(value.asString()); diff --git a/ecs/src/model/DescribeDiagnosticMetricSetsRequest.cc b/ecs/src/model/DescribeDiagnosticMetricSetsRequest.cc new file mode 100644 index 000000000..bfa36de6c --- /dev/null +++ b/ecs/src/model/DescribeDiagnosticMetricSetsRequest.cc @@ -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. + */ + +#include + +using AlibabaCloud::Ecs::Model::DescribeDiagnosticMetricSetsRequest; + +DescribeDiagnosticMetricSetsRequest::DescribeDiagnosticMetricSetsRequest() + : RpcServiceRequest("ecs", "2014-05-26", "DescribeDiagnosticMetricSets") { + setMethod(HttpRequest::Method::Post); +} + +DescribeDiagnosticMetricSetsRequest::~DescribeDiagnosticMetricSetsRequest() {} + +std::vector DescribeDiagnosticMetricSetsRequest::getMetricSetIds() const { + return metricSetIds_; +} + +void DescribeDiagnosticMetricSetsRequest::setMetricSetIds(const std::vector &metricSetIds) { + metricSetIds_ = metricSetIds; +} + +std::string DescribeDiagnosticMetricSetsRequest::getType() const { + return type_; +} + +void DescribeDiagnosticMetricSetsRequest::setType(const std::string &type) { + type_ = type; + setParameter(std::string("Type"), type); +} + +std::string DescribeDiagnosticMetricSetsRequest::getRegionId() const { + return regionId_; +} + +void DescribeDiagnosticMetricSetsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string DescribeDiagnosticMetricSetsRequest::getNextToken() const { + return nextToken_; +} + +void DescribeDiagnosticMetricSetsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +std::string DescribeDiagnosticMetricSetsRequest::getResourceType() const { + return resourceType_; +} + +void DescribeDiagnosticMetricSetsRequest::setResourceType(const std::string &resourceType) { + resourceType_ = resourceType; + setParameter(std::string("ResourceType"), resourceType); +} + +int DescribeDiagnosticMetricSetsRequest::getMaxResults() const { + return maxResults_; +} + +void DescribeDiagnosticMetricSetsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + diff --git a/ecs/src/model/DescribeDiagnosticMetricSetsResult.cc b/ecs/src/model/DescribeDiagnosticMetricSetsResult.cc new file mode 100644 index 000000000..dc8c869a9 --- /dev/null +++ b/ecs/src/model/DescribeDiagnosticMetricSetsResult.cc @@ -0,0 +1,75 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +DescribeDiagnosticMetricSetsResult::DescribeDiagnosticMetricSetsResult() : + ServiceResult() +{} + +DescribeDiagnosticMetricSetsResult::DescribeDiagnosticMetricSetsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeDiagnosticMetricSetsResult::~DescribeDiagnosticMetricSetsResult() +{} + +void DescribeDiagnosticMetricSetsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allMetricSetsNode = value["MetricSets"]["MetricSet"]; + for (auto valueMetricSetsMetricSet : allMetricSetsNode) + { + MetricSet metricSetsObject; + if(!valueMetricSetsMetricSet["MetricSetId"].isNull()) + metricSetsObject.metricSetId = valueMetricSetsMetricSet["MetricSetId"].asString(); + if(!valueMetricSetsMetricSet["MetricSetName"].isNull()) + metricSetsObject.metricSetName = valueMetricSetsMetricSet["MetricSetName"].asString(); + if(!valueMetricSetsMetricSet["Description"].isNull()) + metricSetsObject.description = valueMetricSetsMetricSet["Description"].asString(); + if(!valueMetricSetsMetricSet["Type"].isNull()) + metricSetsObject.type = valueMetricSetsMetricSet["Type"].asString(); + if(!valueMetricSetsMetricSet["ResourceType"].isNull()) + metricSetsObject.resourceType = valueMetricSetsMetricSet["ResourceType"].asString(); + auto allMetricIds = value["MetricIds"]["MetricId"]; + for (auto value : allMetricIds) + metricSetsObject.metricIds.push_back(value.asString()); + metricSets_.push_back(metricSetsObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + +} + +std::string DescribeDiagnosticMetricSetsResult::getNextToken()const +{ + return nextToken_; +} + +std::vector DescribeDiagnosticMetricSetsResult::getMetricSets()const +{ + return metricSets_; +} + diff --git a/ecs/src/model/DescribeDiagnosticMetricsRequest.cc b/ecs/src/model/DescribeDiagnosticMetricsRequest.cc new file mode 100644 index 000000000..c27cebc6f --- /dev/null +++ b/ecs/src/model/DescribeDiagnosticMetricsRequest.cc @@ -0,0 +1,71 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Ecs::Model::DescribeDiagnosticMetricsRequest; + +DescribeDiagnosticMetricsRequest::DescribeDiagnosticMetricsRequest() + : RpcServiceRequest("ecs", "2014-05-26", "DescribeDiagnosticMetrics") { + setMethod(HttpRequest::Method::Post); +} + +DescribeDiagnosticMetricsRequest::~DescribeDiagnosticMetricsRequest() {} + +std::vector DescribeDiagnosticMetricsRequest::getMetricIds() const { + return metricIds_; +} + +void DescribeDiagnosticMetricsRequest::setMetricIds(const std::vector &metricIds) { + metricIds_ = metricIds; +} + +std::string DescribeDiagnosticMetricsRequest::getResourceType() const { + return resourceType_; +} + +void DescribeDiagnosticMetricsRequest::setResourceType(const std::string &resourceType) { + resourceType_ = resourceType; + setParameter(std::string("ResourceType"), resourceType); +} + +std::string DescribeDiagnosticMetricsRequest::getRegionId() const { + return regionId_; +} + +void DescribeDiagnosticMetricsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string DescribeDiagnosticMetricsRequest::getNextToken() const { + return nextToken_; +} + +void DescribeDiagnosticMetricsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +int DescribeDiagnosticMetricsRequest::getMaxResults() const { + return maxResults_; +} + +void DescribeDiagnosticMetricsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + diff --git a/ecs/src/model/DescribeDiagnosticMetricsResult.cc b/ecs/src/model/DescribeDiagnosticMetricsResult.cc new file mode 100644 index 000000000..eccd32aee --- /dev/null +++ b/ecs/src/model/DescribeDiagnosticMetricsResult.cc @@ -0,0 +1,76 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +DescribeDiagnosticMetricsResult::DescribeDiagnosticMetricsResult() : + ServiceResult() +{} + +DescribeDiagnosticMetricsResult::DescribeDiagnosticMetricsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeDiagnosticMetricsResult::~DescribeDiagnosticMetricsResult() +{} + +void DescribeDiagnosticMetricsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allMetricsNode = value["Metrics"]["Metric"]; + for (auto valueMetricsMetric : allMetricsNode) + { + Metric metricsObject; + if(!valueMetricsMetric["MetricId"].isNull()) + metricsObject.metricId = valueMetricsMetric["MetricId"].asString(); + if(!valueMetricsMetric["MetricName"].isNull()) + metricsObject.metricName = valueMetricsMetric["MetricName"].asString(); + if(!valueMetricsMetric["MetricCategory"].isNull()) + metricsObject.metricCategory = valueMetricsMetric["MetricCategory"].asString(); + if(!valueMetricsMetric["Description"].isNull()) + metricsObject.description = valueMetricsMetric["Description"].asString(); + if(!valueMetricsMetric["ResourceType"].isNull()) + metricsObject.resourceType = valueMetricsMetric["ResourceType"].asString(); + if(!valueMetricsMetric["GuestMetric"].isNull()) + metricsObject.guestMetric = valueMetricsMetric["GuestMetric"].asString() == "true"; + if(!valueMetricsMetric["SupportedOperatingSystem"].isNull()) + metricsObject.supportedOperatingSystem = valueMetricsMetric["SupportedOperatingSystem"].asString(); + metrics_.push_back(metricsObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + +} + +std::vector DescribeDiagnosticMetricsResult::getMetrics()const +{ + return metrics_; +} + +std::string DescribeDiagnosticMetricsResult::getNextToken()const +{ + return nextToken_; +} + diff --git a/ecs/src/model/DescribeDiagnosticReportsRequest.cc b/ecs/src/model/DescribeDiagnosticReportsRequest.cc new file mode 100644 index 000000000..a945a65a8 --- /dev/null +++ b/ecs/src/model/DescribeDiagnosticReportsRequest.cc @@ -0,0 +1,88 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Ecs::Model::DescribeDiagnosticReportsRequest; + +DescribeDiagnosticReportsRequest::DescribeDiagnosticReportsRequest() + : RpcServiceRequest("ecs", "2014-05-26", "DescribeDiagnosticReports") { + setMethod(HttpRequest::Method::Post); +} + +DescribeDiagnosticReportsRequest::~DescribeDiagnosticReportsRequest() {} + +std::string DescribeDiagnosticReportsRequest::getRegionId() const { + return regionId_; +} + +void DescribeDiagnosticReportsRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string DescribeDiagnosticReportsRequest::getNextToken() const { + return nextToken_; +} + +void DescribeDiagnosticReportsRequest::setNextToken(const std::string &nextToken) { + nextToken_ = nextToken; + setParameter(std::string("NextToken"), nextToken); +} + +std::string DescribeDiagnosticReportsRequest::getSeverity() const { + return severity_; +} + +void DescribeDiagnosticReportsRequest::setSeverity(const std::string &severity) { + severity_ = severity; + setParameter(std::string("Severity"), severity); +} + +std::vector DescribeDiagnosticReportsRequest::getReportIds() const { + return reportIds_; +} + +void DescribeDiagnosticReportsRequest::setReportIds(const std::vector &reportIds) { + reportIds_ = reportIds; +} + +int DescribeDiagnosticReportsRequest::getMaxResults() const { + return maxResults_; +} + +void DescribeDiagnosticReportsRequest::setMaxResults(int maxResults) { + maxResults_ = maxResults; + setParameter(std::string("MaxResults"), std::to_string(maxResults)); +} + +std::string DescribeDiagnosticReportsRequest::getStatus() const { + return status_; +} + +void DescribeDiagnosticReportsRequest::setStatus(const std::string &status) { + status_ = status; + setParameter(std::string("Status"), status); +} + +std::vector DescribeDiagnosticReportsRequest::getResourceIds() const { + return resourceIds_; +} + +void DescribeDiagnosticReportsRequest::setResourceIds(const std::vector &resourceIds) { + resourceIds_ = resourceIds; +} + diff --git a/ecs/src/model/DescribeDiagnosticReportsResult.cc b/ecs/src/model/DescribeDiagnosticReportsResult.cc new file mode 100644 index 000000000..0fe0b2845 --- /dev/null +++ b/ecs/src/model/DescribeDiagnosticReportsResult.cc @@ -0,0 +1,96 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +DescribeDiagnosticReportsResult::DescribeDiagnosticReportsResult() : + ServiceResult() +{} + +DescribeDiagnosticReportsResult::DescribeDiagnosticReportsResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeDiagnosticReportsResult::~DescribeDiagnosticReportsResult() +{} + +void DescribeDiagnosticReportsResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allReportsNode = value["Reports"]["Report"]; + for (auto valueReportsReport : allReportsNode) + { + Report reportsObject; + if(!valueReportsReport["ResourceId"].isNull()) + reportsObject.resourceId = valueReportsReport["ResourceId"].asString(); + if(!valueReportsReport["ResourceType"].isNull()) + reportsObject.resourceType = valueReportsReport["ResourceType"].asString(); + if(!valueReportsReport["MetricSetId"].isNull()) + reportsObject.metricSetId = valueReportsReport["MetricSetId"].asString(); + if(!valueReportsReport["StartTime"].isNull()) + reportsObject.startTime = valueReportsReport["StartTime"].asString(); + if(!valueReportsReport["EndTime"].isNull()) + reportsObject.endTime = valueReportsReport["EndTime"].asString(); + if(!valueReportsReport["ReportId"].isNull()) + reportsObject.reportId = valueReportsReport["ReportId"].asString(); + if(!valueReportsReport["Status"].isNull()) + reportsObject.status = valueReportsReport["Status"].asString(); + if(!valueReportsReport["CreationTime"].isNull()) + reportsObject.creationTime = valueReportsReport["CreationTime"].asString(); + if(!valueReportsReport["FinishedTime"].isNull()) + reportsObject.finishedTime = valueReportsReport["FinishedTime"].asString(); + if(!valueReportsReport["Severity"].isNull()) + reportsObject.severity = valueReportsReport["Severity"].asString(); + auto allIssuesNode = valueReportsReport["Issues"]["Issue"]; + for (auto valueReportsReportIssuesIssue : allIssuesNode) + { + Report::Issue issuesObject; + if(!valueReportsReportIssuesIssue["MetricId"].isNull()) + issuesObject.metricId = valueReportsReportIssuesIssue["MetricId"].asString(); + if(!valueReportsReportIssuesIssue["MetricCategory"].isNull()) + issuesObject.metricCategory = valueReportsReportIssuesIssue["MetricCategory"].asString(); + if(!valueReportsReportIssuesIssue["IssueId"].isNull()) + issuesObject.issueId = valueReportsReportIssuesIssue["IssueId"].asString(); + if(!valueReportsReportIssuesIssue["Severity"].isNull()) + issuesObject.severity = valueReportsReportIssuesIssue["Severity"].asString(); + reportsObject.issues.push_back(issuesObject); + } + reports_.push_back(reportsObject); + } + if(!value["NextToken"].isNull()) + nextToken_ = value["NextToken"].asString(); + +} + +std::string DescribeDiagnosticReportsResult::getNextToken()const +{ + return nextToken_; +} + +std::vector DescribeDiagnosticReportsResult::getReports()const +{ + return reports_; +} + diff --git a/ecs/src/model/DescribeInvocationResultsRequest.cc b/ecs/src/model/DescribeInvocationResultsRequest.cc index 4a9dbec99..0c2a85f92 100644 --- a/ecs/src/model/DescribeInvocationResultsRequest.cc +++ b/ecs/src/model/DescribeInvocationResultsRequest.cc @@ -79,6 +79,20 @@ void DescribeInvocationResultsRequest::setPageSize(long pageSize) { setParameter(std::string("PageSize"), std::to_string(pageSize)); } +std::vector DescribeInvocationResultsRequest::getTag() const { + return tag_; +} + +void DescribeInvocationResultsRequest::setTag(const std::vector &tag) { + tag_ = tag; + for(int dep1 = 0; dep1 != tag.size(); dep1++) { + auto tagObj = tag.at(dep1); + std::string tagObjStr = std::string("Tag") + "." + std::to_string(dep1 + 1); + setParameter(tagObjStr + ".Key", tagObj.key); + setParameter(tagObjStr + ".Value", tagObj.value); + } +} + std::string DescribeInvocationResultsRequest::getInvokeId() const { return invokeId_; } diff --git a/ecs/src/model/DescribeInvocationResultsResult.cc b/ecs/src/model/DescribeInvocationResultsResult.cc index 283919d5e..000d83b72 100644 --- a/ecs/src/model/DescribeInvocationResultsResult.cc +++ b/ecs/src/model/DescribeInvocationResultsResult.cc @@ -80,6 +80,16 @@ void DescribeInvocationResultsResult::parse(const std::string &payload) invocationResultObject.invokeRecordStatus = invocationNodeInvocationResultsInvocationResult["InvokeRecordStatus"].asString(); if(!invocationNodeInvocationResultsInvocationResult["Username"].isNull()) invocationResultObject.username = invocationNodeInvocationResultsInvocationResult["Username"].asString(); + auto allTagsNode = invocationNodeInvocationResultsInvocationResult["Tags"]["Tag"]; + for (auto invocationNodeInvocationResultsInvocationResultTagsTag : allTagsNode) + { + Invocation::InvocationResult::Tag tagsObject; + if(!invocationNodeInvocationResultsInvocationResultTagsTag["TagKey"].isNull()) + tagsObject.tagKey = invocationNodeInvocationResultsInvocationResultTagsTag["TagKey"].asString(); + if(!invocationNodeInvocationResultsInvocationResultTagsTag["TagValue"].isNull()) + tagsObject.tagValue = invocationNodeInvocationResultsInvocationResultTagsTag["TagValue"].asString(); + invocationResultObject.tags.push_back(tagsObject); + } invocation_.invocationResults.push_back(invocationResultObject); } diff --git a/ecs/src/model/DescribeInvocationsRequest.cc b/ecs/src/model/DescribeInvocationsRequest.cc index 80a4dee06..3b5e3f3c7 100644 --- a/ecs/src/model/DescribeInvocationsRequest.cc +++ b/ecs/src/model/DescribeInvocationsRequest.cc @@ -106,6 +106,20 @@ void DescribeInvocationsRequest::setPageSize(long pageSize) { setParameter(std::string("PageSize"), std::to_string(pageSize)); } +std::vector DescribeInvocationsRequest::getTag() const { + return tag_; +} + +void DescribeInvocationsRequest::setTag(const std::vector &tag) { + tag_ = tag; + for(int dep1 = 0; dep1 != tag.size(); dep1++) { + auto tagObj = tag.at(dep1); + std::string tagObjStr = std::string("Tag") + "." + std::to_string(dep1 + 1); + setParameter(tagObjStr + ".Key", tagObj.key); + setParameter(tagObjStr + ".Value", tagObj.value); + } +} + std::string DescribeInvocationsRequest::getInvokeId() const { return invokeId_; } diff --git a/ecs/src/model/DescribeInvocationsResult.cc b/ecs/src/model/DescribeInvocationsResult.cc index a9dd0e0a6..c6b1740fb 100644 --- a/ecs/src/model/DescribeInvocationsResult.cc +++ b/ecs/src/model/DescribeInvocationsResult.cc @@ -111,6 +111,16 @@ void DescribeInvocationsResult::parse(const std::string &payload) invokeInstancesObject.instanceInvokeStatus = valueInvocationsInvocationInvokeInstancesInvokeInstance["InstanceInvokeStatus"].asString(); invocationsObject.invokeInstances.push_back(invokeInstancesObject); } + auto allTagsNode = valueInvocationsInvocation["Tags"]["Tag"]; + for (auto valueInvocationsInvocationTagsTag : allTagsNode) + { + Invocation::Tag tagsObject; + if(!valueInvocationsInvocationTagsTag["TagKey"].isNull()) + tagsObject.tagKey = valueInvocationsInvocationTagsTag["TagKey"].asString(); + if(!valueInvocationsInvocationTagsTag["TagValue"].isNull()) + tagsObject.tagValue = valueInvocationsInvocationTagsTag["TagValue"].asString(); + invocationsObject.tags.push_back(tagsObject); + } invocations_.push_back(invocationsObject); } if(!value["PageSize"].isNull()) diff --git a/ecs/src/model/ModifyDiagnosticMetricSetRequest.cc b/ecs/src/model/ModifyDiagnosticMetricSetRequest.cc new file mode 100644 index 000000000..8b6178832 --- /dev/null +++ b/ecs/src/model/ModifyDiagnosticMetricSetRequest.cc @@ -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. + */ + +#include + +using AlibabaCloud::Ecs::Model::ModifyDiagnosticMetricSetRequest; + +ModifyDiagnosticMetricSetRequest::ModifyDiagnosticMetricSetRequest() + : RpcServiceRequest("ecs", "2014-05-26", "ModifyDiagnosticMetricSet") { + setMethod(HttpRequest::Method::Post); +} + +ModifyDiagnosticMetricSetRequest::~ModifyDiagnosticMetricSetRequest() {} + +std::vector ModifyDiagnosticMetricSetRequest::getMetricIds() const { + return metricIds_; +} + +void ModifyDiagnosticMetricSetRequest::setMetricIds(const std::vector &metricIds) { + metricIds_ = metricIds; +} + +std::string ModifyDiagnosticMetricSetRequest::getMetricSetId() const { + return metricSetId_; +} + +void ModifyDiagnosticMetricSetRequest::setMetricSetId(const std::string &metricSetId) { + metricSetId_ = metricSetId; + setParameter(std::string("MetricSetId"), metricSetId); +} + +std::string ModifyDiagnosticMetricSetRequest::getDescription() const { + return description_; +} + +void ModifyDiagnosticMetricSetRequest::setDescription(const std::string &description) { + description_ = description; + setParameter(std::string("Description"), description); +} + +std::string ModifyDiagnosticMetricSetRequest::getMetricSetName() const { + return metricSetName_; +} + +void ModifyDiagnosticMetricSetRequest::setMetricSetName(const std::string &metricSetName) { + metricSetName_ = metricSetName; + setParameter(std::string("MetricSetName"), metricSetName); +} + +std::string ModifyDiagnosticMetricSetRequest::getRegionId() const { + return regionId_; +} + +void ModifyDiagnosticMetricSetRequest::setRegionId(const std::string ®ionId) { + regionId_ = regionId; + setParameter(std::string("RegionId"), regionId); +} + +std::string ModifyDiagnosticMetricSetRequest::getResourceType() const { + return resourceType_; +} + +void ModifyDiagnosticMetricSetRequest::setResourceType(const std::string &resourceType) { + resourceType_ = resourceType; + setParameter(std::string("ResourceType"), resourceType); +} + diff --git a/ecs/src/model/ModifyDiagnosticMetricSetResult.cc b/ecs/src/model/ModifyDiagnosticMetricSetResult.cc new file mode 100644 index 000000000..08c2ad7ce --- /dev/null +++ b/ecs/src/model/ModifyDiagnosticMetricSetResult.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Ecs; +using namespace AlibabaCloud::Ecs::Model; + +ModifyDiagnosticMetricSetResult::ModifyDiagnosticMetricSetResult() : + ServiceResult() +{} + +ModifyDiagnosticMetricSetResult::ModifyDiagnosticMetricSetResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ModifyDiagnosticMetricSetResult::~ModifyDiagnosticMetricSetResult() +{} + +void ModifyDiagnosticMetricSetResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/ecs/src/model/ModifySecurityGroupEgressRuleRequest.cc b/ecs/src/model/ModifySecurityGroupEgressRuleRequest.cc index 28ca048ed..6c04ada86 100644 --- a/ecs/src/model/ModifySecurityGroupEgressRuleRequest.cc +++ b/ecs/src/model/ModifySecurityGroupEgressRuleRequest.cc @@ -97,6 +97,15 @@ void ModifySecurityGroupEgressRuleRequest::setRegionId(const std::string ®ion setParameter(std::string("RegionId"), regionId); } +std::string ModifySecurityGroupEgressRuleRequest::getPolicy() const { + return policy_; +} + +void ModifySecurityGroupEgressRuleRequest::setPolicy(const std::string &policy) { + policy_ = policy; + setParameter(std::string("Policy"), policy); +} + std::string ModifySecurityGroupEgressRuleRequest::getIpv6DestCidrIp() const { return ipv6DestCidrIp_; } @@ -115,15 +124,6 @@ void ModifySecurityGroupEgressRuleRequest::setIpv6SourceCidrIp(const std::string setParameter(std::string("Ipv6SourceCidrIp"), ipv6SourceCidrIp); } -std::string ModifySecurityGroupEgressRuleRequest::getPolicy() const { - return policy_; -} - -void ModifySecurityGroupEgressRuleRequest::setPolicy(const std::string &policy) { - policy_ = policy; - setParameter(std::string("Policy"), policy); -} - std::string ModifySecurityGroupEgressRuleRequest::getPortRange() const { return portRange_; } @@ -187,15 +187,6 @@ void ModifySecurityGroupEgressRuleRequest::setOwnerId(long ownerId) { setParameter(std::string("OwnerId"), std::to_string(ownerId)); } -std::string ModifySecurityGroupEgressRuleRequest::getDestGroupOwnerAccount() const { - return destGroupOwnerAccount_; -} - -void ModifySecurityGroupEgressRuleRequest::setDestGroupOwnerAccount(const std::string &destGroupOwnerAccount) { - destGroupOwnerAccount_ = destGroupOwnerAccount; - setParameter(std::string("DestGroupOwnerAccount"), destGroupOwnerAccount); -} - std::string ModifySecurityGroupEgressRuleRequest::getPriority() const { return priority_; } @@ -205,6 +196,15 @@ void ModifySecurityGroupEgressRuleRequest::setPriority(const std::string &priori setParameter(std::string("Priority"), priority); } +std::string ModifySecurityGroupEgressRuleRequest::getDestGroupOwnerAccount() const { + return destGroupOwnerAccount_; +} + +void ModifySecurityGroupEgressRuleRequest::setDestGroupOwnerAccount(const std::string &destGroupOwnerAccount) { + destGroupOwnerAccount_ = destGroupOwnerAccount; + setParameter(std::string("DestGroupOwnerAccount"), destGroupOwnerAccount); +} + std::string ModifySecurityGroupEgressRuleRequest::getDestCidrIp() const { return destCidrIp_; } diff --git a/ecs/src/model/ModifySecurityGroupRuleRequest.cc b/ecs/src/model/ModifySecurityGroupRuleRequest.cc index 484c74ded..07c211c4e 100644 --- a/ecs/src/model/ModifySecurityGroupRuleRequest.cc +++ b/ecs/src/model/ModifySecurityGroupRuleRequest.cc @@ -115,6 +115,15 @@ void ModifySecurityGroupRuleRequest::setRegionId(const std::string ®ionId) { setParameter(std::string("RegionId"), regionId); } +std::string ModifySecurityGroupRuleRequest::getPolicy() const { + return policy_; +} + +void ModifySecurityGroupRuleRequest::setPolicy(const std::string &policy) { + policy_ = policy; + setParameter(std::string("Policy"), policy); +} + std::string ModifySecurityGroupRuleRequest::getIpv6SourceCidrIp() const { return ipv6SourceCidrIp_; } @@ -133,15 +142,6 @@ void ModifySecurityGroupRuleRequest::setIpv6DestCidrIp(const std::string &ipv6De setParameter(std::string("Ipv6DestCidrIp"), ipv6DestCidrIp); } -std::string ModifySecurityGroupRuleRequest::getPolicy() const { - return policy_; -} - -void ModifySecurityGroupRuleRequest::setPolicy(const std::string &policy) { - policy_ = policy; - setParameter(std::string("Policy"), policy); -} - std::string ModifySecurityGroupRuleRequest::getPortRange() const { return portRange_; } diff --git a/ecs/src/model/RunCommandRequest.cc b/ecs/src/model/RunCommandRequest.cc index e558feb12..4de6b1af8 100644 --- a/ecs/src/model/RunCommandRequest.cc +++ b/ecs/src/model/RunCommandRequest.cc @@ -124,6 +124,20 @@ void RunCommandRequest::setWindowsPasswordName(const std::string &windowsPasswor setParameter(std::string("WindowsPasswordName"), windowsPasswordName); } +std::vector RunCommandRequest::getTag() const { + return tag_; +} + +void RunCommandRequest::setTag(const std::vector &tag) { + tag_ = tag; + for(int dep1 = 0; dep1 != tag.size(); dep1++) { + auto tagObj = tag.at(dep1); + std::string tagObjStr = std::string("Tag") + "." + std::to_string(dep1 + 1); + setParameter(tagObjStr + ".Key", tagObj.key); + setParameter(tagObjStr + ".Value", tagObj.value); + } +} + bool RunCommandRequest::getKeepCommand() const { return keepCommand_; }