PVTZ SDK Auto Released By shenshi,Version:1.34.28
Signed-off-by: haowei.yao <haowei.yao@alibaba-inc.com>
This commit is contained in:
@@ -339,6 +339,42 @@ PvtzClient::BindZoneVpcOutcomeCallable PvtzClient::bindZoneVpcCallable(const Bin
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
PvtzClient::DescribeStatisticSummaryOutcome PvtzClient::describeStatisticSummary(const DescribeStatisticSummaryRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeStatisticSummaryOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeStatisticSummaryOutcome(DescribeStatisticSummaryResult(outcome.result()));
|
||||
else
|
||||
return DescribeStatisticSummaryOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void PvtzClient::describeStatisticSummaryAsync(const DescribeStatisticSummaryRequest& request, const DescribeStatisticSummaryAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeStatisticSummary(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
PvtzClient::DescribeStatisticSummaryOutcomeCallable PvtzClient::describeStatisticSummaryCallable(const DescribeStatisticSummaryRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeStatisticSummaryOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeStatisticSummary(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
PvtzClient::DescribeRequestGraphOutcome PvtzClient::describeRequestGraph(const DescribeRequestGraphRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -375,36 +411,36 @@ PvtzClient::DescribeRequestGraphOutcomeCallable PvtzClient::describeRequestGraph
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
PvtzClient::DescribeStatisticSummaryOutcome PvtzClient::describeStatisticSummary(const DescribeStatisticSummaryRequest &request) const
|
||||
PvtzClient::SetProxyPatternOutcome PvtzClient::setProxyPattern(const SetProxyPatternRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeStatisticSummaryOutcome(endpointOutcome.error());
|
||||
return SetProxyPatternOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeStatisticSummaryOutcome(DescribeStatisticSummaryResult(outcome.result()));
|
||||
return SetProxyPatternOutcome(SetProxyPatternResult(outcome.result()));
|
||||
else
|
||||
return DescribeStatisticSummaryOutcome(outcome.error());
|
||||
return SetProxyPatternOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void PvtzClient::describeStatisticSummaryAsync(const DescribeStatisticSummaryRequest& request, const DescribeStatisticSummaryAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
void PvtzClient::setProxyPatternAsync(const SetProxyPatternRequest& request, const SetProxyPatternAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeStatisticSummary(request), context);
|
||||
handler(this, request, setProxyPattern(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
PvtzClient::DescribeStatisticSummaryOutcomeCallable PvtzClient::describeStatisticSummaryCallable(const DescribeStatisticSummaryRequest &request) const
|
||||
PvtzClient::SetProxyPatternOutcomeCallable PvtzClient::setProxyPatternCallable(const SetProxyPatternRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeStatisticSummaryOutcome()>>(
|
||||
auto task = std::make_shared<std::packaged_task<SetProxyPatternOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeStatisticSummary(request);
|
||||
return this->setProxyPattern(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
@@ -591,42 +627,6 @@ PvtzClient::DescribeRegionsOutcomeCallable PvtzClient::describeRegionsCallable(c
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
PvtzClient::DescribeZoneRecordsOutcome PvtzClient::describeZoneRecords(const DescribeZoneRecordsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeZoneRecordsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeZoneRecordsOutcome(DescribeZoneRecordsResult(outcome.result()));
|
||||
else
|
||||
return DescribeZoneRecordsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void PvtzClient::describeZoneRecordsAsync(const DescribeZoneRecordsRequest& request, const DescribeZoneRecordsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeZoneRecords(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
PvtzClient::DescribeZoneRecordsOutcomeCallable PvtzClient::describeZoneRecordsCallable(const DescribeZoneRecordsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeZoneRecordsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeZoneRecords(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
PvtzClient::SetZoneRecordStatusOutcome PvtzClient::setZoneRecordStatus(const SetZoneRecordStatusRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -663,6 +663,42 @@ PvtzClient::SetZoneRecordStatusOutcomeCallable PvtzClient::setZoneRecordStatusCa
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
PvtzClient::DescribeZoneRecordsOutcome PvtzClient::describeZoneRecords(const DescribeZoneRecordsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeZoneRecordsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeZoneRecordsOutcome(DescribeZoneRecordsResult(outcome.result()));
|
||||
else
|
||||
return DescribeZoneRecordsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void PvtzClient::describeZoneRecordsAsync(const DescribeZoneRecordsRequest& request, const DescribeZoneRecordsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeZoneRecords(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
PvtzClient::DescribeZoneRecordsOutcomeCallable PvtzClient::describeZoneRecordsCallable(const DescribeZoneRecordsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeZoneRecordsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeZoneRecords(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
PvtzClient::DescribeZonesOutcome PvtzClient::describeZones(const DescribeZonesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
@@ -25,6 +25,17 @@ AddZoneRequest::AddZoneRequest() :
|
||||
AddZoneRequest::~AddZoneRequest()
|
||||
{}
|
||||
|
||||
std::string AddZoneRequest::getProxyPattern()const
|
||||
{
|
||||
return proxyPattern_;
|
||||
}
|
||||
|
||||
void AddZoneRequest::setProxyPattern(const std::string& proxyPattern)
|
||||
{
|
||||
proxyPattern_ = proxyPattern;
|
||||
setParameter("ProxyPattern", proxyPattern);
|
||||
}
|
||||
|
||||
std::string AddZoneRequest::getUserClientIp()const
|
||||
{
|
||||
return userClientIp_;
|
||||
|
||||
@@ -36,6 +36,17 @@ void DescribeRegionsRequest::setUserClientIp(const std::string& userClientIp)
|
||||
setParameter("UserClientIp", userClientIp);
|
||||
}
|
||||
|
||||
std::string DescribeRegionsRequest::getAcceptLanguage()const
|
||||
{
|
||||
return acceptLanguage_;
|
||||
}
|
||||
|
||||
void DescribeRegionsRequest::setAcceptLanguage(const std::string& acceptLanguage)
|
||||
{
|
||||
acceptLanguage_ = acceptLanguage;
|
||||
setParameter("AcceptLanguage", acceptLanguage);
|
||||
}
|
||||
|
||||
std::string DescribeRegionsRequest::getLang()const
|
||||
{
|
||||
return lang_;
|
||||
|
||||
@@ -48,6 +48,10 @@ void DescribeRegionsResult::parse(const std::string &payload)
|
||||
regionsObject.regionId = value["RegionId"].asString();
|
||||
if(!value["RegionName"].isNull())
|
||||
regionsObject.regionName = value["RegionName"].asString();
|
||||
if(!value["LocalName"].isNull())
|
||||
regionsObject.localName = value["LocalName"].asString();
|
||||
if(!value["RegionEndpoint"].isNull())
|
||||
regionsObject.regionEndpoint = value["RegionEndpoint"].asString();
|
||||
regions_.push_back(regionsObject);
|
||||
}
|
||||
|
||||
|
||||
@@ -52,6 +52,8 @@ void DescribeZoneInfoResult::parse(const std::string &payload)
|
||||
bindVpcsObject.vpcName = value["VpcName"].asString();
|
||||
if(!value["RegionName"].isNull())
|
||||
bindVpcsObject.regionName = value["RegionName"].asString();
|
||||
if(!value["RegionId"].isNull())
|
||||
bindVpcsObject.regionId = value["RegionId"].asString();
|
||||
bindVpcs_.push_back(bindVpcsObject);
|
||||
}
|
||||
if(!value["ZoneId"].isNull())
|
||||
@@ -72,6 +74,8 @@ void DescribeZoneInfoResult::parse(const std::string &payload)
|
||||
updateTimestamp_ = std::stol(value["UpdateTimestamp"].asString());
|
||||
if(!value["IsPtr"].isNull())
|
||||
isPtr_ = value["IsPtr"].asString() == "true";
|
||||
if(!value["ProxyPattern"].isNull())
|
||||
proxyPattern_ = value["ProxyPattern"].asString();
|
||||
|
||||
}
|
||||
|
||||
@@ -85,6 +89,11 @@ std::string DescribeZoneInfoResult::getZoneId()const
|
||||
return zoneId_;
|
||||
}
|
||||
|
||||
std::string DescribeZoneInfoResult::getProxyPattern()const
|
||||
{
|
||||
return proxyPattern_;
|
||||
}
|
||||
|
||||
std::string DescribeZoneInfoResult::getCreateTime()const
|
||||
{
|
||||
return createTime_;
|
||||
|
||||
@@ -58,6 +58,17 @@ void DescribeZoneRecordsRequest::setZoneId(const std::string& zoneId)
|
||||
setParameter("ZoneId", zoneId);
|
||||
}
|
||||
|
||||
std::string DescribeZoneRecordsRequest::getSearchMode()const
|
||||
{
|
||||
return searchMode_;
|
||||
}
|
||||
|
||||
void DescribeZoneRecordsRequest::setSearchMode(const std::string& searchMode)
|
||||
{
|
||||
searchMode_ = searchMode;
|
||||
setParameter("SearchMode", searchMode);
|
||||
}
|
||||
|
||||
std::string DescribeZoneRecordsRequest::getTag()const
|
||||
{
|
||||
return tag_;
|
||||
@@ -69,17 +80,6 @@ void DescribeZoneRecordsRequest::setTag(const std::string& tag)
|
||||
setParameter("Tag", tag);
|
||||
}
|
||||
|
||||
std::string DescribeZoneRecordsRequest::getKeyword()const
|
||||
{
|
||||
return keyword_;
|
||||
}
|
||||
|
||||
void DescribeZoneRecordsRequest::setKeyword(const std::string& keyword)
|
||||
{
|
||||
keyword_ = keyword;
|
||||
setParameter("Keyword", keyword);
|
||||
}
|
||||
|
||||
std::string DescribeZoneRecordsRequest::getLang()const
|
||||
{
|
||||
return lang_;
|
||||
@@ -91,6 +91,17 @@ void DescribeZoneRecordsRequest::setLang(const std::string& lang)
|
||||
setParameter("Lang", lang);
|
||||
}
|
||||
|
||||
std::string DescribeZoneRecordsRequest::getKeyword()const
|
||||
{
|
||||
return keyword_;
|
||||
}
|
||||
|
||||
void DescribeZoneRecordsRequest::setKeyword(const std::string& keyword)
|
||||
{
|
||||
keyword_ = keyword;
|
||||
setParameter("Keyword", keyword);
|
||||
}
|
||||
|
||||
int DescribeZoneRecordsRequest::getPageNumber()const
|
||||
{
|
||||
return pageNumber_;
|
||||
|
||||
@@ -25,6 +25,17 @@ DescribeZonesRequest::DescribeZonesRequest() :
|
||||
DescribeZonesRequest::~DescribeZonesRequest()
|
||||
{}
|
||||
|
||||
std::string DescribeZonesRequest::getQueryVpcId()const
|
||||
{
|
||||
return queryVpcId_;
|
||||
}
|
||||
|
||||
void DescribeZonesRequest::setQueryVpcId(const std::string& queryVpcId)
|
||||
{
|
||||
queryVpcId_ = queryVpcId;
|
||||
setParameter("QueryVpcId", queryVpcId);
|
||||
}
|
||||
|
||||
int DescribeZonesRequest::getPageSize()const
|
||||
{
|
||||
return pageSize_;
|
||||
@@ -47,6 +58,17 @@ void DescribeZonesRequest::setUserClientIp(const std::string& userClientIp)
|
||||
setParameter("UserClientIp", userClientIp);
|
||||
}
|
||||
|
||||
std::string DescribeZonesRequest::getSearchMode()const
|
||||
{
|
||||
return searchMode_;
|
||||
}
|
||||
|
||||
void DescribeZonesRequest::setSearchMode(const std::string& searchMode)
|
||||
{
|
||||
searchMode_ = searchMode;
|
||||
setParameter("SearchMode", searchMode);
|
||||
}
|
||||
|
||||
std::string DescribeZonesRequest::getLang()const
|
||||
{
|
||||
return lang_;
|
||||
@@ -80,3 +102,14 @@ void DescribeZonesRequest::setPageNumber(int pageNumber)
|
||||
setParameter("PageNumber", std::to_string(pageNumber));
|
||||
}
|
||||
|
||||
std::string DescribeZonesRequest::getQueryRegionId()const
|
||||
{
|
||||
return queryRegionId_;
|
||||
}
|
||||
|
||||
void DescribeZonesRequest::setQueryRegionId(const std::string& queryRegionId)
|
||||
{
|
||||
queryRegionId_ = queryRegionId;
|
||||
setParameter("QueryRegionId", queryRegionId);
|
||||
}
|
||||
|
||||
|
||||
@@ -62,6 +62,8 @@ void DescribeZonesResult::parse(const std::string &payload)
|
||||
zonesObject.updateTimestamp = std::stol(value["UpdateTimestamp"].asString());
|
||||
if(!value["IsPtr"].isNull())
|
||||
zonesObject.isPtr = value["IsPtr"].asString() == "true";
|
||||
if(!value["ProxyPattern"].isNull())
|
||||
zonesObject.proxyPattern = value["ProxyPattern"].asString();
|
||||
zones_.push_back(zonesObject);
|
||||
}
|
||||
if(!value["TotalItems"].isNull())
|
||||
|
||||
71
pvtz/src/model/SetProxyPatternRequest.cc
Normal file
71
pvtz/src/model/SetProxyPatternRequest.cc
Normal file
@@ -0,0 +1,71 @@
|
||||
/*
|
||||
* 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/pvtz/model/SetProxyPatternRequest.h>
|
||||
|
||||
using AlibabaCloud::Pvtz::Model::SetProxyPatternRequest;
|
||||
|
||||
SetProxyPatternRequest::SetProxyPatternRequest() :
|
||||
RpcServiceRequest("pvtz", "2018-01-01", "SetProxyPattern")
|
||||
{}
|
||||
|
||||
SetProxyPatternRequest::~SetProxyPatternRequest()
|
||||
{}
|
||||
|
||||
std::string SetProxyPatternRequest::getProxyPattern()const
|
||||
{
|
||||
return proxyPattern_;
|
||||
}
|
||||
|
||||
void SetProxyPatternRequest::setProxyPattern(const std::string& proxyPattern)
|
||||
{
|
||||
proxyPattern_ = proxyPattern;
|
||||
setParameter("ProxyPattern", proxyPattern);
|
||||
}
|
||||
|
||||
std::string SetProxyPatternRequest::getUserClientIp()const
|
||||
{
|
||||
return userClientIp_;
|
||||
}
|
||||
|
||||
void SetProxyPatternRequest::setUserClientIp(const std::string& userClientIp)
|
||||
{
|
||||
userClientIp_ = userClientIp;
|
||||
setParameter("UserClientIp", userClientIp);
|
||||
}
|
||||
|
||||
std::string SetProxyPatternRequest::getZoneId()const
|
||||
{
|
||||
return zoneId_;
|
||||
}
|
||||
|
||||
void SetProxyPatternRequest::setZoneId(const std::string& zoneId)
|
||||
{
|
||||
zoneId_ = zoneId;
|
||||
setParameter("ZoneId", zoneId);
|
||||
}
|
||||
|
||||
std::string SetProxyPatternRequest::getLang()const
|
||||
{
|
||||
return lang_;
|
||||
}
|
||||
|
||||
void SetProxyPatternRequest::setLang(const std::string& lang)
|
||||
{
|
||||
lang_ = lang;
|
||||
setParameter("Lang", lang);
|
||||
}
|
||||
|
||||
52
pvtz/src/model/SetProxyPatternResult.cc
Normal file
52
pvtz/src/model/SetProxyPatternResult.cc
Normal file
@@ -0,0 +1,52 @@
|
||||
/*
|
||||
* 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/pvtz/model/SetProxyPatternResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Pvtz;
|
||||
using namespace AlibabaCloud::Pvtz::Model;
|
||||
|
||||
SetProxyPatternResult::SetProxyPatternResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
SetProxyPatternResult::SetProxyPatternResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
SetProxyPatternResult::~SetProxyPatternResult()
|
||||
{}
|
||||
|
||||
void SetProxyPatternResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
|
||||
setRequestId(value["RequestId"].asString());
|
||||
if(!value["ZoneId"].isNull())
|
||||
zoneId_ = value["ZoneId"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string SetProxyPatternResult::getZoneId()const
|
||||
{
|
||||
return zoneId_;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user