Browse Source

Support new feature.

sdk-team 3 năm trước cách đây
mục cha
commit
5ba3ade3e4

+ 1 - 1
VERSION

@@ -1 +1 @@
-1.36.1685
+1.36.1686

+ 8 - 0
polardb/CMakeLists.txt

@@ -29,6 +29,8 @@ set(polardb_public_header_model
 	include/alibabacloud/polardb/model/CheckDBNameResult.h
 	include/alibabacloud/polardb/model/CheckKMSAuthorizedRequest.h
 	include/alibabacloud/polardb/model/CheckKMSAuthorizedResult.h
+	include/alibabacloud/polardb/model/CheckServiceLinkedRoleRequest.h
+	include/alibabacloud/polardb/model/CheckServiceLinkedRoleResult.h
 	include/alibabacloud/polardb/model/CloseAITaskRequest.h
 	include/alibabacloud/polardb/model/CloseAITaskResult.h
 	include/alibabacloud/polardb/model/CloseDBClusterMigrationRequest.h
@@ -55,6 +57,8 @@ set(polardb_public_header_model
 	include/alibabacloud/polardb/model/CreateGlobalSecurityIPGroupResult.h
 	include/alibabacloud/polardb/model/CreateParameterGroupRequest.h
 	include/alibabacloud/polardb/model/CreateParameterGroupResult.h
+	include/alibabacloud/polardb/model/CreateServiceLinkedRoleRequest.h
+	include/alibabacloud/polardb/model/CreateServiceLinkedRoleResult.h
 	include/alibabacloud/polardb/model/CreateStoragePlanRequest.h
 	include/alibabacloud/polardb/model/CreateStoragePlanResult.h
 	include/alibabacloud/polardb/model/DeleteAccountRequest.h
@@ -306,6 +310,8 @@ set(polardb_src
 	src/model/CheckDBNameResult.cc
 	src/model/CheckKMSAuthorizedRequest.cc
 	src/model/CheckKMSAuthorizedResult.cc
+	src/model/CheckServiceLinkedRoleRequest.cc
+	src/model/CheckServiceLinkedRoleResult.cc
 	src/model/CloseAITaskRequest.cc
 	src/model/CloseAITaskResult.cc
 	src/model/CloseDBClusterMigrationRequest.cc
@@ -332,6 +338,8 @@ set(polardb_src
 	src/model/CreateGlobalSecurityIPGroupResult.cc
 	src/model/CreateParameterGroupRequest.cc
 	src/model/CreateParameterGroupResult.cc
+	src/model/CreateServiceLinkedRoleRequest.cc
+	src/model/CreateServiceLinkedRoleResult.cc
 	src/model/CreateStoragePlanRequest.cc
 	src/model/CreateStoragePlanResult.cc
 	src/model/DeleteAccountRequest.cc

+ 16 - 0
polardb/include/alibabacloud/polardb/PolardbClient.h

@@ -30,6 +30,8 @@
 #include "model/CheckDBNameResult.h"
 #include "model/CheckKMSAuthorizedRequest.h"
 #include "model/CheckKMSAuthorizedResult.h"
+#include "model/CheckServiceLinkedRoleRequest.h"
+#include "model/CheckServiceLinkedRoleResult.h"
 #include "model/CloseAITaskRequest.h"
 #include "model/CloseAITaskResult.h"
 #include "model/CloseDBClusterMigrationRequest.h"
@@ -56,6 +58,8 @@
 #include "model/CreateGlobalSecurityIPGroupResult.h"
 #include "model/CreateParameterGroupRequest.h"
 #include "model/CreateParameterGroupResult.h"
+#include "model/CreateServiceLinkedRoleRequest.h"
+#include "model/CreateServiceLinkedRoleResult.h"
 #include "model/CreateStoragePlanRequest.h"
 #include "model/CreateStoragePlanResult.h"
 #include "model/DeleteAccountRequest.h"
@@ -317,6 +321,9 @@ namespace AlibabaCloud
 			typedef Outcome<Error, Model::CheckKMSAuthorizedResult> CheckKMSAuthorizedOutcome;
 			typedef std::future<CheckKMSAuthorizedOutcome> CheckKMSAuthorizedOutcomeCallable;
 			typedef std::function<void(const PolardbClient*, const Model::CheckKMSAuthorizedRequest&, const CheckKMSAuthorizedOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CheckKMSAuthorizedAsyncHandler;
+			typedef Outcome<Error, Model::CheckServiceLinkedRoleResult> CheckServiceLinkedRoleOutcome;
+			typedef std::future<CheckServiceLinkedRoleOutcome> CheckServiceLinkedRoleOutcomeCallable;
+			typedef std::function<void(const PolardbClient*, const Model::CheckServiceLinkedRoleRequest&, const CheckServiceLinkedRoleOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CheckServiceLinkedRoleAsyncHandler;
 			typedef Outcome<Error, Model::CloseAITaskResult> CloseAITaskOutcome;
 			typedef std::future<CloseAITaskOutcome> CloseAITaskOutcomeCallable;
 			typedef std::function<void(const PolardbClient*, const Model::CloseAITaskRequest&, const CloseAITaskOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CloseAITaskAsyncHandler;
@@ -356,6 +363,9 @@ namespace AlibabaCloud
 			typedef Outcome<Error, Model::CreateParameterGroupResult> CreateParameterGroupOutcome;
 			typedef std::future<CreateParameterGroupOutcome> CreateParameterGroupOutcomeCallable;
 			typedef std::function<void(const PolardbClient*, const Model::CreateParameterGroupRequest&, const CreateParameterGroupOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateParameterGroupAsyncHandler;
+			typedef Outcome<Error, Model::CreateServiceLinkedRoleResult> CreateServiceLinkedRoleOutcome;
+			typedef std::future<CreateServiceLinkedRoleOutcome> CreateServiceLinkedRoleOutcomeCallable;
+			typedef std::function<void(const PolardbClient*, const Model::CreateServiceLinkedRoleRequest&, const CreateServiceLinkedRoleOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateServiceLinkedRoleAsyncHandler;
 			typedef Outcome<Error, Model::CreateStoragePlanResult> CreateStoragePlanOutcome;
 			typedef std::future<CreateStoragePlanOutcome> CreateStoragePlanOutcomeCallable;
 			typedef std::function<void(const PolardbClient*, const Model::CreateStoragePlanRequest&, const CreateStoragePlanOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> CreateStoragePlanAsyncHandler;
@@ -733,6 +743,9 @@ namespace AlibabaCloud
 			CheckKMSAuthorizedOutcome checkKMSAuthorized(const Model::CheckKMSAuthorizedRequest &request)const;
 			void checkKMSAuthorizedAsync(const Model::CheckKMSAuthorizedRequest& request, const CheckKMSAuthorizedAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
 			CheckKMSAuthorizedOutcomeCallable checkKMSAuthorizedCallable(const Model::CheckKMSAuthorizedRequest& request) const;
+			CheckServiceLinkedRoleOutcome checkServiceLinkedRole(const Model::CheckServiceLinkedRoleRequest &request)const;
+			void checkServiceLinkedRoleAsync(const Model::CheckServiceLinkedRoleRequest& request, const CheckServiceLinkedRoleAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
+			CheckServiceLinkedRoleOutcomeCallable checkServiceLinkedRoleCallable(const Model::CheckServiceLinkedRoleRequest& request) const;
 			CloseAITaskOutcome closeAITask(const Model::CloseAITaskRequest &request)const;
 			void closeAITaskAsync(const Model::CloseAITaskRequest& request, const CloseAITaskAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
 			CloseAITaskOutcomeCallable closeAITaskCallable(const Model::CloseAITaskRequest& request) const;
@@ -772,6 +785,9 @@ namespace AlibabaCloud
 			CreateParameterGroupOutcome createParameterGroup(const Model::CreateParameterGroupRequest &request)const;
 			void createParameterGroupAsync(const Model::CreateParameterGroupRequest& request, const CreateParameterGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
 			CreateParameterGroupOutcomeCallable createParameterGroupCallable(const Model::CreateParameterGroupRequest& request) const;
+			CreateServiceLinkedRoleOutcome createServiceLinkedRole(const Model::CreateServiceLinkedRoleRequest &request)const;
+			void createServiceLinkedRoleAsync(const Model::CreateServiceLinkedRoleRequest& request, const CreateServiceLinkedRoleAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
+			CreateServiceLinkedRoleOutcomeCallable createServiceLinkedRoleCallable(const Model::CreateServiceLinkedRoleRequest& request) const;
 			CreateStoragePlanOutcome createStoragePlan(const Model::CreateStoragePlanRequest &request)const;
 			void createStoragePlanAsync(const Model::CreateStoragePlanRequest& request, const CreateStoragePlanAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
 			CreateStoragePlanOutcomeCallable createStoragePlanCallable(const Model::CreateStoragePlanRequest& request) const;

+ 51 - 0
polardb/include/alibabacloud/polardb/model/CheckServiceLinkedRoleRequest.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_POLARDB_MODEL_CHECKSERVICELINKEDROLEREQUEST_H_
+#define ALIBABACLOUD_POLARDB_MODEL_CHECKSERVICELINKEDROLEREQUEST_H_
+
+#include <alibabacloud/polardb/PolardbExport.h>
+#include <alibabacloud/core/RpcServiceRequest.h>
+#include <string>
+#include <vector>
+#include <map>
+
+namespace AlibabaCloud {
+namespace Polardb {
+namespace Model {
+class ALIBABACLOUD_POLARDB_EXPORT CheckServiceLinkedRoleRequest : public RpcServiceRequest {
+public:
+	CheckServiceLinkedRoleRequest();
+	~CheckServiceLinkedRoleRequest();
+	long getResourceOwnerId() const;
+	void setResourceOwnerId(long resourceOwnerId);
+	std::string getResourceOwnerAccount() const;
+	void setResourceOwnerAccount(const std::string &resourceOwnerAccount);
+	std::string getOwnerAccount() const;
+	void setOwnerAccount(const std::string &ownerAccount);
+	long getOwnerId() const;
+	void setOwnerId(long ownerId);
+
+private:
+	long resourceOwnerId_;
+	std::string resourceOwnerAccount_;
+	std::string ownerAccount_;
+	long ownerId_;
+};
+} // namespace Model
+} // namespace Polardb
+} // namespace AlibabaCloud
+#endif // !ALIBABACLOUD_POLARDB_MODEL_CHECKSERVICELINKEDROLEREQUEST_H_

+ 51 - 0
polardb/include/alibabacloud/polardb/model/CheckServiceLinkedRoleResult.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_POLARDB_MODEL_CHECKSERVICELINKEDROLERESULT_H_
+#define ALIBABACLOUD_POLARDB_MODEL_CHECKSERVICELINKEDROLERESULT_H_
+
+#include <string>
+#include <vector>
+#include <utility>
+#include <alibabacloud/core/ServiceResult.h>
+#include <alibabacloud/polardb/PolardbExport.h>
+
+namespace AlibabaCloud
+{
+	namespace Polardb
+	{
+		namespace Model
+		{
+			class ALIBABACLOUD_POLARDB_EXPORT CheckServiceLinkedRoleResult : public ServiceResult
+			{
+			public:
+
+
+				CheckServiceLinkedRoleResult();
+				explicit CheckServiceLinkedRoleResult(const std::string &payload);
+				~CheckServiceLinkedRoleResult();
+				bool getHasServiceLinkedRole()const;
+
+			protected:
+				void parse(const std::string &payload);
+			private:
+				bool hasServiceLinkedRole_;
+
+			};
+		}
+	}
+}
+#endif // !ALIBABACLOUD_POLARDB_MODEL_CHECKSERVICELINKEDROLERESULT_H_

+ 51 - 0
polardb/include/alibabacloud/polardb/model/CreateServiceLinkedRoleRequest.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_POLARDB_MODEL_CREATESERVICELINKEDROLEREQUEST_H_
+#define ALIBABACLOUD_POLARDB_MODEL_CREATESERVICELINKEDROLEREQUEST_H_
+
+#include <alibabacloud/polardb/PolardbExport.h>
+#include <alibabacloud/core/RpcServiceRequest.h>
+#include <string>
+#include <vector>
+#include <map>
+
+namespace AlibabaCloud {
+namespace Polardb {
+namespace Model {
+class ALIBABACLOUD_POLARDB_EXPORT CreateServiceLinkedRoleRequest : public RpcServiceRequest {
+public:
+	CreateServiceLinkedRoleRequest();
+	~CreateServiceLinkedRoleRequest();
+	long getResourceOwnerId() const;
+	void setResourceOwnerId(long resourceOwnerId);
+	std::string getResourceOwnerAccount() const;
+	void setResourceOwnerAccount(const std::string &resourceOwnerAccount);
+	std::string getOwnerAccount() const;
+	void setOwnerAccount(const std::string &ownerAccount);
+	long getOwnerId() const;
+	void setOwnerId(long ownerId);
+
+private:
+	long resourceOwnerId_;
+	std::string resourceOwnerAccount_;
+	std::string ownerAccount_;
+	long ownerId_;
+};
+} // namespace Model
+} // namespace Polardb
+} // namespace AlibabaCloud
+#endif // !ALIBABACLOUD_POLARDB_MODEL_CREATESERVICELINKEDROLEREQUEST_H_

+ 49 - 0
polardb/include/alibabacloud/polardb/model/CreateServiceLinkedRoleResult.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_POLARDB_MODEL_CREATESERVICELINKEDROLERESULT_H_
+#define ALIBABACLOUD_POLARDB_MODEL_CREATESERVICELINKEDROLERESULT_H_
+
+#include <string>
+#include <vector>
+#include <utility>
+#include <alibabacloud/core/ServiceResult.h>
+#include <alibabacloud/polardb/PolardbExport.h>
+
+namespace AlibabaCloud
+{
+	namespace Polardb
+	{
+		namespace Model
+		{
+			class ALIBABACLOUD_POLARDB_EXPORT CreateServiceLinkedRoleResult : public ServiceResult
+			{
+			public:
+
+
+				CreateServiceLinkedRoleResult();
+				explicit CreateServiceLinkedRoleResult(const std::string &payload);
+				~CreateServiceLinkedRoleResult();
+
+			protected:
+				void parse(const std::string &payload);
+			private:
+
+			};
+		}
+	}
+}
+#endif // !ALIBABACLOUD_POLARDB_MODEL_CREATESERVICELINKEDROLERESULT_H_

+ 72 - 0
polardb/src/PolardbClient.cc

@@ -195,6 +195,42 @@ PolardbClient::CheckKMSAuthorizedOutcomeCallable PolardbClient::checkKMSAuthoriz
 	return task->get_future();
 }
 
+PolardbClient::CheckServiceLinkedRoleOutcome PolardbClient::checkServiceLinkedRole(const CheckServiceLinkedRoleRequest &request) const
+{
+	auto endpointOutcome = endpointProvider_->getEndpoint();
+	if (!endpointOutcome.isSuccess())
+		return CheckServiceLinkedRoleOutcome(endpointOutcome.error());
+
+	auto outcome = makeRequest(endpointOutcome.result(), request);
+
+	if (outcome.isSuccess())
+		return CheckServiceLinkedRoleOutcome(CheckServiceLinkedRoleResult(outcome.result()));
+	else
+		return CheckServiceLinkedRoleOutcome(outcome.error());
+}
+
+void PolardbClient::checkServiceLinkedRoleAsync(const CheckServiceLinkedRoleRequest& request, const CheckServiceLinkedRoleAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
+{
+	auto fn = [this, request, handler, context]()
+	{
+		handler(this, request, checkServiceLinkedRole(request), context);
+	};
+
+	asyncExecute(new Runnable(fn));
+}
+
+PolardbClient::CheckServiceLinkedRoleOutcomeCallable PolardbClient::checkServiceLinkedRoleCallable(const CheckServiceLinkedRoleRequest &request) const
+{
+	auto task = std::make_shared<std::packaged_task<CheckServiceLinkedRoleOutcome()>>(
+			[this, request]()
+			{
+			return this->checkServiceLinkedRole(request);
+			});
+
+	asyncExecute(new Runnable([task]() { (*task)(); }));
+	return task->get_future();
+}
+
 PolardbClient::CloseAITaskOutcome PolardbClient::closeAITask(const CloseAITaskRequest &request) const
 {
 	auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -663,6 +699,42 @@ PolardbClient::CreateParameterGroupOutcomeCallable PolardbClient::createParamete
 	return task->get_future();
 }
 
+PolardbClient::CreateServiceLinkedRoleOutcome PolardbClient::createServiceLinkedRole(const CreateServiceLinkedRoleRequest &request) const
+{
+	auto endpointOutcome = endpointProvider_->getEndpoint();
+	if (!endpointOutcome.isSuccess())
+		return CreateServiceLinkedRoleOutcome(endpointOutcome.error());
+
+	auto outcome = makeRequest(endpointOutcome.result(), request);
+
+	if (outcome.isSuccess())
+		return CreateServiceLinkedRoleOutcome(CreateServiceLinkedRoleResult(outcome.result()));
+	else
+		return CreateServiceLinkedRoleOutcome(outcome.error());
+}
+
+void PolardbClient::createServiceLinkedRoleAsync(const CreateServiceLinkedRoleRequest& request, const CreateServiceLinkedRoleAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
+{
+	auto fn = [this, request, handler, context]()
+	{
+		handler(this, request, createServiceLinkedRole(request), context);
+	};
+
+	asyncExecute(new Runnable(fn));
+}
+
+PolardbClient::CreateServiceLinkedRoleOutcomeCallable PolardbClient::createServiceLinkedRoleCallable(const CreateServiceLinkedRoleRequest &request) const
+{
+	auto task = std::make_shared<std::packaged_task<CreateServiceLinkedRoleOutcome()>>(
+			[this, request]()
+			{
+			return this->createServiceLinkedRole(request);
+			});
+
+	asyncExecute(new Runnable([task]() { (*task)(); }));
+	return task->get_future();
+}
+
 PolardbClient::CreateStoragePlanOutcome PolardbClient::createStoragePlan(const CreateStoragePlanRequest &request) const
 {
 	auto endpointOutcome = endpointProvider_->getEndpoint();

+ 63 - 0
polardb/src/model/CheckServiceLinkedRoleRequest.cc

@@ -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.
+ */
+
+#include <alibabacloud/polardb/model/CheckServiceLinkedRoleRequest.h>
+
+using AlibabaCloud::Polardb::Model::CheckServiceLinkedRoleRequest;
+
+CheckServiceLinkedRoleRequest::CheckServiceLinkedRoleRequest()
+    : RpcServiceRequest("polardb", "2017-08-01", "CheckServiceLinkedRole") {
+  setMethod(HttpRequest::Method::Post);
+}
+
+CheckServiceLinkedRoleRequest::~CheckServiceLinkedRoleRequest() {}
+
+long CheckServiceLinkedRoleRequest::getResourceOwnerId() const {
+  return resourceOwnerId_;
+}
+
+void CheckServiceLinkedRoleRequest::setResourceOwnerId(long resourceOwnerId) {
+  resourceOwnerId_ = resourceOwnerId;
+  setParameter(std::string("ResourceOwnerId"), std::to_string(resourceOwnerId));
+}
+
+std::string CheckServiceLinkedRoleRequest::getResourceOwnerAccount() const {
+  return resourceOwnerAccount_;
+}
+
+void CheckServiceLinkedRoleRequest::setResourceOwnerAccount(const std::string &resourceOwnerAccount) {
+  resourceOwnerAccount_ = resourceOwnerAccount;
+  setParameter(std::string("ResourceOwnerAccount"), resourceOwnerAccount);
+}
+
+std::string CheckServiceLinkedRoleRequest::getOwnerAccount() const {
+  return ownerAccount_;
+}
+
+void CheckServiceLinkedRoleRequest::setOwnerAccount(const std::string &ownerAccount) {
+  ownerAccount_ = ownerAccount;
+  setParameter(std::string("OwnerAccount"), ownerAccount);
+}
+
+long CheckServiceLinkedRoleRequest::getOwnerId() const {
+  return ownerId_;
+}
+
+void CheckServiceLinkedRoleRequest::setOwnerId(long ownerId) {
+  ownerId_ = ownerId;
+  setParameter(std::string("OwnerId"), std::to_string(ownerId));
+}
+

+ 51 - 0
polardb/src/model/CheckServiceLinkedRoleResult.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 <alibabacloud/polardb/model/CheckServiceLinkedRoleResult.h>
+#include <json/json.h>
+
+using namespace AlibabaCloud::Polardb;
+using namespace AlibabaCloud::Polardb::Model;
+
+CheckServiceLinkedRoleResult::CheckServiceLinkedRoleResult() :
+	ServiceResult()
+{}
+
+CheckServiceLinkedRoleResult::CheckServiceLinkedRoleResult(const std::string &payload) :
+	ServiceResult()
+{
+	parse(payload);
+}
+
+CheckServiceLinkedRoleResult::~CheckServiceLinkedRoleResult()
+{}
+
+void CheckServiceLinkedRoleResult::parse(const std::string &payload)
+{
+	Json::Reader reader;
+	Json::Value value;
+	reader.parse(payload, value);
+	setRequestId(value["RequestId"].asString());
+	if(!value["HasServiceLinkedRole"].isNull())
+		hasServiceLinkedRole_ = value["HasServiceLinkedRole"].asString() == "true";
+
+}
+
+bool CheckServiceLinkedRoleResult::getHasServiceLinkedRole()const
+{
+	return hasServiceLinkedRole_;
+}
+

+ 63 - 0
polardb/src/model/CreateServiceLinkedRoleRequest.cc

@@ -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.
+ */
+
+#include <alibabacloud/polardb/model/CreateServiceLinkedRoleRequest.h>
+
+using AlibabaCloud::Polardb::Model::CreateServiceLinkedRoleRequest;
+
+CreateServiceLinkedRoleRequest::CreateServiceLinkedRoleRequest()
+    : RpcServiceRequest("polardb", "2017-08-01", "CreateServiceLinkedRole") {
+  setMethod(HttpRequest::Method::Post);
+}
+
+CreateServiceLinkedRoleRequest::~CreateServiceLinkedRoleRequest() {}
+
+long CreateServiceLinkedRoleRequest::getResourceOwnerId() const {
+  return resourceOwnerId_;
+}
+
+void CreateServiceLinkedRoleRequest::setResourceOwnerId(long resourceOwnerId) {
+  resourceOwnerId_ = resourceOwnerId;
+  setParameter(std::string("ResourceOwnerId"), std::to_string(resourceOwnerId));
+}
+
+std::string CreateServiceLinkedRoleRequest::getResourceOwnerAccount() const {
+  return resourceOwnerAccount_;
+}
+
+void CreateServiceLinkedRoleRequest::setResourceOwnerAccount(const std::string &resourceOwnerAccount) {
+  resourceOwnerAccount_ = resourceOwnerAccount;
+  setParameter(std::string("ResourceOwnerAccount"), resourceOwnerAccount);
+}
+
+std::string CreateServiceLinkedRoleRequest::getOwnerAccount() const {
+  return ownerAccount_;
+}
+
+void CreateServiceLinkedRoleRequest::setOwnerAccount(const std::string &ownerAccount) {
+  ownerAccount_ = ownerAccount;
+  setParameter(std::string("OwnerAccount"), ownerAccount);
+}
+
+long CreateServiceLinkedRoleRequest::getOwnerId() const {
+  return ownerId_;
+}
+
+void CreateServiceLinkedRoleRequest::setOwnerId(long ownerId) {
+  ownerId_ = ownerId;
+  setParameter(std::string("OwnerId"), std::to_string(ownerId));
+}
+

+ 44 - 0
polardb/src/model/CreateServiceLinkedRoleResult.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 <alibabacloud/polardb/model/CreateServiceLinkedRoleResult.h>
+#include <json/json.h>
+
+using namespace AlibabaCloud::Polardb;
+using namespace AlibabaCloud::Polardb::Model;
+
+CreateServiceLinkedRoleResult::CreateServiceLinkedRoleResult() :
+	ServiceResult()
+{}
+
+CreateServiceLinkedRoleResult::CreateServiceLinkedRoleResult(const std::string &payload) :
+	ServiceResult()
+{
+	parse(payload);
+}
+
+CreateServiceLinkedRoleResult::~CreateServiceLinkedRoleResult()
+{}
+
+void CreateServiceLinkedRoleResult::parse(const std::string &payload)
+{
+	Json::Reader reader;
+	Json::Value value;
+	reader.parse(payload, value);
+	setRequestId(value["RequestId"].asString());
+
+}
+