From d80ca0d7e2d8b48407f62a1f5017ce9c1022e436 Mon Sep 17 00:00:00 2001 From: sdk-team Date: Tue, 11 Jun 2024 02:26:46 +0000 Subject: [PATCH] Generated 2023-01-20 for csas. --- VERSION | 2 +- csas/CMakeLists.txt | 8 + csas/include/alibabacloud/csas/CsasClient.h | 16 ++ .../csas/model/DeleteUserDevicesRequest.h | 45 +++++ .../csas/model/DeleteUserDevicesResult.h | 49 +++++ .../csas/model/ExportUserDevicesRequest.h | 87 ++++++++ .../csas/model/ExportUserDevicesResult.h | 51 +++++ csas/src/CsasClient.cc | 72 +++++++ csas/src/model/DeleteUserDevicesRequest.cc | 47 +++++ csas/src/model/DeleteUserDevicesResult.cc | 44 +++++ csas/src/model/ExportUserDevicesRequest.cc | 187 ++++++++++++++++++ csas/src/model/ExportUserDevicesResult.cc | 51 +++++ 12 files changed, 658 insertions(+), 1 deletion(-) create mode 100644 csas/include/alibabacloud/csas/model/DeleteUserDevicesRequest.h create mode 100644 csas/include/alibabacloud/csas/model/DeleteUserDevicesResult.h create mode 100644 csas/include/alibabacloud/csas/model/ExportUserDevicesRequest.h create mode 100644 csas/include/alibabacloud/csas/model/ExportUserDevicesResult.h create mode 100644 csas/src/model/DeleteUserDevicesRequest.cc create mode 100644 csas/src/model/DeleteUserDevicesResult.cc create mode 100644 csas/src/model/ExportUserDevicesRequest.cc create mode 100644 csas/src/model/ExportUserDevicesResult.cc diff --git a/VERSION b/VERSION index d8406d280..38e9c692d 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.36.1926 \ No newline at end of file +1.36.1927 \ No newline at end of file diff --git a/csas/CMakeLists.txt b/csas/CMakeLists.txt index be03ec7c8..d24ecf466 100644 --- a/csas/CMakeLists.txt +++ b/csas/CMakeLists.txt @@ -53,10 +53,14 @@ set(csas_public_header_model include/alibabacloud/csas/model/DeletePrivateAccessTagResult.h include/alibabacloud/csas/model/DeleteRegistrationPoliciesRequest.h include/alibabacloud/csas/model/DeleteRegistrationPoliciesResult.h + include/alibabacloud/csas/model/DeleteUserDevicesRequest.h + include/alibabacloud/csas/model/DeleteUserDevicesResult.h include/alibabacloud/csas/model/DeleteUserGroupRequest.h include/alibabacloud/csas/model/DeleteUserGroupResult.h include/alibabacloud/csas/model/DetachApplication2ConnectorRequest.h include/alibabacloud/csas/model/DetachApplication2ConnectorResult.h + include/alibabacloud/csas/model/ExportUserDevicesRequest.h + include/alibabacloud/csas/model/ExportUserDevicesResult.h include/alibabacloud/csas/model/GetActiveIdpConfigRequest.h include/alibabacloud/csas/model/GetActiveIdpConfigResult.h include/alibabacloud/csas/model/GetClientUserRequest.h @@ -194,10 +198,14 @@ set(csas_src src/model/DeletePrivateAccessTagResult.cc src/model/DeleteRegistrationPoliciesRequest.cc src/model/DeleteRegistrationPoliciesResult.cc + src/model/DeleteUserDevicesRequest.cc + src/model/DeleteUserDevicesResult.cc src/model/DeleteUserGroupRequest.cc src/model/DeleteUserGroupResult.cc src/model/DetachApplication2ConnectorRequest.cc src/model/DetachApplication2ConnectorResult.cc + src/model/ExportUserDevicesRequest.cc + src/model/ExportUserDevicesResult.cc src/model/GetActiveIdpConfigRequest.cc src/model/GetActiveIdpConfigResult.cc src/model/GetClientUserRequest.cc diff --git a/csas/include/alibabacloud/csas/CsasClient.h b/csas/include/alibabacloud/csas/CsasClient.h index 8953ea96f..6fe911502 100644 --- a/csas/include/alibabacloud/csas/CsasClient.h +++ b/csas/include/alibabacloud/csas/CsasClient.h @@ -54,10 +54,14 @@ #include "model/DeletePrivateAccessTagResult.h" #include "model/DeleteRegistrationPoliciesRequest.h" #include "model/DeleteRegistrationPoliciesResult.h" +#include "model/DeleteUserDevicesRequest.h" +#include "model/DeleteUserDevicesResult.h" #include "model/DeleteUserGroupRequest.h" #include "model/DeleteUserGroupResult.h" #include "model/DetachApplication2ConnectorRequest.h" #include "model/DetachApplication2ConnectorResult.h" +#include "model/ExportUserDevicesRequest.h" +#include "model/ExportUserDevicesResult.h" #include "model/GetActiveIdpConfigRequest.h" #include "model/GetActiveIdpConfigResult.h" #include "model/GetClientUserRequest.h" @@ -217,12 +221,18 @@ namespace AlibabaCloud typedef Outcome DeleteRegistrationPoliciesOutcome; typedef std::future DeleteRegistrationPoliciesOutcomeCallable; typedef std::function&)> DeleteRegistrationPoliciesAsyncHandler; + typedef Outcome DeleteUserDevicesOutcome; + typedef std::future DeleteUserDevicesOutcomeCallable; + typedef std::function&)> DeleteUserDevicesAsyncHandler; typedef Outcome DeleteUserGroupOutcome; typedef std::future DeleteUserGroupOutcomeCallable; typedef std::function&)> DeleteUserGroupAsyncHandler; typedef Outcome DetachApplication2ConnectorOutcome; typedef std::future DetachApplication2ConnectorOutcomeCallable; typedef std::function&)> DetachApplication2ConnectorAsyncHandler; + typedef Outcome ExportUserDevicesOutcome; + typedef std::future ExportUserDevicesOutcomeCallable; + typedef std::function&)> ExportUserDevicesAsyncHandler; typedef Outcome GetActiveIdpConfigOutcome; typedef std::future GetActiveIdpConfigOutcomeCallable; typedef std::function&)> GetActiveIdpConfigAsyncHandler; @@ -429,12 +439,18 @@ namespace AlibabaCloud DeleteRegistrationPoliciesOutcome deleteRegistrationPolicies(const Model::DeleteRegistrationPoliciesRequest &request)const; void deleteRegistrationPoliciesAsync(const Model::DeleteRegistrationPoliciesRequest& request, const DeleteRegistrationPoliciesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DeleteRegistrationPoliciesOutcomeCallable deleteRegistrationPoliciesCallable(const Model::DeleteRegistrationPoliciesRequest& request) const; + DeleteUserDevicesOutcome deleteUserDevices(const Model::DeleteUserDevicesRequest &request)const; + void deleteUserDevicesAsync(const Model::DeleteUserDevicesRequest& request, const DeleteUserDevicesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DeleteUserDevicesOutcomeCallable deleteUserDevicesCallable(const Model::DeleteUserDevicesRequest& request) const; DeleteUserGroupOutcome deleteUserGroup(const Model::DeleteUserGroupRequest &request)const; void deleteUserGroupAsync(const Model::DeleteUserGroupRequest& request, const DeleteUserGroupAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DeleteUserGroupOutcomeCallable deleteUserGroupCallable(const Model::DeleteUserGroupRequest& request) const; DetachApplication2ConnectorOutcome detachApplication2Connector(const Model::DetachApplication2ConnectorRequest &request)const; void detachApplication2ConnectorAsync(const Model::DetachApplication2ConnectorRequest& request, const DetachApplication2ConnectorAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DetachApplication2ConnectorOutcomeCallable detachApplication2ConnectorCallable(const Model::DetachApplication2ConnectorRequest& request) const; + ExportUserDevicesOutcome exportUserDevices(const Model::ExportUserDevicesRequest &request)const; + void exportUserDevicesAsync(const Model::ExportUserDevicesRequest& request, const ExportUserDevicesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + ExportUserDevicesOutcomeCallable exportUserDevicesCallable(const Model::ExportUserDevicesRequest& request) const; GetActiveIdpConfigOutcome getActiveIdpConfig(const Model::GetActiveIdpConfigRequest &request)const; void getActiveIdpConfigAsync(const Model::GetActiveIdpConfigRequest& request, const GetActiveIdpConfigAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; GetActiveIdpConfigOutcomeCallable getActiveIdpConfigCallable(const Model::GetActiveIdpConfigRequest& request) const; diff --git a/csas/include/alibabacloud/csas/model/DeleteUserDevicesRequest.h b/csas/include/alibabacloud/csas/model/DeleteUserDevicesRequest.h new file mode 100644 index 000000000..5a7266f26 --- /dev/null +++ b/csas/include/alibabacloud/csas/model/DeleteUserDevicesRequest.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_CSAS_MODEL_DELETEUSERDEVICESREQUEST_H_ +#define ALIBABACLOUD_CSAS_MODEL_DELETEUSERDEVICESREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Csas { +namespace Model { +class ALIBABACLOUD_CSAS_EXPORT DeleteUserDevicesRequest : public RpcServiceRequest { +public: + DeleteUserDevicesRequest(); + ~DeleteUserDevicesRequest(); + std::vector getDeviceTags() const; + void setDeviceTags(const std::vector &deviceTags); + std::string getSourceIp() const; + void setSourceIp(const std::string &sourceIp); + +private: + std::vector deviceTags_; + std::string sourceIp_; +}; +} // namespace Model +} // namespace Csas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_CSAS_MODEL_DELETEUSERDEVICESREQUEST_H_ diff --git a/csas/include/alibabacloud/csas/model/DeleteUserDevicesResult.h b/csas/include/alibabacloud/csas/model/DeleteUserDevicesResult.h new file mode 100644 index 000000000..351c3274b --- /dev/null +++ b/csas/include/alibabacloud/csas/model/DeleteUserDevicesResult.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_CSAS_MODEL_DELETEUSERDEVICESRESULT_H_ +#define ALIBABACLOUD_CSAS_MODEL_DELETEUSERDEVICESRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Csas + { + namespace Model + { + class ALIBABACLOUD_CSAS_EXPORT DeleteUserDevicesResult : public ServiceResult + { + public: + + + DeleteUserDevicesResult(); + explicit DeleteUserDevicesResult(const std::string &payload); + ~DeleteUserDevicesResult(); + + protected: + void parse(const std::string &payload); + private: + + }; + } + } +} +#endif // !ALIBABACLOUD_CSAS_MODEL_DELETEUSERDEVICESRESULT_H_ \ No newline at end of file diff --git a/csas/include/alibabacloud/csas/model/ExportUserDevicesRequest.h b/csas/include/alibabacloud/csas/model/ExportUserDevicesRequest.h new file mode 100644 index 000000000..8d36d83ba --- /dev/null +++ b/csas/include/alibabacloud/csas/model/ExportUserDevicesRequest.h @@ -0,0 +1,87 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_CSAS_MODEL_EXPORTUSERDEVICESREQUEST_H_ +#define ALIBABACLOUD_CSAS_MODEL_EXPORTUSERDEVICESREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Csas { +namespace Model { +class ALIBABACLOUD_CSAS_EXPORT ExportUserDevicesRequest : public RpcServiceRequest { +public: + ExportUserDevicesRequest(); + ~ExportUserDevicesRequest(); + std::string getMac() const; + void setMac(const std::string &mac); + std::vector getDeviceTypes() const; + void setDeviceTypes(const std::vector &deviceTypes); + std::string getHostname() const; + void setHostname(const std::string &hostname); + std::vector getAppStatuses() const; + void setAppStatuses(const std::vector &appStatuses); + std::vector getDlpStatuses() const; + void setDlpStatuses(const std::vector &dlpStatuses); + std::string getSourceIp() const; + void setSourceIp(const std::string &sourceIp); + std::string getSaseUserId() const; + void setSaseUserId(const std::string &saseUserId); + std::vector getNacStatuses() const; + void setNacStatuses(const std::vector &nacStatuses); + std::string getDepartment() const; + void setDepartment(const std::string &department); + std::vector getIaStatuses() const; + void setIaStatuses(const std::vector &iaStatuses); + std::string getDeviceBelong() const; + void setDeviceBelong(const std::string &deviceBelong); + bool getSharingStatus() const; + void setSharingStatus(bool sharingStatus); + std::vector getDeviceTags() const; + void setDeviceTags(const std::vector &deviceTags); + std::vector getDeviceStatuses() const; + void setDeviceStatuses(const std::vector &deviceStatuses); + std::vector getPaStatuses() const; + void setPaStatuses(const std::vector &paStatuses); + std::string getUsername() const; + void setUsername(const std::string &username); + +private: + std::string mac_; + std::vector deviceTypes_; + std::string hostname_; + std::vector appStatuses_; + std::vector dlpStatuses_; + std::string sourceIp_; + std::string saseUserId_; + std::vector nacStatuses_; + std::string department_; + std::vector iaStatuses_; + std::string deviceBelong_; + bool sharingStatus_; + std::vector deviceTags_; + std::vector deviceStatuses_; + std::vector paStatuses_; + std::string username_; +}; +} // namespace Model +} // namespace Csas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_CSAS_MODEL_EXPORTUSERDEVICESREQUEST_H_ diff --git a/csas/include/alibabacloud/csas/model/ExportUserDevicesResult.h b/csas/include/alibabacloud/csas/model/ExportUserDevicesResult.h new file mode 100644 index 000000000..71c6dfa43 --- /dev/null +++ b/csas/include/alibabacloud/csas/model/ExportUserDevicesResult.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_CSAS_MODEL_EXPORTUSERDEVICESRESULT_H_ +#define ALIBABACLOUD_CSAS_MODEL_EXPORTUSERDEVICESRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Csas + { + namespace Model + { + class ALIBABACLOUD_CSAS_EXPORT ExportUserDevicesResult : public ServiceResult + { + public: + + + ExportUserDevicesResult(); + explicit ExportUserDevicesResult(const std::string &payload); + ~ExportUserDevicesResult(); + std::string getSignedUrl()const; + + protected: + void parse(const std::string &payload); + private: + std::string signedUrl_; + + }; + } + } +} +#endif // !ALIBABACLOUD_CSAS_MODEL_EXPORTUSERDEVICESRESULT_H_ \ No newline at end of file diff --git a/csas/src/CsasClient.cc b/csas/src/CsasClient.cc index b0cb7ed5d..f352ebd6f 100644 --- a/csas/src/CsasClient.cc +++ b/csas/src/CsasClient.cc @@ -627,6 +627,42 @@ CsasClient::DeleteRegistrationPoliciesOutcomeCallable CsasClient::deleteRegistra return task->get_future(); } +CsasClient::DeleteUserDevicesOutcome CsasClient::deleteUserDevices(const DeleteUserDevicesRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DeleteUserDevicesOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DeleteUserDevicesOutcome(DeleteUserDevicesResult(outcome.result())); + else + return DeleteUserDevicesOutcome(outcome.error()); +} + +void CsasClient::deleteUserDevicesAsync(const DeleteUserDevicesRequest& request, const DeleteUserDevicesAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, deleteUserDevices(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +CsasClient::DeleteUserDevicesOutcomeCallable CsasClient::deleteUserDevicesCallable(const DeleteUserDevicesRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->deleteUserDevices(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + CsasClient::DeleteUserGroupOutcome CsasClient::deleteUserGroup(const DeleteUserGroupRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -699,6 +735,42 @@ CsasClient::DetachApplication2ConnectorOutcomeCallable CsasClient::detachApplica return task->get_future(); } +CsasClient::ExportUserDevicesOutcome CsasClient::exportUserDevices(const ExportUserDevicesRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return ExportUserDevicesOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return ExportUserDevicesOutcome(ExportUserDevicesResult(outcome.result())); + else + return ExportUserDevicesOutcome(outcome.error()); +} + +void CsasClient::exportUserDevicesAsync(const ExportUserDevicesRequest& request, const ExportUserDevicesAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, exportUserDevices(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +CsasClient::ExportUserDevicesOutcomeCallable CsasClient::exportUserDevicesCallable(const ExportUserDevicesRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->exportUserDevices(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + CsasClient::GetActiveIdpConfigOutcome CsasClient::getActiveIdpConfig(const GetActiveIdpConfigRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); diff --git a/csas/src/model/DeleteUserDevicesRequest.cc b/csas/src/model/DeleteUserDevicesRequest.cc new file mode 100644 index 000000000..d48a2136d --- /dev/null +++ b/csas/src/model/DeleteUserDevicesRequest.cc @@ -0,0 +1,47 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT 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::Csas::Model::DeleteUserDevicesRequest; + +DeleteUserDevicesRequest::DeleteUserDevicesRequest() + : RpcServiceRequest("csas", "2023-01-20", "DeleteUserDevices") { + setMethod(HttpRequest::Method::Post); +} + +DeleteUserDevicesRequest::~DeleteUserDevicesRequest() {} + +std::vector DeleteUserDevicesRequest::getDeviceTags() const { + return deviceTags_; +} + +void DeleteUserDevicesRequest::setDeviceTags(const std::vector &deviceTags) { + deviceTags_ = deviceTags; + for(int dep1 = 0; dep1 != deviceTags.size(); dep1++) { + setBodyParameter(std::string("DeviceTags") + "." + std::to_string(dep1 + 1), deviceTags[dep1]); + } +} + +std::string DeleteUserDevicesRequest::getSourceIp() const { + return sourceIp_; +} + +void DeleteUserDevicesRequest::setSourceIp(const std::string &sourceIp) { + sourceIp_ = sourceIp; + setParameter(std::string("SourceIp"), sourceIp); +} + diff --git a/csas/src/model/DeleteUserDevicesResult.cc b/csas/src/model/DeleteUserDevicesResult.cc new file mode 100644 index 000000000..452f19b15 --- /dev/null +++ b/csas/src/model/DeleteUserDevicesResult.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::Csas; +using namespace AlibabaCloud::Csas::Model; + +DeleteUserDevicesResult::DeleteUserDevicesResult() : + ServiceResult() +{} + +DeleteUserDevicesResult::DeleteUserDevicesResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DeleteUserDevicesResult::~DeleteUserDevicesResult() +{} + +void DeleteUserDevicesResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + +} + diff --git a/csas/src/model/ExportUserDevicesRequest.cc b/csas/src/model/ExportUserDevicesRequest.cc new file mode 100644 index 000000000..ef869a8dc --- /dev/null +++ b/csas/src/model/ExportUserDevicesRequest.cc @@ -0,0 +1,187 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT 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::Csas::Model::ExportUserDevicesRequest; + +ExportUserDevicesRequest::ExportUserDevicesRequest() + : RpcServiceRequest("csas", "2023-01-20", "ExportUserDevices") { + setMethod(HttpRequest::Method::Post); +} + +ExportUserDevicesRequest::~ExportUserDevicesRequest() {} + +std::string ExportUserDevicesRequest::getMac() const { + return mac_; +} + +void ExportUserDevicesRequest::setMac(const std::string &mac) { + mac_ = mac; + setBodyParameter(std::string("Mac"), mac); +} + +std::vector ExportUserDevicesRequest::getDeviceTypes() const { + return deviceTypes_; +} + +void ExportUserDevicesRequest::setDeviceTypes(const std::vector &deviceTypes) { + deviceTypes_ = deviceTypes; + for(int dep1 = 0; dep1 != deviceTypes.size(); dep1++) { + setBodyParameter(std::string("DeviceTypes") + "." + std::to_string(dep1 + 1), deviceTypes[dep1]); + } +} + +std::string ExportUserDevicesRequest::getHostname() const { + return hostname_; +} + +void ExportUserDevicesRequest::setHostname(const std::string &hostname) { + hostname_ = hostname; + setBodyParameter(std::string("Hostname"), hostname); +} + +std::vector ExportUserDevicesRequest::getAppStatuses() const { + return appStatuses_; +} + +void ExportUserDevicesRequest::setAppStatuses(const std::vector &appStatuses) { + appStatuses_ = appStatuses; + for(int dep1 = 0; dep1 != appStatuses.size(); dep1++) { + setBodyParameter(std::string("AppStatuses") + "." + std::to_string(dep1 + 1), appStatuses[dep1]); + } +} + +std::vector ExportUserDevicesRequest::getDlpStatuses() const { + return dlpStatuses_; +} + +void ExportUserDevicesRequest::setDlpStatuses(const std::vector &dlpStatuses) { + dlpStatuses_ = dlpStatuses; + for(int dep1 = 0; dep1 != dlpStatuses.size(); dep1++) { + setBodyParameter(std::string("DlpStatuses") + "." + std::to_string(dep1 + 1), dlpStatuses[dep1]); + } +} + +std::string ExportUserDevicesRequest::getSourceIp() const { + return sourceIp_; +} + +void ExportUserDevicesRequest::setSourceIp(const std::string &sourceIp) { + sourceIp_ = sourceIp; + setParameter(std::string("SourceIp"), sourceIp); +} + +std::string ExportUserDevicesRequest::getSaseUserId() const { + return saseUserId_; +} + +void ExportUserDevicesRequest::setSaseUserId(const std::string &saseUserId) { + saseUserId_ = saseUserId; + setBodyParameter(std::string("SaseUserId"), saseUserId); +} + +std::vector ExportUserDevicesRequest::getNacStatuses() const { + return nacStatuses_; +} + +void ExportUserDevicesRequest::setNacStatuses(const std::vector &nacStatuses) { + nacStatuses_ = nacStatuses; + for(int dep1 = 0; dep1 != nacStatuses.size(); dep1++) { + setBodyParameter(std::string("NacStatuses") + "." + std::to_string(dep1 + 1), nacStatuses[dep1]); + } +} + +std::string ExportUserDevicesRequest::getDepartment() const { + return department_; +} + +void ExportUserDevicesRequest::setDepartment(const std::string &department) { + department_ = department; + setBodyParameter(std::string("Department"), department); +} + +std::vector ExportUserDevicesRequest::getIaStatuses() const { + return iaStatuses_; +} + +void ExportUserDevicesRequest::setIaStatuses(const std::vector &iaStatuses) { + iaStatuses_ = iaStatuses; + for(int dep1 = 0; dep1 != iaStatuses.size(); dep1++) { + setBodyParameter(std::string("IaStatuses") + "." + std::to_string(dep1 + 1), iaStatuses[dep1]); + } +} + +std::string ExportUserDevicesRequest::getDeviceBelong() const { + return deviceBelong_; +} + +void ExportUserDevicesRequest::setDeviceBelong(const std::string &deviceBelong) { + deviceBelong_ = deviceBelong; + setBodyParameter(std::string("DeviceBelong"), deviceBelong); +} + +bool ExportUserDevicesRequest::getSharingStatus() const { + return sharingStatus_; +} + +void ExportUserDevicesRequest::setSharingStatus(bool sharingStatus) { + sharingStatus_ = sharingStatus; + setBodyParameter(std::string("SharingStatus"), sharingStatus ? "true" : "false"); +} + +std::vector ExportUserDevicesRequest::getDeviceTags() const { + return deviceTags_; +} + +void ExportUserDevicesRequest::setDeviceTags(const std::vector &deviceTags) { + deviceTags_ = deviceTags; + for(int dep1 = 0; dep1 != deviceTags.size(); dep1++) { + setBodyParameter(std::string("DeviceTags") + "." + std::to_string(dep1 + 1), deviceTags[dep1]); + } +} + +std::vector ExportUserDevicesRequest::getDeviceStatuses() const { + return deviceStatuses_; +} + +void ExportUserDevicesRequest::setDeviceStatuses(const std::vector &deviceStatuses) { + deviceStatuses_ = deviceStatuses; + for(int dep1 = 0; dep1 != deviceStatuses.size(); dep1++) { + setBodyParameter(std::string("DeviceStatuses") + "." + std::to_string(dep1 + 1), deviceStatuses[dep1]); + } +} + +std::vector ExportUserDevicesRequest::getPaStatuses() const { + return paStatuses_; +} + +void ExportUserDevicesRequest::setPaStatuses(const std::vector &paStatuses) { + paStatuses_ = paStatuses; + for(int dep1 = 0; dep1 != paStatuses.size(); dep1++) { + setBodyParameter(std::string("PaStatuses") + "." + std::to_string(dep1 + 1), paStatuses[dep1]); + } +} + +std::string ExportUserDevicesRequest::getUsername() const { + return username_; +} + +void ExportUserDevicesRequest::setUsername(const std::string &username) { + username_ = username; + setBodyParameter(std::string("Username"), username); +} + diff --git a/csas/src/model/ExportUserDevicesResult.cc b/csas/src/model/ExportUserDevicesResult.cc new file mode 100644 index 000000000..caf963bf5 --- /dev/null +++ b/csas/src/model/ExportUserDevicesResult.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::Csas; +using namespace AlibabaCloud::Csas::Model; + +ExportUserDevicesResult::ExportUserDevicesResult() : + ServiceResult() +{} + +ExportUserDevicesResult::ExportUserDevicesResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +ExportUserDevicesResult::~ExportUserDevicesResult() +{} + +void ExportUserDevicesResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["SignedUrl"].isNull()) + signedUrl_ = value["SignedUrl"].asString(); + +} + +std::string ExportUserDevicesResult::getSignedUrl()const +{ + return signedUrl_; +} +