diff --git a/VERSION b/VERSION index 869629173..c4c6434c5 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.36.1260 \ No newline at end of file +1.36.1261 \ No newline at end of file diff --git a/iot/CMakeLists.txt b/iot/CMakeLists.txt index 07a5174d7..c399e0b73 100644 --- a/iot/CMakeLists.txt +++ b/iot/CMakeLists.txt @@ -129,6 +129,8 @@ set(iot_public_header_model include/alibabacloud/iot/model/ConfirmOTATaskResult.h include/alibabacloud/iot/model/CopyThingModelRequest.h include/alibabacloud/iot/model/CopyThingModelResult.h + include/alibabacloud/iot/model/CountSpeechBroadcastHourRequest.h + include/alibabacloud/iot/model/CountSpeechBroadcastHourResult.h include/alibabacloud/iot/model/CreateConsumerGroupRequest.h include/alibabacloud/iot/model/CreateConsumerGroupResult.h include/alibabacloud/iot/model/CreateConsumerGroupSubscribeRelationRequest.h @@ -447,6 +449,8 @@ set(iot_public_header_model include/alibabacloud/iot/model/PackageSoundCodeLabelBatchAudioResult.h include/alibabacloud/iot/model/PageQuerySharedSpeechOpenRequest.h include/alibabacloud/iot/model/PageQuerySharedSpeechOpenResult.h + include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourRequest.h + include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourResult.h include/alibabacloud/iot/model/PrintByTemplateRequest.h include/alibabacloud/iot/model/PrintByTemplateResult.h include/alibabacloud/iot/model/PubRequest.h @@ -902,6 +906,8 @@ set(iot_src src/model/ConfirmOTATaskResult.cc src/model/CopyThingModelRequest.cc src/model/CopyThingModelResult.cc + src/model/CountSpeechBroadcastHourRequest.cc + src/model/CountSpeechBroadcastHourResult.cc src/model/CreateConsumerGroupRequest.cc src/model/CreateConsumerGroupResult.cc src/model/CreateConsumerGroupSubscribeRelationRequest.cc @@ -1220,6 +1226,8 @@ set(iot_src src/model/PackageSoundCodeLabelBatchAudioResult.cc src/model/PageQuerySharedSpeechOpenRequest.cc src/model/PageQuerySharedSpeechOpenResult.cc + src/model/PageQuerySpeechBroadcastHourRequest.cc + src/model/PageQuerySpeechBroadcastHourResult.cc src/model/PrintByTemplateRequest.cc src/model/PrintByTemplateResult.cc src/model/PubRequest.cc diff --git a/iot/include/alibabacloud/iot/IotClient.h b/iot/include/alibabacloud/iot/IotClient.h index c5ad6dfa4..57e0a6136 100644 --- a/iot/include/alibabacloud/iot/IotClient.h +++ b/iot/include/alibabacloud/iot/IotClient.h @@ -130,6 +130,8 @@ #include "model/ConfirmOTATaskResult.h" #include "model/CopyThingModelRequest.h" #include "model/CopyThingModelResult.h" +#include "model/CountSpeechBroadcastHourRequest.h" +#include "model/CountSpeechBroadcastHourResult.h" #include "model/CreateConsumerGroupRequest.h" #include "model/CreateConsumerGroupResult.h" #include "model/CreateConsumerGroupSubscribeRelationRequest.h" @@ -448,6 +450,8 @@ #include "model/PackageSoundCodeLabelBatchAudioResult.h" #include "model/PageQuerySharedSpeechOpenRequest.h" #include "model/PageQuerySharedSpeechOpenResult.h" +#include "model/PageQuerySpeechBroadcastHourRequest.h" +#include "model/PageQuerySpeechBroadcastHourResult.h" #include "model/PrintByTemplateRequest.h" #include "model/PrintByTemplateResult.h" #include "model/PubRequest.h" @@ -963,6 +967,9 @@ namespace AlibabaCloud typedef Outcome CopyThingModelOutcome; typedef std::future CopyThingModelOutcomeCallable; typedef std::function&)> CopyThingModelAsyncHandler; + typedef Outcome CountSpeechBroadcastHourOutcome; + typedef std::future CountSpeechBroadcastHourOutcomeCallable; + typedef std::function&)> CountSpeechBroadcastHourAsyncHandler; typedef Outcome CreateConsumerGroupOutcome; typedef std::future CreateConsumerGroupOutcomeCallable; typedef std::function&)> CreateConsumerGroupAsyncHandler; @@ -1440,6 +1447,9 @@ namespace AlibabaCloud typedef Outcome PageQuerySharedSpeechOpenOutcome; typedef std::future PageQuerySharedSpeechOpenOutcomeCallable; typedef std::function&)> PageQuerySharedSpeechOpenAsyncHandler; + typedef Outcome PageQuerySpeechBroadcastHourOutcome; + typedef std::future PageQuerySpeechBroadcastHourOutcomeCallable; + typedef std::function&)> PageQuerySpeechBroadcastHourAsyncHandler; typedef Outcome PrintByTemplateOutcome; typedef std::future PrintByTemplateOutcomeCallable; typedef std::function&)> PrintByTemplateAsyncHandler; @@ -2123,6 +2133,9 @@ namespace AlibabaCloud CopyThingModelOutcome copyThingModel(const Model::CopyThingModelRequest &request)const; void copyThingModelAsync(const Model::CopyThingModelRequest& request, const CopyThingModelAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CopyThingModelOutcomeCallable copyThingModelCallable(const Model::CopyThingModelRequest& request) const; + CountSpeechBroadcastHourOutcome countSpeechBroadcastHour(const Model::CountSpeechBroadcastHourRequest &request)const; + void countSpeechBroadcastHourAsync(const Model::CountSpeechBroadcastHourRequest& request, const CountSpeechBroadcastHourAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CountSpeechBroadcastHourOutcomeCallable countSpeechBroadcastHourCallable(const Model::CountSpeechBroadcastHourRequest& request) const; CreateConsumerGroupOutcome createConsumerGroup(const Model::CreateConsumerGroupRequest &request)const; void createConsumerGroupAsync(const Model::CreateConsumerGroupRequest& request, const CreateConsumerGroupAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateConsumerGroupOutcomeCallable createConsumerGroupCallable(const Model::CreateConsumerGroupRequest& request) const; @@ -2600,6 +2613,9 @@ namespace AlibabaCloud PageQuerySharedSpeechOpenOutcome pageQuerySharedSpeechOpen(const Model::PageQuerySharedSpeechOpenRequest &request)const; void pageQuerySharedSpeechOpenAsync(const Model::PageQuerySharedSpeechOpenRequest& request, const PageQuerySharedSpeechOpenAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; PageQuerySharedSpeechOpenOutcomeCallable pageQuerySharedSpeechOpenCallable(const Model::PageQuerySharedSpeechOpenRequest& request) const; + PageQuerySpeechBroadcastHourOutcome pageQuerySpeechBroadcastHour(const Model::PageQuerySpeechBroadcastHourRequest &request)const; + void pageQuerySpeechBroadcastHourAsync(const Model::PageQuerySpeechBroadcastHourRequest& request, const PageQuerySpeechBroadcastHourAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + PageQuerySpeechBroadcastHourOutcomeCallable pageQuerySpeechBroadcastHourCallable(const Model::PageQuerySpeechBroadcastHourRequest& request) const; PrintByTemplateOutcome printByTemplate(const Model::PrintByTemplateRequest &request)const; void printByTemplateAsync(const Model::PrintByTemplateRequest& request, const PrintByTemplateAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; PrintByTemplateOutcomeCallable printByTemplateCallable(const Model::PrintByTemplateRequest& request) const; diff --git a/iot/include/alibabacloud/iot/model/CountSpeechBroadcastHourRequest.h b/iot/include/alibabacloud/iot/model/CountSpeechBroadcastHourRequest.h new file mode 100644 index 000000000..dd0f5b20c --- /dev/null +++ b/iot/include/alibabacloud/iot/model/CountSpeechBroadcastHourRequest.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_IOT_MODEL_COUNTSPEECHBROADCASTHOURREQUEST_H_ +#define ALIBABACLOUD_IOT_MODEL_COUNTSPEECHBROADCASTHOURREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Iot + { + namespace Model + { + class ALIBABACLOUD_IOT_EXPORT CountSpeechBroadcastHourRequest : public RpcServiceRequest + { + + public: + CountSpeechBroadcastHourRequest(); + ~CountSpeechBroadcastHourRequest(); + + std::string getQueryDateTimeHour()const; + void setQueryDateTimeHour(const std::string& queryDateTimeHour); + std::string getIotInstanceId()const; + void setIotInstanceId(const std::string& iotInstanceId); + std::string getShareTaskCode()const; + void setShareTaskCode(const std::string& shareTaskCode); + std::string getApiProduct()const; + void setApiProduct(const std::string& apiProduct); + std::string getApiRevision()const; + void setApiRevision(const std::string& apiRevision); + + private: + std::string queryDateTimeHour_; + std::string iotInstanceId_; + std::string shareTaskCode_; + std::string apiProduct_; + std::string apiRevision_; + + }; + } + } +} +#endif // !ALIBABACLOUD_IOT_MODEL_COUNTSPEECHBROADCASTHOURREQUEST_H_ \ No newline at end of file diff --git a/iot/include/alibabacloud/iot/model/CountSpeechBroadcastHourResult.h b/iot/include/alibabacloud/iot/model/CountSpeechBroadcastHourResult.h new file mode 100644 index 000000000..c2ef89d18 --- /dev/null +++ b/iot/include/alibabacloud/iot/model/CountSpeechBroadcastHourResult.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_IOT_MODEL_COUNTSPEECHBROADCASTHOURRESULT_H_ +#define ALIBABACLOUD_IOT_MODEL_COUNTSPEECHBROADCASTHOURRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Iot + { + namespace Model + { + class ALIBABACLOUD_IOT_EXPORT CountSpeechBroadcastHourResult : public ServiceResult + { + public: + + + CountSpeechBroadcastHourResult(); + explicit CountSpeechBroadcastHourResult(const std::string &payload); + ~CountSpeechBroadcastHourResult(); + int getData()const; + std::string getErrorMessage()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + int data_; + std::string errorMessage_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_IOT_MODEL_COUNTSPEECHBROADCASTHOURRESULT_H_ \ No newline at end of file diff --git a/iot/include/alibabacloud/iot/model/GetDestinationResult.h b/iot/include/alibabacloud/iot/model/GetDestinationResult.h index 4e17bcef1..9190abf09 100644 --- a/iot/include/alibabacloud/iot/model/GetDestinationResult.h +++ b/iot/include/alibabacloud/iot/model/GetDestinationResult.h @@ -34,6 +34,7 @@ namespace AlibabaCloud public: struct Destination { + std::string status; std::string type; std::string configuration; std::string utcCreated; diff --git a/iot/include/alibabacloud/iot/model/ListDestinationResult.h b/iot/include/alibabacloud/iot/model/ListDestinationResult.h index a64331493..318765d7f 100644 --- a/iot/include/alibabacloud/iot/model/ListDestinationResult.h +++ b/iot/include/alibabacloud/iot/model/ListDestinationResult.h @@ -34,6 +34,7 @@ namespace AlibabaCloud public: struct DestinationsItem { + std::string status; std::string type; std::string description; std::string configuration; diff --git a/iot/include/alibabacloud/iot/model/ListRuleActionsResult.h b/iot/include/alibabacloud/iot/model/ListRuleActionsResult.h index 254342cb5..6c5915092 100644 --- a/iot/include/alibabacloud/iot/model/ListRuleActionsResult.h +++ b/iot/include/alibabacloud/iot/model/ListRuleActionsResult.h @@ -34,6 +34,7 @@ namespace AlibabaCloud public: struct RuleActionInfo { + std::string status; bool errorActionFlag; std::string type; std::string configuration; diff --git a/iot/include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourRequest.h b/iot/include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourRequest.h new file mode 100644 index 000000000..8179ed4f7 --- /dev/null +++ b/iot/include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourRequest.h @@ -0,0 +1,66 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_IOT_MODEL_PAGEQUERYSPEECHBROADCASTHOURREQUEST_H_ +#define ALIBABACLOUD_IOT_MODEL_PAGEQUERYSPEECHBROADCASTHOURREQUEST_H_ + +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Iot + { + namespace Model + { + class ALIBABACLOUD_IOT_EXPORT PageQuerySpeechBroadcastHourRequest : public RpcServiceRequest + { + + public: + PageQuerySpeechBroadcastHourRequest(); + ~PageQuerySpeechBroadcastHourRequest(); + + std::string getQueryDateTimeHour()const; + void setQueryDateTimeHour(const std::string& queryDateTimeHour); + std::string getIotInstanceId()const; + void setIotInstanceId(const std::string& iotInstanceId); + int getPageSize()const; + void setPageSize(int pageSize); + std::string getPageToken()const; + void setPageToken(const std::string& pageToken); + std::string getShareTaskCode()const; + void setShareTaskCode(const std::string& shareTaskCode); + std::string getApiProduct()const; + void setApiProduct(const std::string& apiProduct); + std::string getApiRevision()const; + void setApiRevision(const std::string& apiRevision); + + private: + std::string queryDateTimeHour_; + std::string iotInstanceId_; + int pageSize_; + std::string pageToken_; + std::string shareTaskCode_; + std::string apiProduct_; + std::string apiRevision_; + + }; + } + } +} +#endif // !ALIBABACLOUD_IOT_MODEL_PAGEQUERYSPEECHBROADCASTHOURREQUEST_H_ \ No newline at end of file diff --git a/iot/include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourResult.h b/iot/include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourResult.h new file mode 100644 index 000000000..a9ace24cd --- /dev/null +++ b/iot/include/alibabacloud/iot/model/PageQuerySpeechBroadcastHourResult.h @@ -0,0 +1,76 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_IOT_MODEL_PAGEQUERYSPEECHBROADCASTHOURRESULT_H_ +#define ALIBABACLOUD_IOT_MODEL_PAGEQUERYSPEECHBROADCASTHOURRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Iot + { + namespace Model + { + class ALIBABACLOUD_IOT_EXPORT PageQuerySpeechBroadcastHourResult : public ServiceResult + { + public: + struct Data + { + struct Data1 + { + std::string msg; + std::string shareTaskCode; + std::string speechs; + long startTime; + int code; + std::string productKey; + std::string deviceName; + std::string speechId; + }; + int pageId; + std::vector resultData; + int pageSize; + int total; + std::string pageToken; + }; + + + PageQuerySpeechBroadcastHourResult(); + explicit PageQuerySpeechBroadcastHourResult(const std::string &payload); + ~PageQuerySpeechBroadcastHourResult(); + Data getData()const; + std::string getErrorMessage()const; + std::string getCode()const; + bool getSuccess()const; + + protected: + void parse(const std::string &payload); + private: + Data data_; + std::string errorMessage_; + std::string code_; + bool success_; + + }; + } + } +} +#endif // !ALIBABACLOUD_IOT_MODEL_PAGEQUERYSPEECHBROADCASTHOURRESULT_H_ \ No newline at end of file diff --git a/iot/src/IotClient.cc b/iot/src/IotClient.cc index b8f8a2aae..092e14028 100644 --- a/iot/src/IotClient.cc +++ b/iot/src/IotClient.cc @@ -1995,6 +1995,42 @@ IotClient::CopyThingModelOutcomeCallable IotClient::copyThingModelCallable(const return task->get_future(); } +IotClient::CountSpeechBroadcastHourOutcome IotClient::countSpeechBroadcastHour(const CountSpeechBroadcastHourRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CountSpeechBroadcastHourOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CountSpeechBroadcastHourOutcome(CountSpeechBroadcastHourResult(outcome.result())); + else + return CountSpeechBroadcastHourOutcome(outcome.error()); +} + +void IotClient::countSpeechBroadcastHourAsync(const CountSpeechBroadcastHourRequest& request, const CountSpeechBroadcastHourAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, countSpeechBroadcastHour(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +IotClient::CountSpeechBroadcastHourOutcomeCallable IotClient::countSpeechBroadcastHourCallable(const CountSpeechBroadcastHourRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->countSpeechBroadcastHour(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + IotClient::CreateConsumerGroupOutcome IotClient::createConsumerGroup(const CreateConsumerGroupRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -7719,6 +7755,42 @@ IotClient::PageQuerySharedSpeechOpenOutcomeCallable IotClient::pageQuerySharedSp return task->get_future(); } +IotClient::PageQuerySpeechBroadcastHourOutcome IotClient::pageQuerySpeechBroadcastHour(const PageQuerySpeechBroadcastHourRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return PageQuerySpeechBroadcastHourOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return PageQuerySpeechBroadcastHourOutcome(PageQuerySpeechBroadcastHourResult(outcome.result())); + else + return PageQuerySpeechBroadcastHourOutcome(outcome.error()); +} + +void IotClient::pageQuerySpeechBroadcastHourAsync(const PageQuerySpeechBroadcastHourRequest& request, const PageQuerySpeechBroadcastHourAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, pageQuerySpeechBroadcastHour(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +IotClient::PageQuerySpeechBroadcastHourOutcomeCallable IotClient::pageQuerySpeechBroadcastHourCallable(const PageQuerySpeechBroadcastHourRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->pageQuerySpeechBroadcastHour(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + IotClient::PrintByTemplateOutcome IotClient::printByTemplate(const PrintByTemplateRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); diff --git a/iot/src/model/CountSpeechBroadcastHourRequest.cc b/iot/src/model/CountSpeechBroadcastHourRequest.cc new file mode 100644 index 000000000..6d758c605 --- /dev/null +++ b/iot/src/model/CountSpeechBroadcastHourRequest.cc @@ -0,0 +1,84 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Iot::Model::CountSpeechBroadcastHourRequest; + +CountSpeechBroadcastHourRequest::CountSpeechBroadcastHourRequest() : + RpcServiceRequest("iot", "2018-01-20", "CountSpeechBroadcastHour") +{ + setMethod(HttpRequest::Method::Post); +} + +CountSpeechBroadcastHourRequest::~CountSpeechBroadcastHourRequest() +{} + +std::string CountSpeechBroadcastHourRequest::getQueryDateTimeHour()const +{ + return queryDateTimeHour_; +} + +void CountSpeechBroadcastHourRequest::setQueryDateTimeHour(const std::string& queryDateTimeHour) +{ + queryDateTimeHour_ = queryDateTimeHour; + setParameter("QueryDateTimeHour", queryDateTimeHour); +} + +std::string CountSpeechBroadcastHourRequest::getIotInstanceId()const +{ + return iotInstanceId_; +} + +void CountSpeechBroadcastHourRequest::setIotInstanceId(const std::string& iotInstanceId) +{ + iotInstanceId_ = iotInstanceId; + setBodyParameter("IotInstanceId", iotInstanceId); +} + +std::string CountSpeechBroadcastHourRequest::getShareTaskCode()const +{ + return shareTaskCode_; +} + +void CountSpeechBroadcastHourRequest::setShareTaskCode(const std::string& shareTaskCode) +{ + shareTaskCode_ = shareTaskCode; + setBodyParameter("ShareTaskCode", shareTaskCode); +} + +std::string CountSpeechBroadcastHourRequest::getApiProduct()const +{ + return apiProduct_; +} + +void CountSpeechBroadcastHourRequest::setApiProduct(const std::string& apiProduct) +{ + apiProduct_ = apiProduct; + setBodyParameter("ApiProduct", apiProduct); +} + +std::string CountSpeechBroadcastHourRequest::getApiRevision()const +{ + return apiRevision_; +} + +void CountSpeechBroadcastHourRequest::setApiRevision(const std::string& apiRevision) +{ + apiRevision_ = apiRevision; + setBodyParameter("ApiRevision", apiRevision); +} + diff --git a/iot/src/model/CountSpeechBroadcastHourResult.cc b/iot/src/model/CountSpeechBroadcastHourResult.cc new file mode 100644 index 000000000..3e12e55fd --- /dev/null +++ b/iot/src/model/CountSpeechBroadcastHourResult.cc @@ -0,0 +1,72 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Iot; +using namespace AlibabaCloud::Iot::Model; + +CountSpeechBroadcastHourResult::CountSpeechBroadcastHourResult() : + ServiceResult() +{} + +CountSpeechBroadcastHourResult::CountSpeechBroadcastHourResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CountSpeechBroadcastHourResult::~CountSpeechBroadcastHourResult() +{} + +void CountSpeechBroadcastHourResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMessage"].isNull()) + errorMessage_ = value["ErrorMessage"].asString(); + if(!value["Data"].isNull()) + data_ = std::stoi(value["Data"].asString()); + +} + +int CountSpeechBroadcastHourResult::getData()const +{ + return data_; +} + +std::string CountSpeechBroadcastHourResult::getErrorMessage()const +{ + return errorMessage_; +} + +std::string CountSpeechBroadcastHourResult::getCode()const +{ + return code_; +} + +bool CountSpeechBroadcastHourResult::getSuccess()const +{ + return success_; +} + diff --git a/iot/src/model/GetDestinationResult.cc b/iot/src/model/GetDestinationResult.cc index d731555cb..21ebe65fb 100644 --- a/iot/src/model/GetDestinationResult.cc +++ b/iot/src/model/GetDestinationResult.cc @@ -52,6 +52,8 @@ void GetDestinationResult::parse(const std::string &payload) destination_.isFailover = destinationNode["IsFailover"].asString() == "true"; if(!destinationNode["UtcCreated"].isNull()) destination_.utcCreated = destinationNode["UtcCreated"].asString(); + if(!destinationNode["Status"].isNull()) + destination_.status = destinationNode["Status"].asString(); if(!value["Success"].isNull()) success_ = value["Success"].asString() == "true"; if(!value["Code"].isNull()) diff --git a/iot/src/model/ListDestinationResult.cc b/iot/src/model/ListDestinationResult.cc index c3c41b2db..88ec5e298 100644 --- a/iot/src/model/ListDestinationResult.cc +++ b/iot/src/model/ListDestinationResult.cc @@ -57,6 +57,8 @@ void ListDestinationResult::parse(const std::string &payload) destinationsObject.utcCreated = valueDestinationsdestinationsItem["UtcCreated"].asString(); if(!valueDestinationsdestinationsItem["Description"].isNull()) destinationsObject.description = valueDestinationsdestinationsItem["Description"].asString(); + if(!valueDestinationsdestinationsItem["Status"].isNull()) + destinationsObject.status = valueDestinationsdestinationsItem["Status"].asString(); destinations_.push_back(destinationsObject); } if(!value["Success"].isNull()) diff --git a/iot/src/model/ListRuleActionsResult.cc b/iot/src/model/ListRuleActionsResult.cc index 6eba47652..dbd2495f0 100644 --- a/iot/src/model/ListRuleActionsResult.cc +++ b/iot/src/model/ListRuleActionsResult.cc @@ -53,6 +53,8 @@ void ListRuleActionsResult::parse(const std::string &payload) ruleActionListObject.configuration = valueRuleActionListRuleActionInfo["Configuration"].asString(); if(!valueRuleActionListRuleActionInfo["ErrorActionFlag"].isNull()) ruleActionListObject.errorActionFlag = valueRuleActionListRuleActionInfo["ErrorActionFlag"].asString() == "true"; + if(!valueRuleActionListRuleActionInfo["Status"].isNull()) + ruleActionListObject.status = valueRuleActionListRuleActionInfo["Status"].asString(); ruleActionList_.push_back(ruleActionListObject); } if(!value["Success"].isNull()) diff --git a/iot/src/model/PageQuerySpeechBroadcastHourRequest.cc b/iot/src/model/PageQuerySpeechBroadcastHourRequest.cc new file mode 100644 index 000000000..00caa82a1 --- /dev/null +++ b/iot/src/model/PageQuerySpeechBroadcastHourRequest.cc @@ -0,0 +1,106 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Iot::Model::PageQuerySpeechBroadcastHourRequest; + +PageQuerySpeechBroadcastHourRequest::PageQuerySpeechBroadcastHourRequest() : + RpcServiceRequest("iot", "2018-01-20", "PageQuerySpeechBroadcastHour") +{ + setMethod(HttpRequest::Method::Post); +} + +PageQuerySpeechBroadcastHourRequest::~PageQuerySpeechBroadcastHourRequest() +{} + +std::string PageQuerySpeechBroadcastHourRequest::getQueryDateTimeHour()const +{ + return queryDateTimeHour_; +} + +void PageQuerySpeechBroadcastHourRequest::setQueryDateTimeHour(const std::string& queryDateTimeHour) +{ + queryDateTimeHour_ = queryDateTimeHour; + setParameter("QueryDateTimeHour", queryDateTimeHour); +} + +std::string PageQuerySpeechBroadcastHourRequest::getIotInstanceId()const +{ + return iotInstanceId_; +} + +void PageQuerySpeechBroadcastHourRequest::setIotInstanceId(const std::string& iotInstanceId) +{ + iotInstanceId_ = iotInstanceId; + setBodyParameter("IotInstanceId", iotInstanceId); +} + +int PageQuerySpeechBroadcastHourRequest::getPageSize()const +{ + return pageSize_; +} + +void PageQuerySpeechBroadcastHourRequest::setPageSize(int pageSize) +{ + pageSize_ = pageSize; + setBodyParameter("PageSize", std::to_string(pageSize)); +} + +std::string PageQuerySpeechBroadcastHourRequest::getPageToken()const +{ + return pageToken_; +} + +void PageQuerySpeechBroadcastHourRequest::setPageToken(const std::string& pageToken) +{ + pageToken_ = pageToken; + setBodyParameter("PageToken", pageToken); +} + +std::string PageQuerySpeechBroadcastHourRequest::getShareTaskCode()const +{ + return shareTaskCode_; +} + +void PageQuerySpeechBroadcastHourRequest::setShareTaskCode(const std::string& shareTaskCode) +{ + shareTaskCode_ = shareTaskCode; + setBodyParameter("ShareTaskCode", shareTaskCode); +} + +std::string PageQuerySpeechBroadcastHourRequest::getApiProduct()const +{ + return apiProduct_; +} + +void PageQuerySpeechBroadcastHourRequest::setApiProduct(const std::string& apiProduct) +{ + apiProduct_ = apiProduct; + setBodyParameter("ApiProduct", apiProduct); +} + +std::string PageQuerySpeechBroadcastHourRequest::getApiRevision()const +{ + return apiRevision_; +} + +void PageQuerySpeechBroadcastHourRequest::setApiRevision(const std::string& apiRevision) +{ + apiRevision_ = apiRevision; + setBodyParameter("ApiRevision", apiRevision); +} + diff --git a/iot/src/model/PageQuerySpeechBroadcastHourResult.cc b/iot/src/model/PageQuerySpeechBroadcastHourResult.cc new file mode 100644 index 000000000..b6c600a6d --- /dev/null +++ b/iot/src/model/PageQuerySpeechBroadcastHourResult.cc @@ -0,0 +1,101 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Iot; +using namespace AlibabaCloud::Iot::Model; + +PageQuerySpeechBroadcastHourResult::PageQuerySpeechBroadcastHourResult() : + ServiceResult() +{} + +PageQuerySpeechBroadcastHourResult::PageQuerySpeechBroadcastHourResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +PageQuerySpeechBroadcastHourResult::~PageQuerySpeechBroadcastHourResult() +{} + +void PageQuerySpeechBroadcastHourResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto dataNode = value["Data"]; + if(!dataNode["PageId"].isNull()) + data_.pageId = std::stoi(dataNode["PageId"].asString()); + if(!dataNode["PageSize"].isNull()) + data_.pageSize = std::stoi(dataNode["PageSize"].asString()); + if(!dataNode["Total"].isNull()) + data_.total = std::stoi(dataNode["Total"].asString()); + if(!dataNode["PageToken"].isNull()) + data_.pageToken = dataNode["PageToken"].asString(); + auto allResultDataNode = dataNode["ResultData"]["Data"]; + for (auto dataNodeResultDataData : allResultDataNode) + { + Data::Data1 data1Object; + if(!dataNodeResultDataData["ProductKey"].isNull()) + data1Object.productKey = dataNodeResultDataData["ProductKey"].asString(); + if(!dataNodeResultDataData["DeviceName"].isNull()) + data1Object.deviceName = dataNodeResultDataData["DeviceName"].asString(); + if(!dataNodeResultDataData["ShareTaskCode"].isNull()) + data1Object.shareTaskCode = dataNodeResultDataData["ShareTaskCode"].asString(); + if(!dataNodeResultDataData["Speechs"].isNull()) + data1Object.speechs = dataNodeResultDataData["Speechs"].asString(); + if(!dataNodeResultDataData["Code"].isNull()) + data1Object.code = std::stoi(dataNodeResultDataData["Code"].asString()); + if(!dataNodeResultDataData["Msg"].isNull()) + data1Object.msg = dataNodeResultDataData["Msg"].asString(); + if(!dataNodeResultDataData["SpeechId"].isNull()) + data1Object.speechId = dataNodeResultDataData["SpeechId"].asString(); + if(!dataNodeResultDataData["StartTime"].isNull()) + data1Object.startTime = std::stol(dataNodeResultDataData["StartTime"].asString()); + data_.resultData.push_back(data1Object); + } + if(!value["Success"].isNull()) + success_ = value["Success"].asString() == "true"; + if(!value["Code"].isNull()) + code_ = value["Code"].asString(); + if(!value["ErrorMessage"].isNull()) + errorMessage_ = value["ErrorMessage"].asString(); + +} + +PageQuerySpeechBroadcastHourResult::Data PageQuerySpeechBroadcastHourResult::getData()const +{ + return data_; +} + +std::string PageQuerySpeechBroadcastHourResult::getErrorMessage()const +{ + return errorMessage_; +} + +std::string PageQuerySpeechBroadcastHourResult::getCode()const +{ + return code_; +} + +bool PageQuerySpeechBroadcastHourResult::getSuccess()const +{ + return success_; +} +