Public ListServiceUsages OpenApi.
This commit is contained in:
@@ -37,6 +37,8 @@ set(computenestsupplier_public_header_model
|
||||
include/alibabacloud/computenestsupplier/model/ListArtifactsResult.h
|
||||
include/alibabacloud/computenestsupplier/model/ListServiceInstancesRequest.h
|
||||
include/alibabacloud/computenestsupplier/model/ListServiceInstancesResult.h
|
||||
include/alibabacloud/computenestsupplier/model/ListServiceUsagesRequest.h
|
||||
include/alibabacloud/computenestsupplier/model/ListServiceUsagesResult.h
|
||||
include/alibabacloud/computenestsupplier/model/ReleaseArtifactRequest.h
|
||||
include/alibabacloud/computenestsupplier/model/ReleaseArtifactResult.h
|
||||
include/alibabacloud/computenestsupplier/model/UpdateArtifactRequest.h
|
||||
@@ -60,6 +62,8 @@ set(computenestsupplier_src
|
||||
src/model/ListArtifactsResult.cc
|
||||
src/model/ListServiceInstancesRequest.cc
|
||||
src/model/ListServiceInstancesResult.cc
|
||||
src/model/ListServiceUsagesRequest.cc
|
||||
src/model/ListServiceUsagesResult.cc
|
||||
src/model/ReleaseArtifactRequest.cc
|
||||
src/model/ReleaseArtifactResult.cc
|
||||
src/model/UpdateArtifactRequest.cc
|
||||
|
||||
@@ -38,6 +38,8 @@
|
||||
#include "model/ListArtifactsResult.h"
|
||||
#include "model/ListServiceInstancesRequest.h"
|
||||
#include "model/ListServiceInstancesResult.h"
|
||||
#include "model/ListServiceUsagesRequest.h"
|
||||
#include "model/ListServiceUsagesResult.h"
|
||||
#include "model/ReleaseArtifactRequest.h"
|
||||
#include "model/ReleaseArtifactResult.h"
|
||||
#include "model/UpdateArtifactRequest.h"
|
||||
@@ -75,6 +77,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::ListServiceInstancesResult> ListServiceInstancesOutcome;
|
||||
typedef std::future<ListServiceInstancesOutcome> ListServiceInstancesOutcomeCallable;
|
||||
typedef std::function<void(const ComputeNestSupplierClient*, const Model::ListServiceInstancesRequest&, const ListServiceInstancesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListServiceInstancesAsyncHandler;
|
||||
typedef Outcome<Error, Model::ListServiceUsagesResult> ListServiceUsagesOutcome;
|
||||
typedef std::future<ListServiceUsagesOutcome> ListServiceUsagesOutcomeCallable;
|
||||
typedef std::function<void(const ComputeNestSupplierClient*, const Model::ListServiceUsagesRequest&, const ListServiceUsagesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListServiceUsagesAsyncHandler;
|
||||
typedef Outcome<Error, Model::ReleaseArtifactResult> ReleaseArtifactOutcome;
|
||||
typedef std::future<ReleaseArtifactOutcome> ReleaseArtifactOutcomeCallable;
|
||||
typedef std::function<void(const ComputeNestSupplierClient*, const Model::ReleaseArtifactRequest&, const ReleaseArtifactOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ReleaseArtifactAsyncHandler;
|
||||
@@ -110,6 +115,9 @@ namespace AlibabaCloud
|
||||
ListServiceInstancesOutcome listServiceInstances(const Model::ListServiceInstancesRequest &request)const;
|
||||
void listServiceInstancesAsync(const Model::ListServiceInstancesRequest& request, const ListServiceInstancesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListServiceInstancesOutcomeCallable listServiceInstancesCallable(const Model::ListServiceInstancesRequest& request) const;
|
||||
ListServiceUsagesOutcome listServiceUsages(const Model::ListServiceUsagesRequest &request)const;
|
||||
void listServiceUsagesAsync(const Model::ListServiceUsagesRequest& request, const ListServiceUsagesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListServiceUsagesOutcomeCallable listServiceUsagesCallable(const Model::ListServiceUsagesRequest& request) const;
|
||||
ReleaseArtifactOutcome releaseArtifact(const Model::ReleaseArtifactRequest &request)const;
|
||||
void releaseArtifactAsync(const Model::ReleaseArtifactRequest& request, const ReleaseArtifactAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ReleaseArtifactOutcomeCallable releaseArtifactCallable(const Model::ReleaseArtifactRequest& request) const;
|
||||
|
||||
@@ -59,7 +59,18 @@ namespace AlibabaCloud
|
||||
{
|
||||
struct PrivateVpcConnection
|
||||
{
|
||||
struct ConnectionConfig
|
||||
{
|
||||
std::vector<std::string> securityGroups;
|
||||
std::vector<std::string> endpointIps;
|
||||
std::string ingressEndpointStatus;
|
||||
std::string vpcId;
|
||||
std::string networkServiceStatus;
|
||||
std::vector<std::string> vSwitches;
|
||||
};
|
||||
std::string endpointServiceId;
|
||||
std::string privateZoneName;
|
||||
std::vector<PrivateVpcConnection::ConnectionConfig> connectionConfigs;
|
||||
std::string endpointId;
|
||||
};
|
||||
struct ReversePrivateVpcConnection
|
||||
|
||||
@@ -79,6 +79,7 @@ namespace AlibabaCloud
|
||||
std::string statusDetail;
|
||||
std::string updateTime;
|
||||
std::string templateName;
|
||||
bool isOperated;
|
||||
std::vector<ServiceInstance::Tag> tags;
|
||||
};
|
||||
|
||||
|
||||
@@ -0,0 +1,51 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_COMPUTENESTSUPPLIER_MODEL_LISTSERVICEUSAGESREQUEST_H_
|
||||
#define ALIBABACLOUD_COMPUTENESTSUPPLIER_MODEL_LISTSERVICEUSAGESREQUEST_H_
|
||||
|
||||
#include <alibabacloud/computenestsupplier/ComputeNestSupplierExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace ComputeNestSupplier {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_COMPUTENESTSUPPLIER_EXPORT ListServiceUsagesRequest : public RpcServiceRequest {
|
||||
public:
|
||||
struct Filter {
|
||||
std::string name;
|
||||
};
|
||||
ListServiceUsagesRequest();
|
||||
~ListServiceUsagesRequest();
|
||||
std::string getNextToken() const;
|
||||
void setNextToken(const std::string &nextToken);
|
||||
std::vector<Filter> getFilter() const;
|
||||
void setFilter(const std::vector<Filter> &filter);
|
||||
int getMaxResults() const;
|
||||
void setMaxResults(int maxResults);
|
||||
|
||||
private:
|
||||
std::string nextToken_;
|
||||
std::vector<Filter> filter_;
|
||||
int maxResults_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace ComputeNestSupplier
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_COMPUTENESTSUPPLIER_MODEL_LISTSERVICEUSAGESREQUEST_H_
|
||||
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_COMPUTENESTSUPPLIER_MODEL_LISTSERVICEUSAGESRESULT_H_
|
||||
#define ALIBABACLOUD_COMPUTENESTSUPPLIER_MODEL_LISTSERVICEUSAGESRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/computenestsupplier/ComputeNestSupplierExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace ComputeNestSupplier
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_COMPUTENESTSUPPLIER_EXPORT ListServiceUsagesResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Policy
|
||||
{
|
||||
struct UserInformation
|
||||
{
|
||||
std::string industry;
|
||||
std::string company;
|
||||
std::string telephone;
|
||||
std::string country;
|
||||
std::string title;
|
||||
std::string emailAddress;
|
||||
std::string source;
|
||||
std::string name;
|
||||
};
|
||||
std::string status;
|
||||
std::string serviceName;
|
||||
std::string supplierName;
|
||||
long userAliUid;
|
||||
std::string comments;
|
||||
std::string createTime;
|
||||
UserInformation userInformation;
|
||||
std::string updateTime;
|
||||
std::string serviceId;
|
||||
};
|
||||
|
||||
|
||||
ListServiceUsagesResult();
|
||||
explicit ListServiceUsagesResult(const std::string &payload);
|
||||
~ListServiceUsagesResult();
|
||||
int getTotalCount()const;
|
||||
std::string getNextToken()const;
|
||||
int getMaxResults()const;
|
||||
std::vector<Policy> getServiceUsages()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
int totalCount_;
|
||||
std::string nextToken_;
|
||||
int maxResults_;
|
||||
std::vector<Policy> serviceUsages_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_COMPUTENESTSUPPLIER_MODEL_LISTSERVICEUSAGESRESULT_H_
|
||||
@@ -339,6 +339,42 @@ ComputeNestSupplierClient::ListServiceInstancesOutcomeCallable ComputeNestSuppli
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
ComputeNestSupplierClient::ListServiceUsagesOutcome ComputeNestSupplierClient::listServiceUsages(const ListServiceUsagesRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ListServiceUsagesOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ListServiceUsagesOutcome(ListServiceUsagesResult(outcome.result()));
|
||||
else
|
||||
return ListServiceUsagesOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void ComputeNestSupplierClient::listServiceUsagesAsync(const ListServiceUsagesRequest& request, const ListServiceUsagesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, listServiceUsages(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
ComputeNestSupplierClient::ListServiceUsagesOutcomeCallable ComputeNestSupplierClient::listServiceUsagesCallable(const ListServiceUsagesRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ListServiceUsagesOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->listServiceUsages(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
ComputeNestSupplierClient::ReleaseArtifactOutcome ComputeNestSupplierClient::releaseArtifact(const ReleaseArtifactRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
@@ -101,6 +101,29 @@ void GetServiceInstanceResult::parse(const std::string &payload)
|
||||
privateVpcConnectionObject.endpointId = networkConfigNodePrivateVpcConnectionsPrivateVpcConnection["EndpointId"].asString();
|
||||
if(!networkConfigNodePrivateVpcConnectionsPrivateVpcConnection["EndpointServiceId"].isNull())
|
||||
privateVpcConnectionObject.endpointServiceId = networkConfigNodePrivateVpcConnectionsPrivateVpcConnection["EndpointServiceId"].asString();
|
||||
if(!networkConfigNodePrivateVpcConnectionsPrivateVpcConnection["PrivateZoneName"].isNull())
|
||||
privateVpcConnectionObject.privateZoneName = networkConfigNodePrivateVpcConnectionsPrivateVpcConnection["PrivateZoneName"].asString();
|
||||
auto allConnectionConfigsNode = networkConfigNodePrivateVpcConnectionsPrivateVpcConnection["ConnectionConfigs"]["ConnectionConfig"];
|
||||
for (auto networkConfigNodePrivateVpcConnectionsPrivateVpcConnectionConnectionConfigsConnectionConfig : allConnectionConfigsNode)
|
||||
{
|
||||
NetworkConfig::PrivateVpcConnection::ConnectionConfig connectionConfigsObject;
|
||||
if(!networkConfigNodePrivateVpcConnectionsPrivateVpcConnectionConnectionConfigsConnectionConfig["VpcId"].isNull())
|
||||
connectionConfigsObject.vpcId = networkConfigNodePrivateVpcConnectionsPrivateVpcConnectionConnectionConfigsConnectionConfig["VpcId"].asString();
|
||||
if(!networkConfigNodePrivateVpcConnectionsPrivateVpcConnectionConnectionConfigsConnectionConfig["IngressEndpointStatus"].isNull())
|
||||
connectionConfigsObject.ingressEndpointStatus = networkConfigNodePrivateVpcConnectionsPrivateVpcConnectionConnectionConfigsConnectionConfig["IngressEndpointStatus"].asString();
|
||||
if(!networkConfigNodePrivateVpcConnectionsPrivateVpcConnectionConnectionConfigsConnectionConfig["NetworkServiceStatus"].isNull())
|
||||
connectionConfigsObject.networkServiceStatus = networkConfigNodePrivateVpcConnectionsPrivateVpcConnectionConnectionConfigsConnectionConfig["NetworkServiceStatus"].asString();
|
||||
auto allSecurityGroups = value["SecurityGroups"]["SecurityGroup"];
|
||||
for (auto value : allSecurityGroups)
|
||||
connectionConfigsObject.securityGroups.push_back(value.asString());
|
||||
auto allVSwitches = value["VSwitches"]["VSwitch"];
|
||||
for (auto value : allVSwitches)
|
||||
connectionConfigsObject.vSwitches.push_back(value.asString());
|
||||
auto allEndpointIps = value["EndpointIps"]["EndpointIp"];
|
||||
for (auto value : allEndpointIps)
|
||||
connectionConfigsObject.endpointIps.push_back(value.asString());
|
||||
privateVpcConnectionObject.connectionConfigs.push_back(connectionConfigsObject);
|
||||
}
|
||||
networkConfig_.privateVpcConnections.push_back(privateVpcConnectionObject);
|
||||
}
|
||||
auto allReversePrivateVpcConnectionsNode = networkConfigNode["ReversePrivateVpcConnections"]["ReversePrivateVpcConnection"];
|
||||
|
||||
@@ -79,6 +79,8 @@ void ListServiceInstancesResult::parse(const std::string &payload)
|
||||
serviceInstancesObject.serviceType = valueServiceInstancesServiceInstance["ServiceType"].asString();
|
||||
if(!valueServiceInstancesServiceInstance["PayType"].isNull())
|
||||
serviceInstancesObject.payType = valueServiceInstancesServiceInstance["PayType"].asString();
|
||||
if(!valueServiceInstancesServiceInstance["IsOperated"].isNull())
|
||||
serviceInstancesObject.isOperated = valueServiceInstancesServiceInstance["IsOperated"].asString() == "true";
|
||||
auto allTagsNode = valueServiceInstancesServiceInstance["Tags"]["Tag"];
|
||||
for (auto valueServiceInstancesServiceInstanceTagsTag : allTagsNode)
|
||||
{
|
||||
|
||||
58
computenestsupplier/src/model/ListServiceUsagesRequest.cc
Normal file
58
computenestsupplier/src/model/ListServiceUsagesRequest.cc
Normal file
@@ -0,0 +1,58 @@
|
||||
/*
|
||||
* 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/computenestsupplier/model/ListServiceUsagesRequest.h>
|
||||
|
||||
using AlibabaCloud::ComputeNestSupplier::Model::ListServiceUsagesRequest;
|
||||
|
||||
ListServiceUsagesRequest::ListServiceUsagesRequest()
|
||||
: RpcServiceRequest("computenestsupplier", "2021-05-21", "ListServiceUsages") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ListServiceUsagesRequest::~ListServiceUsagesRequest() {}
|
||||
|
||||
std::string ListServiceUsagesRequest::getNextToken() const {
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
void ListServiceUsagesRequest::setNextToken(const std::string &nextToken) {
|
||||
nextToken_ = nextToken;
|
||||
setParameter(std::string("NextToken"), nextToken);
|
||||
}
|
||||
|
||||
std::vector<ListServiceUsagesRequest::Filter> ListServiceUsagesRequest::getFilter() const {
|
||||
return filter_;
|
||||
}
|
||||
|
||||
void ListServiceUsagesRequest::setFilter(const std::vector<ListServiceUsagesRequest::Filter> &filter) {
|
||||
filter_ = filter;
|
||||
for(int dep1 = 0; dep1 != filter.size(); dep1++) {
|
||||
auto filterObj = filter.at(dep1);
|
||||
std::string filterObjStr = std::string("Filter") + "." + std::to_string(dep1 + 1);
|
||||
setParameter(filterObjStr + ".Name", filterObj.name);
|
||||
}
|
||||
}
|
||||
|
||||
int ListServiceUsagesRequest::getMaxResults() const {
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
void ListServiceUsagesRequest::setMaxResults(int maxResults) {
|
||||
maxResults_ = maxResults;
|
||||
setParameter(std::string("MaxResults"), std::to_string(maxResults));
|
||||
}
|
||||
|
||||
109
computenestsupplier/src/model/ListServiceUsagesResult.cc
Normal file
109
computenestsupplier/src/model/ListServiceUsagesResult.cc
Normal file
@@ -0,0 +1,109 @@
|
||||
/*
|
||||
* 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/computenestsupplier/model/ListServiceUsagesResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::ComputeNestSupplier;
|
||||
using namespace AlibabaCloud::ComputeNestSupplier::Model;
|
||||
|
||||
ListServiceUsagesResult::ListServiceUsagesResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ListServiceUsagesResult::ListServiceUsagesResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ListServiceUsagesResult::~ListServiceUsagesResult()
|
||||
{}
|
||||
|
||||
void ListServiceUsagesResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allServiceUsagesNode = value["ServiceUsages"]["Policy"];
|
||||
for (auto valueServiceUsagesPolicy : allServiceUsagesNode)
|
||||
{
|
||||
Policy serviceUsagesObject;
|
||||
if(!valueServiceUsagesPolicy["UserAliUid"].isNull())
|
||||
serviceUsagesObject.userAliUid = std::stol(valueServiceUsagesPolicy["UserAliUid"].asString());
|
||||
if(!valueServiceUsagesPolicy["ServiceId"].isNull())
|
||||
serviceUsagesObject.serviceId = valueServiceUsagesPolicy["ServiceId"].asString();
|
||||
if(!valueServiceUsagesPolicy["ServiceName"].isNull())
|
||||
serviceUsagesObject.serviceName = valueServiceUsagesPolicy["ServiceName"].asString();
|
||||
if(!valueServiceUsagesPolicy["SupplierName"].isNull())
|
||||
serviceUsagesObject.supplierName = valueServiceUsagesPolicy["SupplierName"].asString();
|
||||
if(!valueServiceUsagesPolicy["Status"].isNull())
|
||||
serviceUsagesObject.status = valueServiceUsagesPolicy["Status"].asString();
|
||||
if(!valueServiceUsagesPolicy["Comments"].isNull())
|
||||
serviceUsagesObject.comments = valueServiceUsagesPolicy["Comments"].asString();
|
||||
if(!valueServiceUsagesPolicy["CreateTime"].isNull())
|
||||
serviceUsagesObject.createTime = valueServiceUsagesPolicy["CreateTime"].asString();
|
||||
if(!valueServiceUsagesPolicy["UpdateTime"].isNull())
|
||||
serviceUsagesObject.updateTime = valueServiceUsagesPolicy["UpdateTime"].asString();
|
||||
auto userInformationNode = value["UserInformation"];
|
||||
if(!userInformationNode["Name"].isNull())
|
||||
serviceUsagesObject.userInformation.name = userInformationNode["Name"].asString();
|
||||
if(!userInformationNode["EmailAddress"].isNull())
|
||||
serviceUsagesObject.userInformation.emailAddress = userInformationNode["EmailAddress"].asString();
|
||||
if(!userInformationNode["Company"].isNull())
|
||||
serviceUsagesObject.userInformation.company = userInformationNode["Company"].asString();
|
||||
if(!userInformationNode["Country"].isNull())
|
||||
serviceUsagesObject.userInformation.country = userInformationNode["Country"].asString();
|
||||
if(!userInformationNode["Telephone"].isNull())
|
||||
serviceUsagesObject.userInformation.telephone = userInformationNode["Telephone"].asString();
|
||||
if(!userInformationNode["Title"].isNull())
|
||||
serviceUsagesObject.userInformation.title = userInformationNode["Title"].asString();
|
||||
if(!userInformationNode["Industry"].isNull())
|
||||
serviceUsagesObject.userInformation.industry = userInformationNode["Industry"].asString();
|
||||
if(!userInformationNode["Source"].isNull())
|
||||
serviceUsagesObject.userInformation.source = userInformationNode["Source"].asString();
|
||||
serviceUsages_.push_back(serviceUsagesObject);
|
||||
}
|
||||
if(!value["NextToken"].isNull())
|
||||
nextToken_ = value["NextToken"].asString();
|
||||
if(!value["MaxResults"].isNull())
|
||||
maxResults_ = std::stoi(value["MaxResults"].asString());
|
||||
if(!value["TotalCount"].isNull())
|
||||
totalCount_ = std::stoi(value["TotalCount"].asString());
|
||||
|
||||
}
|
||||
|
||||
int ListServiceUsagesResult::getTotalCount()const
|
||||
{
|
||||
return totalCount_;
|
||||
}
|
||||
|
||||
std::string ListServiceUsagesResult::getNextToken()const
|
||||
{
|
||||
return nextToken_;
|
||||
}
|
||||
|
||||
int ListServiceUsagesResult::getMaxResults()const
|
||||
{
|
||||
return maxResults_;
|
||||
}
|
||||
|
||||
std::vector<ListServiceUsagesResult::Policy> ListServiceUsagesResult::getServiceUsages()const
|
||||
{
|
||||
return serviceUsages_;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user