Support Mysql Parameter Group API.

This commit is contained in:
sdk-team
2021-03-08 12:06:57 +00:00
parent 3293c5bfce
commit 0b756cf361
237 changed files with 2944 additions and 509 deletions

View File

@@ -483,6 +483,42 @@ PolardbClient::CreateDatabaseOutcomeCallable PolardbClient::createDatabaseCallab
return task->get_future();
}
PolardbClient::CreateParameterGroupOutcome PolardbClient::createParameterGroup(const CreateParameterGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return CreateParameterGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return CreateParameterGroupOutcome(CreateParameterGroupResult(outcome.result()));
else
return CreateParameterGroupOutcome(outcome.error());
}
void PolardbClient::createParameterGroupAsync(const CreateParameterGroupRequest& request, const CreateParameterGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, createParameterGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
PolardbClient::CreateParameterGroupOutcomeCallable PolardbClient::createParameterGroupCallable(const CreateParameterGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<CreateParameterGroupOutcome()>>(
[this, request]()
{
return this->createParameterGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
PolardbClient::DeleteAccountOutcome PolardbClient::deleteAccount(const DeleteAccountRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -771,6 +807,42 @@ PolardbClient::DeleteDatabaseOutcomeCallable PolardbClient::deleteDatabaseCallab
return task->get_future();
}
PolardbClient::DeleteParameterGroupOutcome PolardbClient::deleteParameterGroup(const DeleteParameterGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DeleteParameterGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DeleteParameterGroupOutcome(DeleteParameterGroupResult(outcome.result()));
else
return DeleteParameterGroupOutcome(outcome.error());
}
void PolardbClient::deleteParameterGroupAsync(const DeleteParameterGroupRequest& request, const DeleteParameterGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, deleteParameterGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
PolardbClient::DeleteParameterGroupOutcomeCallable PolardbClient::deleteParameterGroupCallable(const DeleteParameterGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DeleteParameterGroupOutcome()>>(
[this, request]()
{
return this->deleteParameterGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
PolardbClient::DescribeAccountsOutcome PolardbClient::describeAccounts(const DescribeAccountsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -1815,6 +1887,78 @@ PolardbClient::DescribeMetaListOutcomeCallable PolardbClient::describeMetaListCa
return task->get_future();
}
PolardbClient::DescribeParameterGroupOutcome PolardbClient::describeParameterGroup(const DescribeParameterGroupRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeParameterGroupOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeParameterGroupOutcome(DescribeParameterGroupResult(outcome.result()));
else
return DescribeParameterGroupOutcome(outcome.error());
}
void PolardbClient::describeParameterGroupAsync(const DescribeParameterGroupRequest& request, const DescribeParameterGroupAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeParameterGroup(request), context);
};
asyncExecute(new Runnable(fn));
}
PolardbClient::DescribeParameterGroupOutcomeCallable PolardbClient::describeParameterGroupCallable(const DescribeParameterGroupRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeParameterGroupOutcome()>>(
[this, request]()
{
return this->describeParameterGroup(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
PolardbClient::DescribeParameterGroupsOutcome PolardbClient::describeParameterGroups(const DescribeParameterGroupsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeParameterGroupsOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeParameterGroupsOutcome(DescribeParameterGroupsResult(outcome.result()));
else
return DescribeParameterGroupsOutcome(outcome.error());
}
void PolardbClient::describeParameterGroupsAsync(const DescribeParameterGroupsRequest& request, const DescribeParameterGroupsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeParameterGroups(request), context);
};
asyncExecute(new Runnable(fn));
}
PolardbClient::DescribeParameterGroupsOutcomeCallable PolardbClient::describeParameterGroupsCallable(const DescribeParameterGroupsRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeParameterGroupsOutcome()>>(
[this, request]()
{
return this->describeParameterGroups(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
PolardbClient::DescribePendingMaintenanceActionOutcome PolardbClient::describePendingMaintenanceAction(const DescribePendingMaintenanceActionRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
@@ -1995,36 +2139,72 @@ PolardbClient::DescribeSQLExplorerRetentionOutcomeCallable PolardbClient::descri
return task->get_future();
}
PolardbClient::DescribeSQLExplorerVersionOutcome PolardbClient::describeSQLExplorerVersion(const DescribeSQLExplorerVersionRequest &request) const
PolardbClient::DescribeSQLLogRecordsOutcome PolardbClient::describeSQLLogRecords(const DescribeSQLLogRecordsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeSQLExplorerVersionOutcome(endpointOutcome.error());
return DescribeSQLLogRecordsOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeSQLExplorerVersionOutcome(DescribeSQLExplorerVersionResult(outcome.result()));
return DescribeSQLLogRecordsOutcome(DescribeSQLLogRecordsResult(outcome.result()));
else
return DescribeSQLExplorerVersionOutcome(outcome.error());
return DescribeSQLLogRecordsOutcome(outcome.error());
}
void PolardbClient::describeSQLExplorerVersionAsync(const DescribeSQLExplorerVersionRequest& request, const DescribeSQLExplorerVersionAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
void PolardbClient::describeSQLLogRecordsAsync(const DescribeSQLLogRecordsRequest& request, const DescribeSQLLogRecordsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeSQLExplorerVersion(request), context);
handler(this, request, describeSQLLogRecords(request), context);
};
asyncExecute(new Runnable(fn));
}
PolardbClient::DescribeSQLExplorerVersionOutcomeCallable PolardbClient::describeSQLExplorerVersionCallable(const DescribeSQLExplorerVersionRequest &request) const
PolardbClient::DescribeSQLLogRecordsOutcomeCallable PolardbClient::describeSQLLogRecordsCallable(const DescribeSQLLogRecordsRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeSQLExplorerVersionOutcome()>>(
auto task = std::make_shared<std::packaged_task<DescribeSQLLogRecordsOutcome()>>(
[this, request]()
{
return this->describeSQLExplorerVersion(request);
return this->describeSQLLogRecords(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
PolardbClient::DescribeSQLLogTemplatesOutcome PolardbClient::describeSQLLogTemplates(const DescribeSQLLogTemplatesRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeSQLLogTemplatesOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeSQLLogTemplatesOutcome(DescribeSQLLogTemplatesResult(outcome.result()));
else
return DescribeSQLLogTemplatesOutcome(outcome.error());
}
void PolardbClient::describeSQLLogTemplatesAsync(const DescribeSQLLogTemplatesRequest& request, const DescribeSQLLogTemplatesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeSQLLogTemplates(request), context);
};
asyncExecute(new Runnable(fn));
}
PolardbClient::DescribeSQLLogTemplatesOutcomeCallable PolardbClient::describeSQLLogTemplatesCallable(const DescribeSQLLogTemplatesRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeSQLLogTemplatesOutcome()>>(
[this, request]()
{
return this->describeSQLLogTemplates(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
@@ -2103,42 +2283,6 @@ PolardbClient::DescribeSlowLogRecordsOutcomeCallable PolardbClient::describeSlow
return task->get_future();
}
PolardbClient::DescribeSqlLogTrialStatusOutcome PolardbClient::describeSqlLogTrialStatus(const DescribeSqlLogTrialStatusRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeSqlLogTrialStatusOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeSqlLogTrialStatusOutcome(DescribeSqlLogTrialStatusResult(outcome.result()));
else
return DescribeSqlLogTrialStatusOutcome(outcome.error());
}
void PolardbClient::describeSqlLogTrialStatusAsync(const DescribeSqlLogTrialStatusRequest& request, const DescribeSqlLogTrialStatusAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeSqlLogTrialStatus(request), context);
};
asyncExecute(new Runnable(fn));
}
PolardbClient::DescribeSqlLogTrialStatusOutcomeCallable PolardbClient::describeSqlLogTrialStatusCallable(const DescribeSqlLogTrialStatusRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeSqlLogTrialStatusOutcome()>>(
[this, request]()
{
return this->describeSqlLogTrialStatus(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
PolardbClient::DescribeTasksOutcome PolardbClient::describeTasks(const DescribeTasksRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();

View File

@@ -258,6 +258,28 @@ void CreateDBClusterRequest::setClusterNetworkType(const std::string& clusterNet
setParameter("ClusterNetworkType", clusterNetworkType);
}
std::string CreateDBClusterRequest::getParameterGroupId()const
{
return parameterGroupId_;
}
void CreateDBClusterRequest::setParameterGroupId(const std::string& parameterGroupId)
{
parameterGroupId_ = parameterGroupId;
setParameter("ParameterGroupId", parameterGroupId);
}
std::string CreateDBClusterRequest::getRegionId()const
{
return regionId_;
}
void CreateDBClusterRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setParameter("RegionId", regionId);
}
std::string CreateDBClusterRequest::getEngine()const
{
return engine_;

View File

@@ -39,12 +39,12 @@ void CreateDBClusterResult::parse(const std::string &payload)
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["ResourceGroupId"].isNull())
resourceGroupId_ = value["ResourceGroupId"].asString();
if(!value["DBClusterId"].isNull())
dBClusterId_ = value["DBClusterId"].asString();
if(!value["OrderId"].isNull())
orderId_ = value["OrderId"].asString();
if(!value["ResourceGroupId"].isNull())
resourceGroupId_ = value["ResourceGroupId"].asString();
}

View File

@@ -0,0 +1,150 @@
/*
* 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/CreateParameterGroupRequest.h>
using AlibabaCloud::Polardb::Model::CreateParameterGroupRequest;
CreateParameterGroupRequest::CreateParameterGroupRequest() :
RpcServiceRequest("polardb", "2017-08-01", "CreateParameterGroup")
{
setMethod(HttpRequest::Method::Post);
}
CreateParameterGroupRequest::~CreateParameterGroupRequest()
{}
long CreateParameterGroupRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void CreateParameterGroupRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string CreateParameterGroupRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void CreateParameterGroupRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string CreateParameterGroupRequest::getRegionId()const
{
return regionId_;
}
void CreateParameterGroupRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setParameter("RegionId", regionId);
}
std::string CreateParameterGroupRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void CreateParameterGroupRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string CreateParameterGroupRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void CreateParameterGroupRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
long CreateParameterGroupRequest::getOwnerId()const
{
return ownerId_;
}
void CreateParameterGroupRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}
std::string CreateParameterGroupRequest::getDBType()const
{
return dBType_;
}
void CreateParameterGroupRequest::setDBType(const std::string& dBType)
{
dBType_ = dBType;
setParameter("DBType", dBType);
}
std::string CreateParameterGroupRequest::getDBVersion()const
{
return dBVersion_;
}
void CreateParameterGroupRequest::setDBVersion(const std::string& dBVersion)
{
dBVersion_ = dBVersion;
setParameter("DBVersion", dBVersion);
}
std::string CreateParameterGroupRequest::getParameterGroupName()const
{
return parameterGroupName_;
}
void CreateParameterGroupRequest::setParameterGroupName(const std::string& parameterGroupName)
{
parameterGroupName_ = parameterGroupName;
setParameter("ParameterGroupName", parameterGroupName);
}
std::string CreateParameterGroupRequest::getParameters()const
{
return parameters_;
}
void CreateParameterGroupRequest::setParameters(const std::string& parameters)
{
parameters_ = parameters;
setParameter("Parameters", parameters);
}
std::string CreateParameterGroupRequest::getParameterGroupDesc()const
{
return parameterGroupDesc_;
}
void CreateParameterGroupRequest::setParameterGroupDesc(const std::string& parameterGroupDesc)
{
parameterGroupDesc_ = parameterGroupDesc;
setParameter("ParameterGroupDesc", parameterGroupDesc);
}

View File

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

View File

@@ -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 <alibabacloud/polardb/model/DeleteParameterGroupRequest.h>
using AlibabaCloud::Polardb::Model::DeleteParameterGroupRequest;
DeleteParameterGroupRequest::DeleteParameterGroupRequest() :
RpcServiceRequest("polardb", "2017-08-01", "DeleteParameterGroup")
{
setMethod(HttpRequest::Method::Post);
}
DeleteParameterGroupRequest::~DeleteParameterGroupRequest()
{}
long DeleteParameterGroupRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DeleteParameterGroupRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DeleteParameterGroupRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DeleteParameterGroupRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DeleteParameterGroupRequest::getParameterGroupId()const
{
return parameterGroupId_;
}
void DeleteParameterGroupRequest::setParameterGroupId(const std::string& parameterGroupId)
{
parameterGroupId_ = parameterGroupId;
setParameter("ParameterGroupId", parameterGroupId);
}
std::string DeleteParameterGroupRequest::getRegionId()const
{
return regionId_;
}
void DeleteParameterGroupRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setParameter("RegionId", regionId);
}
std::string DeleteParameterGroupRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DeleteParameterGroupRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DeleteParameterGroupRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DeleteParameterGroupRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
long DeleteParameterGroupRequest::getOwnerId()const
{
return ownerId_;
}
void DeleteParameterGroupRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}

View File

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

View File

@@ -39,20 +39,22 @@ void DescribeBackupPolicyResult::parse(const std::string &payload)
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["BackupRetentionPeriod"].isNull())
backupRetentionPeriod_ = std::stoi(value["BackupRetentionPeriod"].asString());
if(!value["PreferredNextBackupTime"].isNull())
preferredNextBackupTime_ = value["PreferredNextBackupTime"].asString();
if(!value["PreferredBackupTime"].isNull())
preferredBackupTime_ = value["PreferredBackupTime"].asString();
if(!value["PreferredBackupPeriod"].isNull())
preferredBackupPeriod_ = value["PreferredBackupPeriod"].asString();
if(!value["DataLevel1BackupRetentionPeriod"].isNull())
dataLevel1BackupRetentionPeriod_ = value["DataLevel1BackupRetentionPeriod"].asString();
if(!value["DataLevel2BackupRetentionPeriod"].isNull())
dataLevel2BackupRetentionPeriod_ = value["DataLevel2BackupRetentionPeriod"].asString();
if(!value["BackupRetentionPolicyOnClusterDeletion"].isNull())
backupRetentionPolicyOnClusterDeletion_ = value["BackupRetentionPolicyOnClusterDeletion"].asString();
if(!value["PreferredBackupTime"].isNull())
preferredBackupTime_ = value["PreferredBackupTime"].asString();
if(!value["BackupFrequency"].isNull())
backupFrequency_ = value["BackupFrequency"].asString();
if(!value["PreferredNextBackupTime"].isNull())
preferredNextBackupTime_ = value["PreferredNextBackupTime"].asString();
if(!value["BackupRetentionPeriod"].isNull())
backupRetentionPeriod_ = std::stoi(value["BackupRetentionPeriod"].asString());
if(!value["DataLevel2BackupRetentionPeriod"].isNull())
dataLevel2BackupRetentionPeriod_ = value["DataLevel2BackupRetentionPeriod"].asString();
}
@@ -66,19 +68,19 @@ std::string DescribeBackupPolicyResult::getDataLevel1BackupRetentionPeriod()cons
return dataLevel1BackupRetentionPeriod_;
}
std::string DescribeBackupPolicyResult::getPreferredBackupTime()const
{
return preferredBackupTime_;
}
std::string DescribeBackupPolicyResult::getBackupRetentionPolicyOnClusterDeletion()const
{
return backupRetentionPolicyOnClusterDeletion_;
}
int DescribeBackupPolicyResult::getBackupRetentionPeriod()const
std::string DescribeBackupPolicyResult::getPreferredBackupTime()const
{
return backupRetentionPeriod_;
return preferredBackupTime_;
}
std::string DescribeBackupPolicyResult::getBackupFrequency()const
{
return backupFrequency_;
}
std::string DescribeBackupPolicyResult::getPreferredNextBackupTime()const
@@ -86,6 +88,11 @@ std::string DescribeBackupPolicyResult::getPreferredNextBackupTime()const
return preferredNextBackupTime_;
}
int DescribeBackupPolicyResult::getBackupRetentionPeriod()const
{
return backupRetentionPeriod_;
}
std::string DescribeBackupPolicyResult::getDataLevel2BackupRetentionPeriod()const
{
return dataLevel2BackupRetentionPeriod_;

View File

@@ -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 <alibabacloud/polardb/model/DescribeParameterGroupRequest.h>
using AlibabaCloud::Polardb::Model::DescribeParameterGroupRequest;
DescribeParameterGroupRequest::DescribeParameterGroupRequest() :
RpcServiceRequest("polardb", "2017-08-01", "DescribeParameterGroup")
{
setMethod(HttpRequest::Method::Post);
}
DescribeParameterGroupRequest::~DescribeParameterGroupRequest()
{}
long DescribeParameterGroupRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeParameterGroupRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeParameterGroupRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeParameterGroupRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeParameterGroupRequest::getParameterGroupId()const
{
return parameterGroupId_;
}
void DescribeParameterGroupRequest::setParameterGroupId(const std::string& parameterGroupId)
{
parameterGroupId_ = parameterGroupId;
setParameter("ParameterGroupId", parameterGroupId);
}
std::string DescribeParameterGroupRequest::getRegionId()const
{
return regionId_;
}
void DescribeParameterGroupRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setParameter("RegionId", regionId);
}
std::string DescribeParameterGroupRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeParameterGroupRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DescribeParameterGroupRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeParameterGroupRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
long DescribeParameterGroupRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeParameterGroupRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}

View File

@@ -0,0 +1,83 @@
/*
* 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/DescribeParameterGroupResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Polardb;
using namespace AlibabaCloud::Polardb::Model;
DescribeParameterGroupResult::DescribeParameterGroupResult() :
ServiceResult()
{}
DescribeParameterGroupResult::DescribeParameterGroupResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeParameterGroupResult::~DescribeParameterGroupResult()
{}
void DescribeParameterGroupResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allParameterGroupNode = value["ParameterGroup"]["ParameterGroupItem"];
for (auto valueParameterGroupParameterGroupItem : allParameterGroupNode)
{
ParameterGroupItem parameterGroupObject;
if(!valueParameterGroupParameterGroupItem["DBVersion"].isNull())
parameterGroupObject.dBVersion = valueParameterGroupParameterGroupItem["DBVersion"].asString();
if(!valueParameterGroupParameterGroupItem["ParameterGroupId"].isNull())
parameterGroupObject.parameterGroupId = valueParameterGroupParameterGroupItem["ParameterGroupId"].asString();
if(!valueParameterGroupParameterGroupItem["ForceRestart"].isNull())
parameterGroupObject.forceRestart = valueParameterGroupParameterGroupItem["ForceRestart"].asString();
if(!valueParameterGroupParameterGroupItem["ParameterGroupName"].isNull())
parameterGroupObject.parameterGroupName = valueParameterGroupParameterGroupItem["ParameterGroupName"].asString();
if(!valueParameterGroupParameterGroupItem["CreateTime"].isNull())
parameterGroupObject.createTime = valueParameterGroupParameterGroupItem["CreateTime"].asString();
if(!valueParameterGroupParameterGroupItem["ParameterGroupDesc"].isNull())
parameterGroupObject.parameterGroupDesc = valueParameterGroupParameterGroupItem["ParameterGroupDesc"].asString();
if(!valueParameterGroupParameterGroupItem["ParameterGroupType"].isNull())
parameterGroupObject.parameterGroupType = valueParameterGroupParameterGroupItem["ParameterGroupType"].asString();
if(!valueParameterGroupParameterGroupItem["ParameterCounts"].isNull())
parameterGroupObject.parameterCounts = std::stoi(valueParameterGroupParameterGroupItem["ParameterCounts"].asString());
if(!valueParameterGroupParameterGroupItem["DBType"].isNull())
parameterGroupObject.dBType = valueParameterGroupParameterGroupItem["DBType"].asString();
auto allParameterDetailNode = valueParameterGroupParameterGroupItem["ParameterDetail"]["ParameterDetailItem"];
for (auto valueParameterGroupParameterGroupItemParameterDetailParameterDetailItem : allParameterDetailNode)
{
ParameterGroupItem::ParameterDetailItem parameterDetailObject;
if(!valueParameterGroupParameterGroupItemParameterDetailParameterDetailItem["ParamValue"].isNull())
parameterDetailObject.paramValue = valueParameterGroupParameterGroupItemParameterDetailParameterDetailItem["ParamValue"].asString();
if(!valueParameterGroupParameterGroupItemParameterDetailParameterDetailItem["ParamName"].isNull())
parameterDetailObject.paramName = valueParameterGroupParameterGroupItemParameterDetailParameterDetailItem["ParamName"].asString();
parameterGroupObject.parameterDetail.push_back(parameterDetailObject);
}
parameterGroup_.push_back(parameterGroupObject);
}
}
std::vector<DescribeParameterGroupResult::ParameterGroupItem> DescribeParameterGroupResult::getParameterGroup()const
{
return parameterGroup_;
}

View File

@@ -0,0 +1,117 @@
/*
* 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/DescribeParameterGroupsRequest.h>
using AlibabaCloud::Polardb::Model::DescribeParameterGroupsRequest;
DescribeParameterGroupsRequest::DescribeParameterGroupsRequest() :
RpcServiceRequest("polardb", "2017-08-01", "DescribeParameterGroups")
{
setMethod(HttpRequest::Method::Post);
}
DescribeParameterGroupsRequest::~DescribeParameterGroupsRequest()
{}
long DescribeParameterGroupsRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeParameterGroupsRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeParameterGroupsRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeParameterGroupsRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeParameterGroupsRequest::getRegionId()const
{
return regionId_;
}
void DescribeParameterGroupsRequest::setRegionId(const std::string& regionId)
{
regionId_ = regionId;
setParameter("RegionId", regionId);
}
std::string DescribeParameterGroupsRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeParameterGroupsRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DescribeParameterGroupsRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeParameterGroupsRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
long DescribeParameterGroupsRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeParameterGroupsRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeParameterGroupsRequest::getDBType()const
{
return dBType_;
}
void DescribeParameterGroupsRequest::setDBType(const std::string& dBType)
{
dBType_ = dBType;
setParameter("DBType", dBType);
}
std::string DescribeParameterGroupsRequest::getDBVersion()const
{
return dBVersion_;
}
void DescribeParameterGroupsRequest::setDBVersion(const std::string& dBVersion)
{
dBVersion_ = dBVersion;
setParameter("DBVersion", dBVersion);
}

View File

@@ -0,0 +1,75 @@
/*
* 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/DescribeParameterGroupsResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Polardb;
using namespace AlibabaCloud::Polardb::Model;
DescribeParameterGroupsResult::DescribeParameterGroupsResult() :
ServiceResult()
{}
DescribeParameterGroupsResult::DescribeParameterGroupsResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeParameterGroupsResult::~DescribeParameterGroupsResult()
{}
void DescribeParameterGroupsResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allParameterGroupsNode = value["ParameterGroups"]["ParameterGroupsItem"];
for (auto valueParameterGroupsParameterGroupsItem : allParameterGroupsNode)
{
ParameterGroupsItem parameterGroupsObject;
if(!valueParameterGroupsParameterGroupsItem["DBVersion"].isNull())
parameterGroupsObject.dBVersion = valueParameterGroupsParameterGroupsItem["DBVersion"].asString();
if(!valueParameterGroupsParameterGroupsItem["ParameterGroupId"].isNull())
parameterGroupsObject.parameterGroupId = valueParameterGroupsParameterGroupsItem["ParameterGroupId"].asString();
if(!valueParameterGroupsParameterGroupsItem["DigitalId"].isNull())
parameterGroupsObject.digitalId = valueParameterGroupsParameterGroupsItem["DigitalId"].asString();
if(!valueParameterGroupsParameterGroupsItem["ForceRestart"].isNull())
parameterGroupsObject.forceRestart = valueParameterGroupsParameterGroupsItem["ForceRestart"].asString();
if(!valueParameterGroupsParameterGroupsItem["ParameterGroupName"].isNull())
parameterGroupsObject.parameterGroupName = valueParameterGroupsParameterGroupsItem["ParameterGroupName"].asString();
if(!valueParameterGroupsParameterGroupsItem["CreateTime"].isNull())
parameterGroupsObject.createTime = valueParameterGroupsParameterGroupsItem["CreateTime"].asString();
if(!valueParameterGroupsParameterGroupsItem["ParameterGroupDesc"].isNull())
parameterGroupsObject.parameterGroupDesc = valueParameterGroupsParameterGroupsItem["ParameterGroupDesc"].asString();
if(!valueParameterGroupsParameterGroupsItem["ParameterGroupType"].isNull())
parameterGroupsObject.parameterGroupType = valueParameterGroupsParameterGroupsItem["ParameterGroupType"].asString();
if(!valueParameterGroupsParameterGroupsItem["ParameterCounts"].isNull())
parameterGroupsObject.parameterCounts = std::stol(valueParameterGroupsParameterGroupsItem["ParameterCounts"].asString());
if(!valueParameterGroupsParameterGroupsItem["DBType"].isNull())
parameterGroupsObject.dBType = valueParameterGroupsParameterGroupsItem["DBType"].asString();
parameterGroups_.push_back(parameterGroupsObject);
}
}
std::vector<DescribeParameterGroupsResult::ParameterGroupsItem> DescribeParameterGroupsResult::getParameterGroups()const
{
return parameterGroups_;
}

View File

@@ -1,106 +0,0 @@
/*
* 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/DescribeSQLExplorerVersionRequest.h>
using AlibabaCloud::Polardb::Model::DescribeSQLExplorerVersionRequest;
DescribeSQLExplorerVersionRequest::DescribeSQLExplorerVersionRequest() :
RpcServiceRequest("polardb", "2017-08-01", "DescribeSQLExplorerVersion")
{
setMethod(HttpRequest::Method::Post);
}
DescribeSQLExplorerVersionRequest::~DescribeSQLExplorerVersionRequest()
{}
long DescribeSQLExplorerVersionRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeSQLExplorerVersionRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeSQLExplorerVersionRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeSQLExplorerVersionRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeSQLExplorerVersionRequest::getSecurityToken()const
{
return securityToken_;
}
void DescribeSQLExplorerVersionRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setParameter("SecurityToken", securityToken);
}
std::string DescribeSQLExplorerVersionRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void DescribeSQLExplorerVersionRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setParameter("DBInstanceId", dBInstanceId);
}
std::string DescribeSQLExplorerVersionRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeSQLExplorerVersionRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DescribeSQLExplorerVersionRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeSQLExplorerVersionRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
long DescribeSQLExplorerVersionRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeSQLExplorerVersionRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}

View File

@@ -1,65 +0,0 @@
/*
* 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/DescribeSQLExplorerVersionResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Polardb;
using namespace AlibabaCloud::Polardb::Model;
DescribeSQLExplorerVersionResult::DescribeSQLExplorerVersionResult() :
ServiceResult()
{}
DescribeSQLExplorerVersionResult::DescribeSQLExplorerVersionResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeSQLExplorerVersionResult::~DescribeSQLExplorerVersionResult()
{}
void DescribeSQLExplorerVersionResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["ConfigValue"].isNull())
configValue_ = value["ConfigValue"].asString();
if(!value["DBInstanceID"].isNull())
dBInstanceID_ = std::stoi(value["DBInstanceID"].asString());
if(!value["DBInstanceName"].isNull())
dBInstanceName_ = value["DBInstanceName"].asString();
}
std::string DescribeSQLExplorerVersionResult::getConfigValue()const
{
return configValue_;
}
int DescribeSQLExplorerVersionResult::getDBInstanceID()const
{
return dBInstanceID_;
}
std::string DescribeSQLExplorerVersionResult::getDBInstanceName()const
{
return dBInstanceName_;
}

View File

@@ -0,0 +1,348 @@
/*
* 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/DescribeSQLLogRecordsRequest.h>
using AlibabaCloud::Polardb::Model::DescribeSQLLogRecordsRequest;
DescribeSQLLogRecordsRequest::DescribeSQLLogRecordsRequest() :
RpcServiceRequest("polardb", "2017-08-01", "DescribeSQLLogRecords")
{
setMethod(HttpRequest::Method::Post);
}
DescribeSQLLogRecordsRequest::~DescribeSQLLogRecordsRequest()
{}
long DescribeSQLLogRecordsRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeSQLLogRecordsRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeSQLLogRecordsRequest::getStartTime()const
{
return startTime_;
}
void DescribeSQLLogRecordsRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeSQLLogRecordsRequest::getJobId()const
{
return jobId_;
}
void DescribeSQLLogRecordsRequest::setJobId(const std::string& jobId)
{
jobId_ = jobId;
setParameter("JobId", jobId);
}
std::string DescribeSQLLogRecordsRequest::getAccountName()const
{
return accountName_;
}
void DescribeSQLLogRecordsRequest::setAccountName(const std::string& accountName)
{
accountName_ = accountName;
setParameter("AccountName", accountName);
}
std::string DescribeSQLLogRecordsRequest::getSecurityToken()const
{
return securityToken_;
}
void DescribeSQLLogRecordsRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setParameter("SecurityToken", securityToken);
}
std::string DescribeSQLLogRecordsRequest::getState()const
{
return state_;
}
void DescribeSQLLogRecordsRequest::setState(const std::string& state)
{
state_ = state;
setParameter("State", state);
}
long DescribeSQLLogRecordsRequest::getMinConsume()const
{
return minConsume_;
}
void DescribeSQLLogRecordsRequest::setMinConsume(long minConsume)
{
minConsume_ = minConsume;
setParameter("MinConsume", std::to_string(minConsume));
}
long DescribeSQLLogRecordsRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeSQLLogRecordsRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}
std::string DescribeSQLLogRecordsRequest::getLogicalOperator()const
{
return logicalOperator_;
}
void DescribeSQLLogRecordsRequest::setLogicalOperator(const std::string& logicalOperator)
{
logicalOperator_ = logicalOperator;
setParameter("LogicalOperator", logicalOperator);
}
std::string DescribeSQLLogRecordsRequest::getDBName()const
{
return dBName_;
}
void DescribeSQLLogRecordsRequest::setDBName(const std::string& dBName)
{
dBName_ = dBName;
setParameter("DBName", dBName);
}
long DescribeSQLLogRecordsRequest::getMinScanRows()const
{
return minScanRows_;
}
void DescribeSQLLogRecordsRequest::setMinScanRows(long minScanRows)
{
minScanRows_ = minScanRows;
setParameter("MinScanRows", std::to_string(minScanRows));
}
std::string DescribeSQLLogRecordsRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeSQLLogRecordsRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeSQLLogRecordsRequest::getHostAddress()const
{
return hostAddress_;
}
void DescribeSQLLogRecordsRequest::setHostAddress(const std::string& hostAddress)
{
hostAddress_ = hostAddress;
setParameter("HostAddress", hostAddress);
}
std::string DescribeSQLLogRecordsRequest::getSortKey()const
{
return sortKey_;
}
void DescribeSQLLogRecordsRequest::setSortKey(const std::string& sortKey)
{
sortKey_ = sortKey;
setParameter("SortKey", sortKey);
}
int DescribeSQLLogRecordsRequest::getPageNumbers()const
{
return pageNumbers_;
}
void DescribeSQLLogRecordsRequest::setPageNumbers(int pageNumbers)
{
pageNumbers_ = pageNumbers;
setParameter("PageNumbers", std::to_string(pageNumbers));
}
std::string DescribeSQLLogRecordsRequest::getPagingID()const
{
return pagingID_;
}
void DescribeSQLLogRecordsRequest::setPagingID(const std::string& pagingID)
{
pagingID_ = pagingID;
setParameter("PagingID", pagingID);
}
std::string DescribeSQLLogRecordsRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void DescribeSQLLogRecordsRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setParameter("DBInstanceId", dBInstanceId);
}
std::string DescribeSQLLogRecordsRequest::getTableName()const
{
return tableName_;
}
void DescribeSQLLogRecordsRequest::setTableName(const std::string& tableName)
{
tableName_ = tableName;
setParameter("TableName", tableName);
}
std::string DescribeSQLLogRecordsRequest::getSqlType()const
{
return sqlType_;
}
void DescribeSQLLogRecordsRequest::setSqlType(const std::string& sqlType)
{
sqlType_ = sqlType;
setParameter("SqlType", sqlType);
}
std::string DescribeSQLLogRecordsRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeSQLLogRecordsRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DescribeSQLLogRecordsRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeSQLLogRecordsRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
int DescribeSQLLogRecordsRequest::getMaxRecordsPerPage()const
{
return maxRecordsPerPage_;
}
void DescribeSQLLogRecordsRequest::setMaxRecordsPerPage(int maxRecordsPerPage)
{
maxRecordsPerPage_ = maxRecordsPerPage;
setParameter("MaxRecordsPerPage", std::to_string(maxRecordsPerPage));
}
std::string DescribeSQLLogRecordsRequest::getQueryKeyword()const
{
return queryKeyword_;
}
void DescribeSQLLogRecordsRequest::setQueryKeyword(const std::string& queryKeyword)
{
queryKeyword_ = queryKeyword;
setParameter("QueryKeyword", queryKeyword);
}
std::string DescribeSQLLogRecordsRequest::getEndTime()const
{
return endTime_;
}
void DescribeSQLLogRecordsRequest::setEndTime(const std::string& endTime)
{
endTime_ = endTime;
setParameter("EndTime", endTime);
}
long DescribeSQLLogRecordsRequest::getMaxConsume()const
{
return maxConsume_;
}
void DescribeSQLLogRecordsRequest::setMaxConsume(long maxConsume)
{
maxConsume_ = maxConsume;
setParameter("MaxConsume", std::to_string(maxConsume));
}
std::string DescribeSQLLogRecordsRequest::getThreadID()const
{
return threadID_;
}
void DescribeSQLLogRecordsRequest::setThreadID(const std::string& threadID)
{
threadID_ = threadID;
setParameter("ThreadID", threadID);
}
std::string DescribeSQLLogRecordsRequest::getChildDBInstanceIDs()const
{
return childDBInstanceIDs_;
}
void DescribeSQLLogRecordsRequest::setChildDBInstanceIDs(const std::string& childDBInstanceIDs)
{
childDBInstanceIDs_ = childDBInstanceIDs;
setParameter("ChildDBInstanceIDs", childDBInstanceIDs);
}
std::string DescribeSQLLogRecordsRequest::getSortMethod()const
{
return sortMethod_;
}
void DescribeSQLLogRecordsRequest::setSortMethod(const std::string& sortMethod)
{
sortMethod_ = sortMethod;
setParameter("SortMethod", sortMethod);
}
long DescribeSQLLogRecordsRequest::getMaxScanRows()const
{
return maxScanRows_;
}
void DescribeSQLLogRecordsRequest::setMaxScanRows(long maxScanRows)
{
maxScanRows_ = maxScanRows;
setParameter("MaxScanRows", std::to_string(maxScanRows));
}

View File

@@ -0,0 +1,160 @@
/*
* 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/DescribeSQLLogRecordsResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Polardb;
using namespace AlibabaCloud::Polardb::Model;
DescribeSQLLogRecordsResult::DescribeSQLLogRecordsResult() :
ServiceResult()
{}
DescribeSQLLogRecordsResult::DescribeSQLLogRecordsResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeSQLLogRecordsResult::~DescribeSQLLogRecordsResult()
{}
void DescribeSQLLogRecordsResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allItemsNode = value["Items"]["SQLLogRecord"];
for (auto valueItemsSQLLogRecord : allItemsNode)
{
SQLLogRecord itemsObject;
if(!valueItemsSQLLogRecord["ExecuteTime"].isNull())
itemsObject.executeTime = valueItemsSQLLogRecord["ExecuteTime"].asString();
if(!valueItemsSQLLogRecord["InsName"].isNull())
itemsObject.insName = valueItemsSQLLogRecord["InsName"].asString();
if(!valueItemsSQLLogRecord["HostAddress"].isNull())
itemsObject.hostAddress = valueItemsSQLLogRecord["HostAddress"].asString();
if(!valueItemsSQLLogRecord["UpdateRows"].isNull())
itemsObject.updateRows = std::stol(valueItemsSQLLogRecord["UpdateRows"].asString());
if(!valueItemsSQLLogRecord["SQLText"].isNull())
itemsObject.sQLText = valueItemsSQLLogRecord["SQLText"].asString();
if(!valueItemsSQLLogRecord["OriginTime"].isNull())
itemsObject.originTime = valueItemsSQLLogRecord["OriginTime"].asString();
if(!valueItemsSQLLogRecord["Consume"].isNull())
itemsObject.consume = std::stol(valueItemsSQLLogRecord["Consume"].asString());
if(!valueItemsSQLLogRecord["ScanRows"].isNull())
itemsObject.scanRows = std::stol(valueItemsSQLLogRecord["ScanRows"].asString());
if(!valueItemsSQLLogRecord["ThreadID"].isNull())
itemsObject.threadID = std::stoi(valueItemsSQLLogRecord["ThreadID"].asString());
if(!valueItemsSQLLogRecord["State"].isNull())
itemsObject.state = valueItemsSQLLogRecord["State"].asString();
if(!valueItemsSQLLogRecord["DBName"].isNull())
itemsObject.dBName = valueItemsSQLLogRecord["DBName"].asString();
if(!valueItemsSQLLogRecord["SqlType"].isNull())
itemsObject.sqlType = valueItemsSQLLogRecord["SqlType"].asString();
if(!valueItemsSQLLogRecord["Vip"].isNull())
itemsObject.vip = valueItemsSQLLogRecord["Vip"].asString();
if(!valueItemsSQLLogRecord["AccountName"].isNull())
itemsObject.accountName = valueItemsSQLLogRecord["AccountName"].asString();
items_.push_back(itemsObject);
}
if(!value["MaxRecordsPerPage"].isNull())
maxRecordsPerPage_ = std::stoi(value["MaxRecordsPerPage"].asString());
if(!value["ItemsNumbers"].isNull())
itemsNumbers_ = std::stoi(value["ItemsNumbers"].asString());
if(!value["EndTime"].isNull())
endTime_ = value["EndTime"].asString();
if(!value["DBInstanceID"].isNull())
dBInstanceID_ = value["DBInstanceID"].asString();
if(!value["StartTime"].isNull())
startTime_ = value["StartTime"].asString();
if(!value["TotalRecords"].isNull())
totalRecords_ = std::stoi(value["TotalRecords"].asString());
if(!value["Finish"].isNull())
finish_ = value["Finish"].asString();
if(!value["PageNumbers"].isNull())
pageNumbers_ = std::stoi(value["PageNumbers"].asString());
if(!value["JobId"].isNull())
jobId_ = value["JobId"].asString();
if(!value["PagingID"].isNull())
pagingID_ = value["PagingID"].asString();
if(!value["DBInstanceName"].isNull())
dBInstanceName_ = value["DBInstanceName"].asString();
}
int DescribeSQLLogRecordsResult::getMaxRecordsPerPage()const
{
return maxRecordsPerPage_;
}
int DescribeSQLLogRecordsResult::getItemsNumbers()const
{
return itemsNumbers_;
}
std::string DescribeSQLLogRecordsResult::getEndTime()const
{
return endTime_;
}
std::string DescribeSQLLogRecordsResult::getDBInstanceID()const
{
return dBInstanceID_;
}
std::string DescribeSQLLogRecordsResult::getStartTime()const
{
return startTime_;
}
int DescribeSQLLogRecordsResult::getTotalRecords()const
{
return totalRecords_;
}
std::vector<DescribeSQLLogRecordsResult::SQLLogRecord> DescribeSQLLogRecordsResult::getItems()const
{
return items_;
}
std::string DescribeSQLLogRecordsResult::getFinish()const
{
return finish_;
}
int DescribeSQLLogRecordsResult::getPageNumbers()const
{
return pageNumbers_;
}
std::string DescribeSQLLogRecordsResult::getJobId()const
{
return jobId_;
}
std::string DescribeSQLLogRecordsResult::getPagingID()const
{
return pagingID_;
}
std::string DescribeSQLLogRecordsResult::getDBInstanceName()const
{
return dBInstanceName_;
}

View File

@@ -0,0 +1,260 @@
/*
* 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/DescribeSQLLogTemplatesRequest.h>
using AlibabaCloud::Polardb::Model::DescribeSQLLogTemplatesRequest;
DescribeSQLLogTemplatesRequest::DescribeSQLLogTemplatesRequest() :
RpcServiceRequest("polardb", "2017-08-01", "DescribeSQLLogTemplates")
{
setMethod(HttpRequest::Method::Post);
}
DescribeSQLLogTemplatesRequest::~DescribeSQLLogTemplatesRequest()
{}
long DescribeSQLLogTemplatesRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeSQLLogTemplatesRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeSQLLogTemplatesRequest::getStartTime()const
{
return startTime_;
}
void DescribeSQLLogTemplatesRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setParameter("StartTime", startTime);
}
std::string DescribeSQLLogTemplatesRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeSQLLogTemplatesRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeSQLLogTemplatesRequest::getJobId()const
{
return jobId_;
}
void DescribeSQLLogTemplatesRequest::setJobId(const std::string& jobId)
{
jobId_ = jobId;
setParameter("JobId", jobId);
}
std::string DescribeSQLLogTemplatesRequest::getSortKey()const
{
return sortKey_;
}
void DescribeSQLLogTemplatesRequest::setSortKey(const std::string& sortKey)
{
sortKey_ = sortKey;
setParameter("SortKey", sortKey);
}
float DescribeSQLLogTemplatesRequest::getMinAvgScanRows()const
{
return minAvgScanRows_;
}
void DescribeSQLLogTemplatesRequest::setMinAvgScanRows(float minAvgScanRows)
{
minAvgScanRows_ = minAvgScanRows;
setParameter("MinAvgScanRows", std::to_string(minAvgScanRows));
}
std::string DescribeSQLLogTemplatesRequest::getSecurityToken()const
{
return securityToken_;
}
void DescribeSQLLogTemplatesRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setParameter("SecurityToken", securityToken);
}
int DescribeSQLLogTemplatesRequest::getPageNumbers()const
{
return pageNumbers_;
}
void DescribeSQLLogTemplatesRequest::setPageNumbers(int pageNumbers)
{
pageNumbers_ = pageNumbers;
setParameter("PageNumbers", std::to_string(pageNumbers));
}
std::string DescribeSQLLogTemplatesRequest::getPagingId()const
{
return pagingId_;
}
void DescribeSQLLogTemplatesRequest::setPagingId(const std::string& pagingId)
{
pagingId_ = pagingId;
setParameter("PagingId", pagingId);
}
std::string DescribeSQLLogTemplatesRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void DescribeSQLLogTemplatesRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setParameter("DBInstanceId", dBInstanceId);
}
float DescribeSQLLogTemplatesRequest::getMaxAvgScanRows()const
{
return maxAvgScanRows_;
}
void DescribeSQLLogTemplatesRequest::setMaxAvgScanRows(float maxAvgScanRows)
{
maxAvgScanRows_ = maxAvgScanRows;
setParameter("MaxAvgScanRows", std::to_string(maxAvgScanRows));
}
std::string DescribeSQLLogTemplatesRequest::getSqlType()const
{
return sqlType_;
}
void DescribeSQLLogTemplatesRequest::setSqlType(const std::string& sqlType)
{
sqlType_ = sqlType;
setParameter("SqlType", sqlType);
}
std::string DescribeSQLLogTemplatesRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeSQLLogTemplatesRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
float DescribeSQLLogTemplatesRequest::getMinAvgConsume()const
{
return minAvgConsume_;
}
void DescribeSQLLogTemplatesRequest::setMinAvgConsume(float minAvgConsume)
{
minAvgConsume_ = minAvgConsume;
setParameter("MinAvgConsume", std::to_string(minAvgConsume));
}
std::string DescribeSQLLogTemplatesRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeSQLLogTemplatesRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
int DescribeSQLLogTemplatesRequest::getMaxRecordsPerPage()const
{
return maxRecordsPerPage_;
}
void DescribeSQLLogTemplatesRequest::setMaxRecordsPerPage(int maxRecordsPerPage)
{
maxRecordsPerPage_ = maxRecordsPerPage;
setParameter("MaxRecordsPerPage", std::to_string(maxRecordsPerPage));
}
std::string DescribeSQLLogTemplatesRequest::getEndTime()const
{
return endTime_;
}
void DescribeSQLLogTemplatesRequest::setEndTime(const std::string& endTime)
{
endTime_ = endTime;
setParameter("EndTime", endTime);
}
long DescribeSQLLogTemplatesRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeSQLLogTemplatesRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}
float DescribeSQLLogTemplatesRequest::getMaxAvgConsume()const
{
return maxAvgConsume_;
}
void DescribeSQLLogTemplatesRequest::setMaxAvgConsume(float maxAvgConsume)
{
maxAvgConsume_ = maxAvgConsume;
setParameter("MaxAvgConsume", std::to_string(maxAvgConsume));
}
std::string DescribeSQLLogTemplatesRequest::getChildDBInstanceIDs()const
{
return childDBInstanceIDs_;
}
void DescribeSQLLogTemplatesRequest::setChildDBInstanceIDs(const std::string& childDBInstanceIDs)
{
childDBInstanceIDs_ = childDBInstanceIDs;
setParameter("ChildDBInstanceIDs", childDBInstanceIDs);
}
std::string DescribeSQLLogTemplatesRequest::getSortMethod()const
{
return sortMethod_;
}
void DescribeSQLLogTemplatesRequest::setSortMethod(const std::string& sortMethod)
{
sortMethod_ = sortMethod;
setParameter("SortMethod", sortMethod);
}

View File

@@ -0,0 +1,154 @@
/*
* 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/DescribeSQLLogTemplatesResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Polardb;
using namespace AlibabaCloud::Polardb::Model;
DescribeSQLLogTemplatesResult::DescribeSQLLogTemplatesResult() :
ServiceResult()
{}
DescribeSQLLogTemplatesResult::DescribeSQLLogTemplatesResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeSQLLogTemplatesResult::~DescribeSQLLogTemplatesResult()
{}
void DescribeSQLLogTemplatesResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allItemsNode = value["Items"]["Template"];
for (auto valueItemsTemplate : allItemsNode)
{
_Template itemsObject;
if(!valueItemsTemplate["AvgScanRows"].isNull())
itemsObject.avgScanRows = std::stof(valueItemsTemplate["AvgScanRows"].asString());
if(!valueItemsTemplate["TemplateHash"].isNull())
itemsObject.templateHash = valueItemsTemplate["TemplateHash"].asString();
if(!valueItemsTemplate["AvgConsume"].isNull())
itemsObject.avgConsume = std::stof(valueItemsTemplate["AvgConsume"].asString());
if(!valueItemsTemplate["TotalScanRows"].isNull())
itemsObject.totalScanRows = std::stol(valueItemsTemplate["TotalScanRows"].asString());
if(!valueItemsTemplate["TotalUpdateRows"].isNull())
itemsObject.totalUpdateRows = std::stol(valueItemsTemplate["TotalUpdateRows"].asString());
if(!valueItemsTemplate["TotalCounts"].isNull())
itemsObject.totalCounts = std::stol(valueItemsTemplate["TotalCounts"].asString());
if(!valueItemsTemplate["SqlType"].isNull())
itemsObject.sqlType = valueItemsTemplate["SqlType"].asString();
if(!valueItemsTemplate["AvgUpdateRows"].isNull())
itemsObject.avgUpdateRows = std::stof(valueItemsTemplate["AvgUpdateRows"].asString());
if(!valueItemsTemplate["ItemID"].isNull())
itemsObject.itemID = std::stoi(valueItemsTemplate["ItemID"].asString());
if(!valueItemsTemplate["Template"].isNull())
itemsObject._template = valueItemsTemplate["Template"].asString();
if(!valueItemsTemplate["TotalConsume"].isNull())
itemsObject.totalConsume = std::stol(valueItemsTemplate["TotalConsume"].asString());
items_.push_back(itemsObject);
}
if(!value["MaxRecordsPerPage"].isNull())
maxRecordsPerPage_ = std::stoi(value["MaxRecordsPerPage"].asString());
if(!value["ItemsNumbers"].isNull())
itemsNumbers_ = std::stoi(value["ItemsNumbers"].asString());
if(!value["EndTime"].isNull())
endTime_ = value["EndTime"].asString();
if(!value["DBInstanceID"].isNull())
dBInstanceID_ = std::stoi(value["DBInstanceID"].asString());
if(!value["StartTime"].isNull())
startTime_ = value["StartTime"].asString();
if(!value["TotalRecords"].isNull())
totalRecords_ = std::stoi(value["TotalRecords"].asString());
if(!value["Finish"].isNull())
finish_ = value["Finish"].asString();
if(!value["PageNumbers"].isNull())
pageNumbers_ = std::stoi(value["PageNumbers"].asString());
if(!value["JobId"].isNull())
jobId_ = value["JobId"].asString();
if(!value["PagingID"].isNull())
pagingID_ = value["PagingID"].asString();
if(!value["DBInstanceName"].isNull())
dBInstanceName_ = value["DBInstanceName"].asString();
}
int DescribeSQLLogTemplatesResult::getMaxRecordsPerPage()const
{
return maxRecordsPerPage_;
}
int DescribeSQLLogTemplatesResult::getItemsNumbers()const
{
return itemsNumbers_;
}
std::string DescribeSQLLogTemplatesResult::getEndTime()const
{
return endTime_;
}
int DescribeSQLLogTemplatesResult::getDBInstanceID()const
{
return dBInstanceID_;
}
std::string DescribeSQLLogTemplatesResult::getStartTime()const
{
return startTime_;
}
int DescribeSQLLogTemplatesResult::getTotalRecords()const
{
return totalRecords_;
}
std::vector<DescribeSQLLogTemplatesResult::_Template> DescribeSQLLogTemplatesResult::getItems()const
{
return items_;
}
std::string DescribeSQLLogTemplatesResult::getFinish()const
{
return finish_;
}
int DescribeSQLLogTemplatesResult::getPageNumbers()const
{
return pageNumbers_;
}
std::string DescribeSQLLogTemplatesResult::getJobId()const
{
return jobId_;
}
std::string DescribeSQLLogTemplatesResult::getPagingID()const
{
return pagingID_;
}
std::string DescribeSQLLogTemplatesResult::getDBInstanceName()const
{
return dBInstanceName_;
}

View File

@@ -52,28 +52,26 @@ void DescribeScheduleTasksResult::parse(const std::string &payload)
Data::TimerInfosItem timerInfosItemObject;
if(!dataNodeTimerInfostimerInfosItem["Status"].isNull())
timerInfosItemObject.status = dataNodeTimerInfostimerInfosItem["Status"].asString();
if(!dataNodeTimerInfostimerInfosItem["GmtCreate"].isNull())
timerInfosItemObject.gmtCreate = std::stol(dataNodeTimerInfostimerInfosItem["GmtCreate"].asString());
if(!dataNodeTimerInfostimerInfosItem["Action"].isNull())
timerInfosItemObject.action = dataNodeTimerInfostimerInfosItem["Action"].asString();
if(!dataNodeTimerInfostimerInfosItem["TaskId"].isNull())
timerInfosItemObject.taskId = dataNodeTimerInfostimerInfosItem["TaskId"].asString();
if(!dataNodeTimerInfostimerInfosItem["PlannedTime"].isNull())
timerInfosItemObject.plannedTime = dataNodeTimerInfostimerInfosItem["PlannedTime"].asString();
if(!dataNodeTimerInfostimerInfosItem["DbClusterDescription"].isNull())
timerInfosItemObject.dbClusterDescription = dataNodeTimerInfostimerInfosItem["DbClusterDescription"].asString();
if(!dataNodeTimerInfostimerInfosItem["PlannedStartTime"].isNull())
timerInfosItemObject.plannedStartTime = dataNodeTimerInfostimerInfosItem["PlannedStartTime"].asString();
if(!dataNodeTimerInfostimerInfosItem["DBClusterId"].isNull())
timerInfosItemObject.dBClusterId = dataNodeTimerInfostimerInfosItem["DBClusterId"].asString();
if(!dataNodeTimerInfostimerInfosItem["GmtModified"].isNull())
timerInfosItemObject.gmtModified = std::stol(dataNodeTimerInfostimerInfosItem["GmtModified"].asString());
if(!dataNodeTimerInfostimerInfosItem["Region"].isNull())
timerInfosItemObject.region = dataNodeTimerInfostimerInfosItem["Region"].asString();
if(!dataNodeTimerInfostimerInfosItem["OrderId"].isNull())
timerInfosItemObject.orderId = dataNodeTimerInfostimerInfosItem["OrderId"].asString();
if(!dataNodeTimerInfostimerInfosItem["PlannedEndTime"].isNull())
timerInfosItemObject.plannedEndTime = dataNodeTimerInfostimerInfosItem["PlannedEndTime"].asString();
if(!dataNodeTimerInfostimerInfosItem["AliUid"].isNull())
timerInfosItemObject.aliUid = std::stoi(dataNodeTimerInfostimerInfosItem["AliUid"].asString());
if(!dataNodeTimerInfostimerInfosItem["DbClusterStatus"].isNull())
timerInfosItemObject.dbClusterStatus = dataNodeTimerInfostimerInfosItem["DbClusterStatus"].asString();
data_.timerInfos.push_back(timerInfosItemObject);
}
if(!value["Message"].isNull())

View File

@@ -1,106 +0,0 @@
/*
* 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/DescribeSqlLogTrialStatusRequest.h>
using AlibabaCloud::Polardb::Model::DescribeSqlLogTrialStatusRequest;
DescribeSqlLogTrialStatusRequest::DescribeSqlLogTrialStatusRequest() :
RpcServiceRequest("polardb", "2017-08-01", "DescribeSqlLogTrialStatus")
{
setMethod(HttpRequest::Method::Post);
}
DescribeSqlLogTrialStatusRequest::~DescribeSqlLogTrialStatusRequest()
{}
long DescribeSqlLogTrialStatusRequest::getResourceOwnerId()const
{
return resourceOwnerId_;
}
void DescribeSqlLogTrialStatusRequest::setResourceOwnerId(long resourceOwnerId)
{
resourceOwnerId_ = resourceOwnerId;
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string DescribeSqlLogTrialStatusRequest::getAccessKeyId()const
{
return accessKeyId_;
}
void DescribeSqlLogTrialStatusRequest::setAccessKeyId(const std::string& accessKeyId)
{
accessKeyId_ = accessKeyId;
setParameter("AccessKeyId", accessKeyId);
}
std::string DescribeSqlLogTrialStatusRequest::getSecurityToken()const
{
return securityToken_;
}
void DescribeSqlLogTrialStatusRequest::setSecurityToken(const std::string& securityToken)
{
securityToken_ = securityToken;
setParameter("SecurityToken", securityToken);
}
std::string DescribeSqlLogTrialStatusRequest::getDBInstanceId()const
{
return dBInstanceId_;
}
void DescribeSqlLogTrialStatusRequest::setDBInstanceId(const std::string& dBInstanceId)
{
dBInstanceId_ = dBInstanceId;
setParameter("DBInstanceId", dBInstanceId);
}
std::string DescribeSqlLogTrialStatusRequest::getResourceOwnerAccount()const
{
return resourceOwnerAccount_;
}
void DescribeSqlLogTrialStatusRequest::setResourceOwnerAccount(const std::string& resourceOwnerAccount)
{
resourceOwnerAccount_ = resourceOwnerAccount;
setParameter("ResourceOwnerAccount", resourceOwnerAccount);
}
std::string DescribeSqlLogTrialStatusRequest::getOwnerAccount()const
{
return ownerAccount_;
}
void DescribeSqlLogTrialStatusRequest::setOwnerAccount(const std::string& ownerAccount)
{
ownerAccount_ = ownerAccount;
setParameter("OwnerAccount", ownerAccount);
}
long DescribeSqlLogTrialStatusRequest::getOwnerId()const
{
return ownerId_;
}
void DescribeSqlLogTrialStatusRequest::setOwnerId(long ownerId)
{
ownerId_ = ownerId;
setParameter("OwnerId", std::to_string(ownerId));
}

View File

@@ -1,79 +0,0 @@
/*
* 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/DescribeSqlLogTrialStatusResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Polardb;
using namespace AlibabaCloud::Polardb::Model;
DescribeSqlLogTrialStatusResult::DescribeSqlLogTrialStatusResult() :
ServiceResult()
{}
DescribeSqlLogTrialStatusResult::DescribeSqlLogTrialStatusResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeSqlLogTrialStatusResult::~DescribeSqlLogTrialStatusResult()
{}
void DescribeSqlLogTrialStatusResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["EverTrialed"].isNull())
everTrialed_ = value["EverTrialed"].asString();
if(!value["OpenTrial"].isNull())
openTrial_ = value["OpenTrial"].asString();
if(!value["RemainDays"].isNull())
remainDays_ = value["RemainDays"].asString();
if(!value["UsedDays"].isNull())
usedDays_ = value["UsedDays"].asString();
if(!value["DBInstanceName"].isNull())
dBInstanceName_ = value["DBInstanceName"].asString();
}
std::string DescribeSqlLogTrialStatusResult::getEverTrialed()const
{
return everTrialed_;
}
std::string DescribeSqlLogTrialStatusResult::getOpenTrial()const
{
return openTrial_;
}
std::string DescribeSqlLogTrialStatusResult::getRemainDays()const
{
return remainDays_;
}
std::string DescribeSqlLogTrialStatusResult::getUsedDays()const
{
return usedDays_;
}
std::string DescribeSqlLogTrialStatusResult::getDBInstanceName()const
{
return dBInstanceName_;
}

View File

@@ -159,3 +159,14 @@ void ModifyBackupPolicyRequest::setBackupRetentionPeriod(const std::string& back
setParameter("BackupRetentionPeriod", backupRetentionPeriod);
}
std::string ModifyBackupPolicyRequest::getBackupFrequency()const
{
return backupFrequency_;
}
void ModifyBackupPolicyRequest::setBackupFrequency(const std::string& backupFrequency)
{
backupFrequency_ = backupFrequency;
setParameter("BackupFrequency", backupFrequency);
}

View File

@@ -49,6 +49,17 @@ void ModifyDBClusterParametersRequest::setAccessKeyId(const std::string& accessK
setParameter("AccessKeyId", accessKeyId);
}
std::string ModifyDBClusterParametersRequest::getParameterGroupId()const
{
return parameterGroupId_;
}
void ModifyDBClusterParametersRequest::setParameterGroupId(const std::string& parameterGroupId)
{
parameterGroupId_ = parameterGroupId;
setParameter("ParameterGroupId", parameterGroupId);
}
std::string ModifyDBClusterParametersRequest::getEffectiveTime()const
{
return effectiveTime_;

View File

@@ -38,6 +38,17 @@ void UpgradeDBClusterVersionRequest::setResourceOwnerId(long resourceOwnerId)
setParameter("ResourceOwnerId", std::to_string(resourceOwnerId));
}
std::string UpgradeDBClusterVersionRequest::getUpgradeType()const
{
return upgradeType_;
}
void UpgradeDBClusterVersionRequest::setUpgradeType(const std::string& upgradeType)
{
upgradeType_ = upgradeType;
setParameter("UpgradeType", upgradeType);
}
std::string UpgradeDBClusterVersionRequest::getPlannedEndTime()const
{
return plannedEndTime_;