ModifyBackupPolicy API support parameter BackupPriority.

This commit is contained in:
sdk-team
2023-06-30 02:10:05 +00:00
parent 4fd76a9156
commit 44572042b1
5 changed files with 31 additions and 1 deletions

View File

@@ -64,6 +64,7 @@ namespace AlibabaCloud
std::string getDuplication()const;
std::string getArchiveBackupKeepPolicy()const;
std::string getPreferredBackupTime()const;
int getBackupPriority()const;
int getLocalLogRetentionHours()const;
std::string getHighSpaceUsageProtection()const;
std::string getCompressType()const;
@@ -72,6 +73,7 @@ namespace AlibabaCloud
std::string getEnableBackupLog()const;
std::string getLocalLogRetentionSpace()const;
int getBackupRetentionPeriod()const;
bool getSupportModifyBackupPriority()const;
std::string getBackupInterval()const;
protected:
@@ -94,6 +96,7 @@ namespace AlibabaCloud
std::string duplication_;
std::string archiveBackupKeepPolicy_;
std::string preferredBackupTime_;
int backupPriority_;
int localLogRetentionHours_;
std::string highSpaceUsageProtection_;
std::string compressType_;
@@ -102,6 +105,7 @@ namespace AlibabaCloud
std::string enableBackupLog_;
std::string localLogRetentionSpace_;
int backupRetentionPeriod_;
bool supportModifyBackupPriority_;
std::string backupInterval_;
};

View File

@@ -34,6 +34,8 @@ public:
void setResourceOwnerId(long resourceOwnerId);
std::string getLocalLogRetentionHours() const;
void setLocalLogRetentionHours(const std::string &localLogRetentionHours);
int getBackupPriority() const;
void setBackupPriority(int backupPriority);
std::string getLogBackupFrequency() const;
void setLogBackupFrequency(const std::string &logBackupFrequency);
int getArchiveBackupKeepCount() const;
@@ -94,6 +96,7 @@ public:
private:
long resourceOwnerId_;
std::string localLogRetentionHours_;
int backupPriority_;
std::string logBackupFrequency_;
int archiveBackupKeepCount_;
std::string backupLog_;

View File

@@ -97,6 +97,10 @@ void DescribeBackupPolicyResult::parse(const std::string &payload)
backupLog_ = value["BackupLog"].asString();
if(!value["EnableIncrementDataBackup"].isNull())
enableIncrementDataBackup_ = value["EnableIncrementDataBackup"].asString() == "true";
if(!value["SupportModifyBackupPriority"].isNull())
supportModifyBackupPriority_ = value["SupportModifyBackupPriority"].asString() == "true";
if(!value["BackupPriority"].isNull())
backupPriority_ = std::stoi(value["BackupPriority"].asString());
}
@@ -185,6 +189,11 @@ std::string DescribeBackupPolicyResult::getPreferredBackupTime()const
return preferredBackupTime_;
}
int DescribeBackupPolicyResult::getBackupPriority()const
{
return backupPriority_;
}
int DescribeBackupPolicyResult::getLocalLogRetentionHours()const
{
return localLogRetentionHours_;
@@ -225,6 +234,11 @@ int DescribeBackupPolicyResult::getBackupRetentionPeriod()const
return backupRetentionPeriod_;
}
bool DescribeBackupPolicyResult::getSupportModifyBackupPriority()const
{
return supportModifyBackupPriority_;
}
std::string DescribeBackupPolicyResult::getBackupInterval()const
{
return backupInterval_;

View File

@@ -43,6 +43,15 @@ void ModifyBackupPolicyRequest::setLocalLogRetentionHours(const std::string &loc
setParameter(std::string("LocalLogRetentionHours"), localLogRetentionHours);
}
int ModifyBackupPolicyRequest::getBackupPriority() const {
return backupPriority_;
}
void ModifyBackupPolicyRequest::setBackupPriority(int backupPriority) {
backupPriority_ = backupPriority;
setParameter(std::string("BackupPriority"), std::to_string(backupPriority));
}
std::string ModifyBackupPolicyRequest::getLogBackupFrequency() const {
return logBackupFrequency_;
}