Support tag policy.

This commit is contained in:
sdk-team
2023-08-02 07:56:14 +00:00
parent a174c41ddf
commit ebfee1c7e2
3 changed files with 22 additions and 1 deletions

View File

@@ -1 +1 @@
1.36.1709
1.36.1710

View File

@@ -28,6 +28,10 @@ namespace Adb {
namespace Model {
class ALIBABACLOUD_ADB_EXPORT CreateDBClusterRequest : public RpcServiceRequest {
public:
struct Tag {
std::string value;
std::string key;
};
CreateDBClusterRequest();
~CreateDBClusterRequest();
long getResourceOwnerId() const;
@@ -40,6 +44,8 @@ public:
void setMode(const std::string &mode);
std::string getResourceGroupId() const;
void setResourceGroupId(const std::string &resourceGroupId);
std::vector<Tag> getTag() const;
void setTag(const std::vector<Tag> &tag);
std::string getPeriod() const;
void setPeriod(const std::string &period);
std::string getBackupSetID() const;
@@ -99,6 +105,7 @@ private:
std::string storageType_;
std::string mode_;
std::string resourceGroupId_;
std::vector<Tag> tag_;
std::string period_;
std::string backupSetID_;
long ownerId_;

View File

@@ -70,6 +70,20 @@ void CreateDBClusterRequest::setResourceGroupId(const std::string &resourceGroup
setParameter(std::string("ResourceGroupId"), resourceGroupId);
}
std::vector<CreateDBClusterRequest::Tag> CreateDBClusterRequest::getTag() const {
return tag_;
}
void CreateDBClusterRequest::setTag(const std::vector<CreateDBClusterRequest::Tag> &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 + ".Value", tagObj.value);
setParameter(tagObjStr + ".Key", tagObj.key);
}
}
std::string CreateDBClusterRequest::getPeriod() const {
return period_;
}