Generated 2019-09-28 for reid.

This commit is contained in:
sdk-team
2019-12-19 20:45:10 +08:00
parent 3550cece5c
commit 6462c32f5f
58 changed files with 4752 additions and 1 deletions

521
reid/src/ReidClient.cc Normal file
View File

@@ -0,0 +1,521 @@
/*
* 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/reid/ReidClient.h>
#include <alibabacloud/core/SimpleCredentialsProvider.h>
using namespace AlibabaCloud;
using namespace AlibabaCloud::Location;
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
namespace
{
const std::string SERVICE_NAME = "reid";
}
ReidClient::ReidClient(const Credentials &credentials, const ClientConfiguration &configuration) :
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(credentials), configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentials, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "1.0.0");
}
ReidClient::ReidClient(const std::shared_ptr<CredentialsProvider>& credentialsProvider, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, credentialsProvider, configuration)
{
auto locationClient = std::make_shared<LocationClient>(credentialsProvider, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "1.0.0");
}
ReidClient::ReidClient(const std::string & accessKeyId, const std::string & accessKeySecret, const ClientConfiguration & configuration) :
RpcServiceClient(SERVICE_NAME, std::make_shared<SimpleCredentialsProvider>(accessKeyId, accessKeySecret), configuration)
{
auto locationClient = std::make_shared<LocationClient>(accessKeyId, accessKeySecret, configuration);
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "1.0.0");
}
ReidClient::~ReidClient()
{}
ReidClient::DescribeBaseStatisticsOutcome ReidClient::describeBaseStatistics(const DescribeBaseStatisticsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeBaseStatisticsOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeBaseStatisticsOutcome(DescribeBaseStatisticsResult(outcome.result()));
else
return DescribeBaseStatisticsOutcome(outcome.error());
}
void ReidClient::describeBaseStatisticsAsync(const DescribeBaseStatisticsRequest& request, const DescribeBaseStatisticsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeBaseStatistics(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::DescribeBaseStatisticsOutcomeCallable ReidClient::describeBaseStatisticsCallable(const DescribeBaseStatisticsRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeBaseStatisticsOutcome()>>(
[this, request]()
{
return this->describeBaseStatistics(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::DescribeCursorOutcome ReidClient::describeCursor(const DescribeCursorRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeCursorOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeCursorOutcome(DescribeCursorResult(outcome.result()));
else
return DescribeCursorOutcome(outcome.error());
}
void ReidClient::describeCursorAsync(const DescribeCursorRequest& request, const DescribeCursorAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeCursor(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::DescribeCursorOutcomeCallable ReidClient::describeCursorCallable(const DescribeCursorRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeCursorOutcome()>>(
[this, request]()
{
return this->describeCursor(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::DescribeCustomerFlowByLocationOutcome ReidClient::describeCustomerFlowByLocation(const DescribeCustomerFlowByLocationRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeCustomerFlowByLocationOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeCustomerFlowByLocationOutcome(DescribeCustomerFlowByLocationResult(outcome.result()));
else
return DescribeCustomerFlowByLocationOutcome(outcome.error());
}
void ReidClient::describeCustomerFlowByLocationAsync(const DescribeCustomerFlowByLocationRequest& request, const DescribeCustomerFlowByLocationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeCustomerFlowByLocation(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::DescribeCustomerFlowByLocationOutcomeCallable ReidClient::describeCustomerFlowByLocationCallable(const DescribeCustomerFlowByLocationRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeCustomerFlowByLocationOutcome()>>(
[this, request]()
{
return this->describeCustomerFlowByLocation(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::DescribeHeatMapOutcome ReidClient::describeHeatMap(const DescribeHeatMapRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeHeatMapOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeHeatMapOutcome(DescribeHeatMapResult(outcome.result()));
else
return DescribeHeatMapOutcome(outcome.error());
}
void ReidClient::describeHeatMapAsync(const DescribeHeatMapRequest& request, const DescribeHeatMapAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeHeatMap(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::DescribeHeatMapOutcomeCallable ReidClient::describeHeatMapCallable(const DescribeHeatMapRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeHeatMapOutcome()>>(
[this, request]()
{
return this->describeHeatMap(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::DescribeImageUrlsOutcome ReidClient::describeImageUrls(const DescribeImageUrlsRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeImageUrlsOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeImageUrlsOutcome(DescribeImageUrlsResult(outcome.result()));
else
return DescribeImageUrlsOutcome(outcome.error());
}
void ReidClient::describeImageUrlsAsync(const DescribeImageUrlsRequest& request, const DescribeImageUrlsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeImageUrls(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::DescribeImageUrlsOutcomeCallable ReidClient::describeImageUrlsCallable(const DescribeImageUrlsRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeImageUrlsOutcome()>>(
[this, request]()
{
return this->describeImageUrls(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::DescribeOverviewDataOutcome ReidClient::describeOverviewData(const DescribeOverviewDataRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return DescribeOverviewDataOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return DescribeOverviewDataOutcome(DescribeOverviewDataResult(outcome.result()));
else
return DescribeOverviewDataOutcome(outcome.error());
}
void ReidClient::describeOverviewDataAsync(const DescribeOverviewDataRequest& request, const DescribeOverviewDataAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, describeOverviewData(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::DescribeOverviewDataOutcomeCallable ReidClient::describeOverviewDataCallable(const DescribeOverviewDataRequest &request) const
{
auto task = std::make_shared<std::packaged_task<DescribeOverviewDataOutcome()>>(
[this, request]()
{
return this->describeOverviewData(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::ImportSpecialPersonnelOutcome ReidClient::importSpecialPersonnel(const ImportSpecialPersonnelRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ImportSpecialPersonnelOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ImportSpecialPersonnelOutcome(ImportSpecialPersonnelResult(outcome.result()));
else
return ImportSpecialPersonnelOutcome(outcome.error());
}
void ReidClient::importSpecialPersonnelAsync(const ImportSpecialPersonnelRequest& request, const ImportSpecialPersonnelAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, importSpecialPersonnel(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::ImportSpecialPersonnelOutcomeCallable ReidClient::importSpecialPersonnelCallable(const ImportSpecialPersonnelRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ImportSpecialPersonnelOutcome()>>(
[this, request]()
{
return this->importSpecialPersonnel(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::ListActionDataOutcome ReidClient::listActionData(const ListActionDataRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListActionDataOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListActionDataOutcome(ListActionDataResult(outcome.result()));
else
return ListActionDataOutcome(outcome.error());
}
void ReidClient::listActionDataAsync(const ListActionDataRequest& request, const ListActionDataAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listActionData(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::ListActionDataOutcomeCallable ReidClient::listActionDataCallable(const ListActionDataRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListActionDataOutcome()>>(
[this, request]()
{
return this->listActionData(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::ListEmapOutcome ReidClient::listEmap(const ListEmapRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListEmapOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListEmapOutcome(ListEmapResult(outcome.result()));
else
return ListEmapOutcome(outcome.error());
}
void ReidClient::listEmapAsync(const ListEmapRequest& request, const ListEmapAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listEmap(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::ListEmapOutcomeCallable ReidClient::listEmapCallable(const ListEmapRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListEmapOutcome()>>(
[this, request]()
{
return this->listEmap(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::ListLocationOutcome ReidClient::listLocation(const ListLocationRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListLocationOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListLocationOutcome(ListLocationResult(outcome.result()));
else
return ListLocationOutcome(outcome.error());
}
void ReidClient::listLocationAsync(const ListLocationRequest& request, const ListLocationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listLocation(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::ListLocationOutcomeCallable ReidClient::listLocationCallable(const ListLocationRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListLocationOutcome()>>(
[this, request]()
{
return this->listLocation(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::ListPersonByImageOutcome ReidClient::listPersonByImage(const ListPersonByImageRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListPersonByImageOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListPersonByImageOutcome(ListPersonByImageResult(outcome.result()));
else
return ListPersonByImageOutcome(outcome.error());
}
void ReidClient::listPersonByImageAsync(const ListPersonByImageRequest& request, const ListPersonByImageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listPersonByImage(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::ListPersonByImageOutcomeCallable ReidClient::listPersonByImageCallable(const ListPersonByImageRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListPersonByImageOutcome()>>(
[this, request]()
{
return this->listPersonByImage(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::ListStoreOutcome ReidClient::listStore(const ListStoreRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return ListStoreOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return ListStoreOutcome(ListStoreResult(outcome.result()));
else
return ListStoreOutcome(outcome.error());
}
void ReidClient::listStoreAsync(const ListStoreRequest& request, const ListStoreAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, listStore(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::ListStoreOutcomeCallable ReidClient::listStoreCallable(const ListStoreRequest &request) const
{
auto task = std::make_shared<std::packaged_task<ListStoreOutcome()>>(
[this, request]()
{
return this->listStore(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}
ReidClient::PullActionDataOutcome ReidClient::pullActionData(const PullActionDataRequest &request) const
{
auto endpointOutcome = endpointProvider_->getEndpoint();
if (!endpointOutcome.isSuccess())
return PullActionDataOutcome(endpointOutcome.error());
auto outcome = makeRequest(endpointOutcome.result(), request);
if (outcome.isSuccess())
return PullActionDataOutcome(PullActionDataResult(outcome.result()));
else
return PullActionDataOutcome(outcome.error());
}
void ReidClient::pullActionDataAsync(const PullActionDataRequest& request, const PullActionDataAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
{
auto fn = [this, request, handler, context]()
{
handler(this, request, pullActionData(request), context);
};
asyncExecute(new Runnable(fn));
}
ReidClient::PullActionDataOutcomeCallable ReidClient::pullActionDataCallable(const PullActionDataRequest &request) const
{
auto task = std::make_shared<std::packaged_task<PullActionDataOutcome()>>(
[this, request]()
{
return this->pullActionData(request);
});
asyncExecute(new Runnable([task]() { (*task)(); }));
return task->get_future();
}

View File

@@ -0,0 +1,84 @@
/*
* 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/reid/model/DescribeBaseStatisticsRequest.h>
using AlibabaCloud::Reid::Model::DescribeBaseStatisticsRequest;
DescribeBaseStatisticsRequest::DescribeBaseStatisticsRequest() :
RpcServiceRequest("reid", "2019-09-28", "DescribeBaseStatistics")
{
setMethod(HttpRequest::Method::Post);
}
DescribeBaseStatisticsRequest::~DescribeBaseStatisticsRequest()
{}
std::string DescribeBaseStatisticsRequest::getDate()const
{
return date_;
}
void DescribeBaseStatisticsRequest::setDate(const std::string& date)
{
date_ = date;
setCoreParameter("Date", date);
}
std::string DescribeBaseStatisticsRequest::getExtraStatisticTypes()const
{
return extraStatisticTypes_;
}
void DescribeBaseStatisticsRequest::setExtraStatisticTypes(const std::string& extraStatisticTypes)
{
extraStatisticTypes_ = extraStatisticTypes;
setCoreParameter("ExtraStatisticTypes", extraStatisticTypes);
}
long DescribeBaseStatisticsRequest::getStoreId()const
{
return storeId_;
}
void DescribeBaseStatisticsRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
std::string DescribeBaseStatisticsRequest::getSummaryType()const
{
return summaryType_;
}
void DescribeBaseStatisticsRequest::setSummaryType(const std::string& summaryType)
{
summaryType_ = summaryType;
setCoreParameter("SummaryType", summaryType);
}
long DescribeBaseStatisticsRequest::getLocationId()const
{
return locationId_;
}
void DescribeBaseStatisticsRequest::setLocationId(long locationId)
{
locationId_ = locationId;
setCoreParameter("LocationId", std::to_string(locationId));
}

View File

@@ -0,0 +1,147 @@
/*
* 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/reid/model/DescribeBaseStatisticsResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
DescribeBaseStatisticsResult::DescribeBaseStatisticsResult() :
ServiceResult()
{}
DescribeBaseStatisticsResult::DescribeBaseStatisticsResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeBaseStatisticsResult::~DescribeBaseStatisticsResult()
{}
void DescribeBaseStatisticsResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allBaseStatisticsNode = value["BaseStatistics"]["BaseStatisticsItem"];
for (auto valueBaseStatisticsBaseStatisticsItem : allBaseStatisticsNode)
{
BaseStatisticsItem baseStatisticsObject;
if(!valueBaseStatisticsBaseStatisticsItem["StoreId"].isNull())
baseStatisticsObject.storeId = std::stol(valueBaseStatisticsBaseStatisticsItem["StoreId"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["FemaleUvCount"].isNull())
baseStatisticsObject.femaleUvCount = std::stoi(valueBaseStatisticsBaseStatisticsItem["FemaleUvCount"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["OldCount"].isNull())
baseStatisticsObject.oldCount = std::stoi(valueBaseStatisticsBaseStatisticsItem["OldCount"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["NewCount"].isNull())
baseStatisticsObject.newCount = std::stoi(valueBaseStatisticsBaseStatisticsItem["NewCount"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["SummaryType"].isNull())
baseStatisticsObject.summaryType = valueBaseStatisticsBaseStatisticsItem["SummaryType"].asString();
if(!valueBaseStatisticsBaseStatisticsItem["MaleUvCount"].isNull())
baseStatisticsObject.maleUvCount = std::stoi(valueBaseStatisticsBaseStatisticsItem["MaleUvCount"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["Time"].isNull())
baseStatisticsObject.time = valueBaseStatisticsBaseStatisticsItem["Time"].asString();
if(!valueBaseStatisticsBaseStatisticsItem["LocationId"].isNull())
baseStatisticsObject.locationId = std::stol(valueBaseStatisticsBaseStatisticsItem["LocationId"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["StayPeriod"].isNull())
baseStatisticsObject.stayPeriod = std::stol(valueBaseStatisticsBaseStatisticsItem["StayPeriod"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["UvCount"].isNull())
baseStatisticsObject.uvCount = std::stoi(valueBaseStatisticsBaseStatisticsItem["UvCount"].asString());
if(!valueBaseStatisticsBaseStatisticsItem["OnlyBodyUvCount"].isNull())
baseStatisticsObject.onlyBodyUvCount = std::stoi(valueBaseStatisticsBaseStatisticsItem["OnlyBodyUvCount"].asString());
auto allAgeItemsNode = allBaseStatisticsNode["AgeItems"]["AgeItem"];
for (auto allBaseStatisticsNodeAgeItemsAgeItem : allAgeItemsNode)
{
BaseStatisticsItem::AgeItem ageItemsObject;
if(!allBaseStatisticsNodeAgeItemsAgeItem["Name"].isNull())
ageItemsObject.name = allBaseStatisticsNodeAgeItemsAgeItem["Name"].asString();
if(!allBaseStatisticsNodeAgeItemsAgeItem["Count"].isNull())
ageItemsObject.count = std::stoi(allBaseStatisticsNodeAgeItemsAgeItem["Count"].asString());
baseStatisticsObject.ageItems.push_back(ageItemsObject);
}
auto allStayDistributionItemsNode = allBaseStatisticsNode["StayDistributionItems"]["StayDistributionItem"];
for (auto allBaseStatisticsNodeStayDistributionItemsStayDistributionItem : allStayDistributionItemsNode)
{
BaseStatisticsItem::StayDistributionItem stayDistributionItemsObject;
if(!allBaseStatisticsNodeStayDistributionItemsStayDistributionItem["StartTs"].isNull())
stayDistributionItemsObject.startTs = std::stol(allBaseStatisticsNodeStayDistributionItemsStayDistributionItem["StartTs"].asString());
if(!allBaseStatisticsNodeStayDistributionItemsStayDistributionItem["EndTs"].isNull())
stayDistributionItemsObject.endTs = std::stol(allBaseStatisticsNodeStayDistributionItemsStayDistributionItem["EndTs"].asString());
if(!allBaseStatisticsNodeStayDistributionItemsStayDistributionItem["Count"].isNull())
stayDistributionItemsObject.count = std::stoi(allBaseStatisticsNodeStayDistributionItemsStayDistributionItem["Count"].asString());
baseStatisticsObject.stayDistributionItems.push_back(stayDistributionItemsObject);
}
auto allMaleAgeItemsNode = allBaseStatisticsNode["MaleAgeItems"]["AgeItem"];
for (auto allBaseStatisticsNodeMaleAgeItemsAgeItem : allMaleAgeItemsNode)
{
BaseStatisticsItem::AgeItem maleAgeItemsObject;
if(!allBaseStatisticsNodeMaleAgeItemsAgeItem["Name"].isNull())
maleAgeItemsObject.name = allBaseStatisticsNodeMaleAgeItemsAgeItem["Name"].asString();
if(!allBaseStatisticsNodeMaleAgeItemsAgeItem["Count"].isNull())
maleAgeItemsObject.count = std::stoi(allBaseStatisticsNodeMaleAgeItemsAgeItem["Count"].asString());
baseStatisticsObject.maleAgeItems.push_back(maleAgeItemsObject);
}
auto allFemaleAgeItemsNode = allBaseStatisticsNode["FemaleAgeItems"]["AgeItem"];
for (auto allBaseStatisticsNodeFemaleAgeItemsAgeItem : allFemaleAgeItemsNode)
{
BaseStatisticsItem::AgeItem femaleAgeItemsObject;
if(!allBaseStatisticsNodeFemaleAgeItemsAgeItem["Name"].isNull())
femaleAgeItemsObject.name = allBaseStatisticsNodeFemaleAgeItemsAgeItem["Name"].asString();
if(!allBaseStatisticsNodeFemaleAgeItemsAgeItem["Count"].isNull())
femaleAgeItemsObject.count = std::stoi(allBaseStatisticsNodeFemaleAgeItemsAgeItem["Count"].asString());
baseStatisticsObject.femaleAgeItems.push_back(femaleAgeItemsObject);
}
baseStatistics_.push_back(baseStatisticsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["CursorTime"].isNull())
cursorTime_ = value["CursorTime"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::string DescribeBaseStatisticsResult::getCursorTime()const
{
return cursorTime_;
}
std::string DescribeBaseStatisticsResult::getErrorCode()const
{
return errorCode_;
}
std::string DescribeBaseStatisticsResult::getErrorMessage()const
{
return errorMessage_;
}
std::vector<DescribeBaseStatisticsResult::BaseStatisticsItem> DescribeBaseStatisticsResult::getBaseStatistics()const
{
return baseStatistics_;
}
bool DescribeBaseStatisticsResult::getSuccess()const
{
return success_;
}

View File

@@ -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.
*/
#include <alibabacloud/reid/model/DescribeCursorRequest.h>
using AlibabaCloud::Reid::Model::DescribeCursorRequest;
DescribeCursorRequest::DescribeCursorRequest() :
RpcServiceRequest("reid", "2019-09-28", "DescribeCursor")
{
setMethod(HttpRequest::Method::Post);
}
DescribeCursorRequest::~DescribeCursorRequest()
{}
long DescribeCursorRequest::getStoreId()const
{
return storeId_;
}
void DescribeCursorRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
std::string DescribeCursorRequest::getTime()const
{
return time_;
}
void DescribeCursorRequest::setTime(const std::string& time)
{
time_ = time;
setCoreParameter("Time", time);
}

View File

@@ -0,0 +1,72 @@
/*
* 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/reid/model/DescribeCursorResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
DescribeCursorResult::DescribeCursorResult() :
ServiceResult()
{}
DescribeCursorResult::DescribeCursorResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeCursorResult::~DescribeCursorResult()
{}
void DescribeCursorResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Cursor"].isNull())
cursor_ = value["Cursor"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::string DescribeCursorResult::getErrorCode()const
{
return errorCode_;
}
std::string DescribeCursorResult::getErrorMessage()const
{
return errorMessage_;
}
std::string DescribeCursorResult::getCursor()const
{
return cursor_;
}
bool DescribeCursorResult::getSuccess()const
{
return success_;
}

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/reid/model/DescribeCustomerFlowByLocationRequest.h>
using AlibabaCloud::Reid::Model::DescribeCustomerFlowByLocationRequest;
DescribeCustomerFlowByLocationRequest::DescribeCustomerFlowByLocationRequest() :
RpcServiceRequest("reid", "2019-09-28", "DescribeCustomerFlowByLocation")
{
setMethod(HttpRequest::Method::Post);
}
DescribeCustomerFlowByLocationRequest::~DescribeCustomerFlowByLocationRequest()
{}
std::string DescribeCustomerFlowByLocationRequest::getStartDate()const
{
return startDate_;
}
void DescribeCustomerFlowByLocationRequest::setStartDate(const std::string& startDate)
{
startDate_ = startDate;
setCoreParameter("StartDate", startDate);
}
long DescribeCustomerFlowByLocationRequest::getStoreId()const
{
return storeId_;
}
void DescribeCustomerFlowByLocationRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
long DescribeCustomerFlowByLocationRequest::getMinCount()const
{
return minCount_;
}
void DescribeCustomerFlowByLocationRequest::setMinCount(long minCount)
{
minCount_ = minCount;
setCoreParameter("MinCount", std::to_string(minCount));
}
long DescribeCustomerFlowByLocationRequest::getParentAmount()const
{
return parentAmount_;
}
void DescribeCustomerFlowByLocationRequest::setParentAmount(long parentAmount)
{
parentAmount_ = parentAmount;
setCoreParameter("ParentAmount", std::to_string(parentAmount));
}
long DescribeCustomerFlowByLocationRequest::getMaxCount()const
{
return maxCount_;
}
void DescribeCustomerFlowByLocationRequest::setMaxCount(long maxCount)
{
maxCount_ = maxCount;
setCoreParameter("MaxCount", std::to_string(maxCount));
}
std::string DescribeCustomerFlowByLocationRequest::getEndDate()const
{
return endDate_;
}
void DescribeCustomerFlowByLocationRequest::setEndDate(const std::string& endDate)
{
endDate_ = endDate;
setCoreParameter("EndDate", endDate);
}
long DescribeCustomerFlowByLocationRequest::getLocationId()const
{
return locationId_;
}
void DescribeCustomerFlowByLocationRequest::setLocationId(long locationId)
{
locationId_ = locationId;
setCoreParameter("LocationId", std::to_string(locationId));
}
std::string DescribeCustomerFlowByLocationRequest::getParentLocationIds()const
{
return parentLocationIds_;
}
void DescribeCustomerFlowByLocationRequest::setParentLocationIds(const std::string& parentLocationIds)
{
parentLocationIds_ = parentLocationIds;
setCoreParameter("ParentLocationIds", parentLocationIds);
}

View File

@@ -0,0 +1,130 @@
/*
* 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/reid/model/DescribeCustomerFlowByLocationResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
DescribeCustomerFlowByLocationResult::DescribeCustomerFlowByLocationResult() :
ServiceResult()
{}
DescribeCustomerFlowByLocationResult::DescribeCustomerFlowByLocationResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeCustomerFlowByLocationResult::~DescribeCustomerFlowByLocationResult()
{}
void DescribeCustomerFlowByLocationResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allCustomerFlowItemsNode = value["CustomerFlowItems"]["CustomerFlowItem"];
for (auto valueCustomerFlowItemsCustomerFlowItem : allCustomerFlowItemsNode)
{
CustomerFlowItem customerFlowItemsObject;
if(!valueCustomerFlowItemsCustomerFlowItem["Count"].isNull())
customerFlowItemsObject.count = std::stol(valueCustomerFlowItemsCustomerFlowItem["Count"].asString());
if(!valueCustomerFlowItemsCustomerFlowItem["StoreId"].isNull())
customerFlowItemsObject.storeId = std::stol(valueCustomerFlowItemsCustomerFlowItem["StoreId"].asString());
if(!valueCustomerFlowItemsCustomerFlowItem["Percent"].isNull())
customerFlowItemsObject.percent = std::stof(valueCustomerFlowItemsCustomerFlowItem["Percent"].asString());
if(!valueCustomerFlowItemsCustomerFlowItem["LocationName"].isNull())
customerFlowItemsObject.locationName = valueCustomerFlowItemsCustomerFlowItem["LocationName"].asString();
if(!valueCustomerFlowItemsCustomerFlowItem["ParentLocationIds"].isNull())
customerFlowItemsObject.parentLocationIds = valueCustomerFlowItemsCustomerFlowItem["ParentLocationIds"].asString();
if(!valueCustomerFlowItemsCustomerFlowItem["LocationId"].isNull())
customerFlowItemsObject.locationId = std::stol(valueCustomerFlowItemsCustomerFlowItem["LocationId"].asString());
customerFlowItems_.push_back(customerFlowItemsObject);
}
if(!value["LocationId"].isNull())
locationId_ = std::stol(value["LocationId"].asString());
if(!value["ParentLocationIds"].isNull())
parentLocationIds_ = value["ParentLocationIds"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["LocationName"].isNull())
locationName_ = value["LocationName"].asString();
if(!value["Percent"].isNull())
percent_ = std::stof(value["Percent"].asString());
if(!value["StoreId"].isNull())
storeId_ = std::stol(value["StoreId"].asString());
if(!value["Count"].isNull())
count_ = std::stol(value["Count"].asString());
}
std::vector<DescribeCustomerFlowByLocationResult::CustomerFlowItem> DescribeCustomerFlowByLocationResult::getCustomerFlowItems()const
{
return customerFlowItems_;
}
long DescribeCustomerFlowByLocationResult::getStoreId()const
{
return storeId_;
}
float DescribeCustomerFlowByLocationResult::getPercent()const
{
return percent_;
}
long DescribeCustomerFlowByLocationResult::getLocationId()const
{
return locationId_;
}
std::string DescribeCustomerFlowByLocationResult::getParentLocationIds()const
{
return parentLocationIds_;
}
std::string DescribeCustomerFlowByLocationResult::getErrorCode()const
{
return errorCode_;
}
long DescribeCustomerFlowByLocationResult::getCount()const
{
return count_;
}
std::string DescribeCustomerFlowByLocationResult::getErrorMessage()const
{
return errorMessage_;
}
bool DescribeCustomerFlowByLocationResult::getSuccess()const
{
return success_;
}
std::string DescribeCustomerFlowByLocationResult::getLocationName()const
{
return locationName_;
}

View File

@@ -0,0 +1,62 @@
/*
* 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/reid/model/DescribeHeatMapRequest.h>
using AlibabaCloud::Reid::Model::DescribeHeatMapRequest;
DescribeHeatMapRequest::DescribeHeatMapRequest() :
RpcServiceRequest("reid", "2019-09-28", "DescribeHeatMap")
{
setMethod(HttpRequest::Method::Post);
}
DescribeHeatMapRequest::~DescribeHeatMapRequest()
{}
std::string DescribeHeatMapRequest::getDate()const
{
return date_;
}
void DescribeHeatMapRequest::setDate(const std::string& date)
{
date_ = date;
setCoreParameter("Date", date);
}
long DescribeHeatMapRequest::getStoreId()const
{
return storeId_;
}
void DescribeHeatMapRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
long DescribeHeatMapRequest::getEmapId()const
{
return emapId_;
}
void DescribeHeatMapRequest::setEmapId(long emapId)
{
emapId_ = emapId;
setCoreParameter("EmapId", std::to_string(emapId));
}

View File

@@ -0,0 +1,82 @@
/*
* 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/reid/model/DescribeHeatMapResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
DescribeHeatMapResult::DescribeHeatMapResult() :
ServiceResult()
{}
DescribeHeatMapResult::DescribeHeatMapResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeHeatMapResult::~DescribeHeatMapResult()
{}
void DescribeHeatMapResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allHeatMapPointsNode = value["HeatMapPoints"]["HeatMapPoint"];
for (auto valueHeatMapPointsHeatMapPoint : allHeatMapPointsNode)
{
HeatMapPoint heatMapPointsObject;
if(!valueHeatMapPointsHeatMapPoint["Y"].isNull())
heatMapPointsObject.y = std::stof(valueHeatMapPointsHeatMapPoint["Y"].asString());
if(!valueHeatMapPointsHeatMapPoint["Weight"].isNull())
heatMapPointsObject.weight = std::stoi(valueHeatMapPointsHeatMapPoint["Weight"].asString());
if(!valueHeatMapPointsHeatMapPoint["X"].isNull())
heatMapPointsObject.x = std::stof(valueHeatMapPointsHeatMapPoint["X"].asString());
heatMapPoints_.push_back(heatMapPointsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::string DescribeHeatMapResult::getErrorCode()const
{
return errorCode_;
}
std::string DescribeHeatMapResult::getErrorMessage()const
{
return errorMessage_;
}
std::vector<DescribeHeatMapResult::HeatMapPoint> DescribeHeatMapResult::getHeatMapPoints()const
{
return heatMapPoints_;
}
bool DescribeHeatMapResult::getSuccess()const
{
return success_;
}

View File

@@ -0,0 +1,62 @@
/*
* 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/reid/model/DescribeImageUrlsRequest.h>
using AlibabaCloud::Reid::Model::DescribeImageUrlsRequest;
DescribeImageUrlsRequest::DescribeImageUrlsRequest() :
RpcServiceRequest("reid", "2019-09-28", "DescribeImageUrls")
{
setMethod(HttpRequest::Method::Post);
}
DescribeImageUrlsRequest::~DescribeImageUrlsRequest()
{}
std::string DescribeImageUrlsRequest::getOriginUrls()const
{
return originUrls_;
}
void DescribeImageUrlsRequest::setOriginUrls(const std::string& originUrls)
{
originUrls_ = originUrls;
setCoreParameter("OriginUrls", originUrls);
}
long DescribeImageUrlsRequest::getStoreId()const
{
return storeId_;
}
void DescribeImageUrlsRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
std::string DescribeImageUrlsRequest::getObjectKeys()const
{
return objectKeys_;
}
void DescribeImageUrlsRequest::setObjectKeys(const std::string& objectKeys)
{
objectKeys_ = objectKeys;
setCoreParameter("ObjectKeys", objectKeys);
}

View File

@@ -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.
*/
#include <alibabacloud/reid/model/DescribeImageUrlsResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
DescribeImageUrlsResult::DescribeImageUrlsResult() :
ServiceResult()
{}
DescribeImageUrlsResult::DescribeImageUrlsResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeImageUrlsResult::~DescribeImageUrlsResult()
{}
void DescribeImageUrlsResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allUrlsNode = value["Urls"]["ImageUrl"];
for (auto valueUrlsImageUrl : allUrlsNode)
{
ImageUrl urlsObject;
if(!valueUrlsImageUrl["ObjectKey"].isNull())
urlsObject.objectKey = valueUrlsImageUrl["ObjectKey"].asString();
if(!valueUrlsImageUrl["Url"].isNull())
urlsObject.url = valueUrlsImageUrl["Url"].asString();
urls_.push_back(urlsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::string DescribeImageUrlsResult::getErrorCode()const
{
return errorCode_;
}
std::vector<DescribeImageUrlsResult::ImageUrl> DescribeImageUrlsResult::getUrls()const
{
return urls_;
}
std::string DescribeImageUrlsResult::getErrorMessage()const
{
return errorMessage_;
}
bool DescribeImageUrlsResult::getSuccess()const
{
return success_;
}

View File

@@ -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.
*/
#include <alibabacloud/reid/model/DescribeOverviewDataRequest.h>
using AlibabaCloud::Reid::Model::DescribeOverviewDataRequest;
DescribeOverviewDataRequest::DescribeOverviewDataRequest() :
RpcServiceRequest("reid", "2019-09-28", "DescribeOverviewData")
{
setMethod(HttpRequest::Method::Post);
}
DescribeOverviewDataRequest::~DescribeOverviewDataRequest()
{}
std::string DescribeOverviewDataRequest::getDate()const
{
return date_;
}
void DescribeOverviewDataRequest::setDate(const std::string& date)
{
date_ = date;
setCoreParameter("Date", date);
}
std::string DescribeOverviewDataRequest::getStoreIds()const
{
return storeIds_;
}
void DescribeOverviewDataRequest::setStoreIds(const std::string& storeIds)
{
storeIds_ = storeIds;
setCoreParameter("StoreIds", storeIds);
}

View File

@@ -0,0 +1,91 @@
/*
* 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/reid/model/DescribeOverviewDataResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
DescribeOverviewDataResult::DescribeOverviewDataResult() :
ServiceResult()
{}
DescribeOverviewDataResult::DescribeOverviewDataResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
DescribeOverviewDataResult::~DescribeOverviewDataResult()
{}
void DescribeOverviewDataResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto overviewDetailNode = value["OverviewDetail"];
if(!overviewDetailNode["StayDeepAvgWOWPercent"].isNull())
overviewDetail_.stayDeepAvgWOWPercent = std::stof(overviewDetailNode["StayDeepAvgWOWPercent"].asString());
if(!overviewDetailNode["StayDeepAvg"].isNull())
overviewDetail_.stayDeepAvg = std::stof(overviewDetailNode["StayDeepAvg"].asString());
if(!overviewDetailNode["UvAvgWOWPercent"].isNull())
overviewDetail_.uvAvgWOWPercent = std::stof(overviewDetailNode["UvAvgWOWPercent"].asString());
if(!overviewDetailNode["StayAvgPeriodWOWPercent"].isNull())
overviewDetail_.stayAvgPeriodWOWPercent = std::stof(overviewDetailNode["StayAvgPeriodWOWPercent"].asString());
if(!overviewDetailNode["UvEverySqmGrowthWOWPercent"].isNull())
overviewDetail_.uvEverySqmGrowthWOWPercent = std::stof(overviewDetailNode["UvEverySqmGrowthWOWPercent"].asString());
if(!overviewDetailNode["UvWOWPercent"].isNull())
overviewDetail_.uvWOWPercent = std::stof(overviewDetailNode["UvWOWPercent"].asString());
if(!overviewDetailNode["Uv"].isNull())
overviewDetail_.uv = std::stol(overviewDetailNode["Uv"].asString());
if(!overviewDetailNode["UvEverySqm"].isNull())
overviewDetail_.uvEverySqm = std::stof(overviewDetailNode["UvEverySqm"].asString());
if(!overviewDetailNode["UvAvg"].isNull())
overviewDetail_.uvAvg = std::stof(overviewDetailNode["UvAvg"].asString());
if(!overviewDetailNode["StayAvgPeriod"].isNull())
overviewDetail_.stayAvgPeriod = std::stof(overviewDetailNode["StayAvgPeriod"].asString());
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
DescribeOverviewDataResult::OverviewDetail DescribeOverviewDataResult::getOverviewDetail()const
{
return overviewDetail_;
}
std::string DescribeOverviewDataResult::getErrorCode()const
{
return errorCode_;
}
std::string DescribeOverviewDataResult::getErrorMessage()const
{
return errorMessage_;
}
bool DescribeOverviewDataResult::getSuccess()const
{
return success_;
}

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/reid/model/ImportSpecialPersonnelRequest.h>
using AlibabaCloud::Reid::Model::ImportSpecialPersonnelRequest;
ImportSpecialPersonnelRequest::ImportSpecialPersonnelRequest() :
RpcServiceRequest("reid", "2019-09-28", "ImportSpecialPersonnel")
{
setMethod(HttpRequest::Method::Post);
}
ImportSpecialPersonnelRequest::~ImportSpecialPersonnelRequest()
{}
long ImportSpecialPersonnelRequest::getUkId()const
{
return ukId_;
}
void ImportSpecialPersonnelRequest::setUkId(long ukId)
{
ukId_ = ukId;
setCoreParameter("UkId", std::to_string(ukId));
}
std::string ImportSpecialPersonnelRequest::getDescription()const
{
return description_;
}
void ImportSpecialPersonnelRequest::setDescription(const std::string& description)
{
description_ = description;
setCoreParameter("Description", description);
}
std::string ImportSpecialPersonnelRequest::getExternalId()const
{
return externalId_;
}
void ImportSpecialPersonnelRequest::setExternalId(const std::string& externalId)
{
externalId_ = externalId;
setCoreParameter("ExternalId", externalId);
}
std::string ImportSpecialPersonnelRequest::getPersonType()const
{
return personType_;
}
void ImportSpecialPersonnelRequest::setPersonType(const std::string& personType)
{
personType_ = personType;
setCoreParameter("PersonType", personType);
}
std::string ImportSpecialPersonnelRequest::getUrls()const
{
return urls_;
}
void ImportSpecialPersonnelRequest::setUrls(const std::string& urls)
{
urls_ = urls;
setCoreParameter("Urls", urls);
}
std::string ImportSpecialPersonnelRequest::getPersonName()const
{
return personName_;
}
void ImportSpecialPersonnelRequest::setPersonName(const std::string& personName)
{
personName_ = personName;
setCoreParameter("PersonName", personName);
}
std::string ImportSpecialPersonnelRequest::getStoreIds()const
{
return storeIds_;
}
void ImportSpecialPersonnelRequest::setStoreIds(const std::string& storeIds)
{
storeIds_ = storeIds;
setCoreParameter("StoreIds", storeIds);
}
std::string ImportSpecialPersonnelRequest::getStatus()const
{
return status_;
}
void ImportSpecialPersonnelRequest::setStatus(const std::string& status)
{
status_ = status;
setCoreParameter("Status", status);
}

View File

@@ -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.
*/
#include <alibabacloud/reid/model/ImportSpecialPersonnelResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
ImportSpecialPersonnelResult::ImportSpecialPersonnelResult() :
ServiceResult()
{}
ImportSpecialPersonnelResult::ImportSpecialPersonnelResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ImportSpecialPersonnelResult::~ImportSpecialPersonnelResult()
{}
void ImportSpecialPersonnelResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allSpecialPersonnelMapsNode = value["SpecialPersonnelMaps"]["SpecialPersonnelMap"];
for (auto valueSpecialPersonnelMapsSpecialPersonnelMap : allSpecialPersonnelMapsNode)
{
SpecialPersonnelMap specialPersonnelMapsObject;
if(!valueSpecialPersonnelMapsSpecialPersonnelMap["UkId"].isNull())
specialPersonnelMapsObject.ukId = std::stol(valueSpecialPersonnelMapsSpecialPersonnelMap["UkId"].asString());
if(!valueSpecialPersonnelMapsSpecialPersonnelMap["StoreId"].isNull())
specialPersonnelMapsObject.storeId = std::stol(valueSpecialPersonnelMapsSpecialPersonnelMap["StoreId"].asString());
specialPersonnelMaps_.push_back(specialPersonnelMapsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::string ImportSpecialPersonnelResult::getErrorCode()const
{
return errorCode_;
}
std::string ImportSpecialPersonnelResult::getErrorMessage()const
{
return errorMessage_;
}
std::vector<ImportSpecialPersonnelResult::SpecialPersonnelMap> ImportSpecialPersonnelResult::getSpecialPersonnelMaps()const
{
return specialPersonnelMaps_;
}
bool ImportSpecialPersonnelResult::getSuccess()const
{
return success_;
}

View File

@@ -0,0 +1,95 @@
/*
* 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/reid/model/ListActionDataRequest.h>
using AlibabaCloud::Reid::Model::ListActionDataRequest;
ListActionDataRequest::ListActionDataRequest() :
RpcServiceRequest("reid", "2019-09-28", "ListActionData")
{
setMethod(HttpRequest::Method::Post);
}
ListActionDataRequest::~ListActionDataRequest()
{}
long ListActionDataRequest::getEndTime()const
{
return endTime_;
}
void ListActionDataRequest::setEndTime(long endTime)
{
endTime_ = endTime;
setCoreParameter("EndTime", std::to_string(endTime));
}
long ListActionDataRequest::getStartTime()const
{
return startTime_;
}
void ListActionDataRequest::setStartTime(long startTime)
{
startTime_ = startTime;
setCoreParameter("StartTime", std::to_string(startTime));
}
long ListActionDataRequest::getStoreId()const
{
return storeId_;
}
void ListActionDataRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
int ListActionDataRequest::getPageNumber()const
{
return pageNumber_;
}
void ListActionDataRequest::setPageNumber(int pageNumber)
{
pageNumber_ = pageNumber;
setCoreParameter("PageNumber", std::to_string(pageNumber));
}
int ListActionDataRequest::getPageSize()const
{
return pageSize_;
}
void ListActionDataRequest::setPageSize(int pageSize)
{
pageSize_ = pageSize;
setCoreParameter("PageSize", std::to_string(pageSize));
}
bool ListActionDataRequest::getFilterInvalidData()const
{
return filterInvalidData_;
}
void ListActionDataRequest::setFilterInvalidData(bool filterInvalidData)
{
filterInvalidData_ = filterInvalidData;
setCoreParameter("FilterInvalidData", filterInvalidData ? "true" : "false");
}

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/reid/model/ListActionDataResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
ListActionDataResult::ListActionDataResult() :
ServiceResult()
{}
ListActionDataResult::ListActionDataResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListActionDataResult::~ListActionDataResult()
{}
void ListActionDataResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allActionsNode = value["Actions"]["Action"];
for (auto valueActionsAction : allActionsNode)
{
Action actionsObject;
if(!valueActionsAction["StoreId"].isNull())
actionsObject.storeId = std::stol(valueActionsAction["StoreId"].asString());
if(!valueActionsAction["GmtCreate"].isNull())
actionsObject.gmtCreate = std::stol(valueActionsAction["GmtCreate"].asString());
if(!valueActionsAction["LeaveTimestamp"].isNull())
actionsObject.leaveTimestamp = std::stol(valueActionsAction["LeaveTimestamp"].asString());
if(!valueActionsAction["LocationLayerType"].isNull())
actionsObject.locationLayerType = valueActionsAction["LocationLayerType"].asString();
if(!valueActionsAction["StayValid"].isNull())
actionsObject.stayValid = valueActionsAction["StayValid"].asString() == "true";
if(!valueActionsAction["Gender"].isNull())
actionsObject.gender = valueActionsAction["Gender"].asString();
if(!valueActionsAction["UkId"].isNull())
actionsObject.ukId = std::stol(valueActionsAction["UkId"].asString());
if(!valueActionsAction["ArriveTimestamp"].isNull())
actionsObject.arriveTimestamp = std::stol(valueActionsAction["ArriveTimestamp"].asString());
if(!valueActionsAction["GmtModified"].isNull())
actionsObject.gmtModified = std::stol(valueActionsAction["GmtModified"].asString());
if(!valueActionsAction["ImageType"].isNull())
actionsObject.imageType = valueActionsAction["ImageType"].asString();
if(!valueActionsAction["InStay"].isNull())
actionsObject.inStay = std::stol(valueActionsAction["InStay"].asString());
if(!valueActionsAction["Status"].isNull())
actionsObject.status = std::stoi(valueActionsAction["Status"].asString());
if(!valueActionsAction["Age"].isNull())
actionsObject.age = std::stoi(valueActionsAction["Age"].asString());
if(!valueActionsAction["Id"].isNull())
actionsObject.id = std::stol(valueActionsAction["Id"].asString());
if(!valueActionsAction["ImageUrl"].isNull())
actionsObject.imageUrl = valueActionsAction["ImageUrl"].asString();
if(!valueActionsAction["LocationId"].isNull())
actionsObject.locationId = std::stol(valueActionsAction["LocationId"].asString());
if(!valueActionsAction["StayPeriod"].isNull())
actionsObject.stayPeriod = std::stoi(valueActionsAction["StayPeriod"].asString());
if(!valueActionsAction["Score"].isNull())
actionsObject.score = std::stof(valueActionsAction["Score"].asString());
if(!valueActionsAction["SpecialType"].isNull())
actionsObject.specialType = valueActionsAction["SpecialType"].asString();
if(!valueActionsAction["ImageObjectKey"].isNull())
actionsObject.imageObjectKey = valueActionsAction["ImageObjectKey"].asString();
if(!valueActionsAction["FacePointNumber"].isNull())
actionsObject.facePointNumber = std::stoi(valueActionsAction["FacePointNumber"].asString());
auto objectPositionInImageNode = value["ObjectPositionInImage"];
if(!objectPositionInImageNode["Bottom"].isNull())
actionsObject.objectPositionInImage.bottom = std::stof(objectPositionInImageNode["Bottom"].asString());
if(!objectPositionInImageNode["Left"].isNull())
actionsObject.objectPositionInImage.left = std::stof(objectPositionInImageNode["Left"].asString());
if(!objectPositionInImageNode["Top"].isNull())
actionsObject.objectPositionInImage.top = std::stof(objectPositionInImageNode["Top"].asString());
if(!objectPositionInImageNode["Right"].isNull())
actionsObject.objectPositionInImage.right = std::stof(objectPositionInImageNode["Right"].asString());
auto pointInMapNode = value["PointInMap"];
if(!pointInMapNode["X"].isNull())
actionsObject.pointInMap.x = std::stof(pointInMapNode["X"].asString());
if(!pointInMapNode["Y"].isNull())
actionsObject.pointInMap.y = std::stof(pointInMapNode["Y"].asString());
actions_.push_back(actionsObject);
}
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
if(!value["CursorTime"].isNull())
cursorTime_ = std::stol(value["CursorTime"].asString());
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["PageNumber"].isNull())
pageNumber_ = std::stoi(value["PageNumber"].asString());
if(!value["TotalCount"].isNull())
totalCount_ = std::stol(value["TotalCount"].asString());
if(!value["PageSize"].isNull())
pageSize_ = std::stoi(value["PageSize"].asString());
}
long ListActionDataResult::getTotalCount()const
{
return totalCount_;
}
int ListActionDataResult::getPageSize()const
{
return pageSize_;
}
std::vector<ListActionDataResult::Action> ListActionDataResult::getActions()const
{
return actions_;
}
int ListActionDataResult::getPageNumber()const
{
return pageNumber_;
}
long ListActionDataResult::getCursorTime()const
{
return cursorTime_;
}
std::string ListActionDataResult::getErrorCode()const
{
return errorCode_;
}
std::string ListActionDataResult::getErrorMessage()const
{
return errorMessage_;
}
bool ListActionDataResult::getSuccess()const
{
return success_;
}

View File

@@ -0,0 +1,40 @@
/*
* 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/reid/model/ListEmapRequest.h>
using AlibabaCloud::Reid::Model::ListEmapRequest;
ListEmapRequest::ListEmapRequest() :
RpcServiceRequest("reid", "2019-09-28", "ListEmap")
{
setMethod(HttpRequest::Method::Post);
}
ListEmapRequest::~ListEmapRequest()
{}
long ListEmapRequest::getStoreId()const
{
return storeId_;
}
void ListEmapRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}

View File

@@ -0,0 +1,84 @@
/*
* 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/reid/model/ListEmapResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
ListEmapResult::ListEmapResult() :
ServiceResult()
{}
ListEmapResult::ListEmapResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListEmapResult::~ListEmapResult()
{}
void ListEmapResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allOpenEmapsNode = value["OpenEmaps"]["OpenEmap"];
for (auto valueOpenEmapsOpenEmap : allOpenEmapsNode)
{
OpenEmap openEmapsObject;
if(!valueOpenEmapsOpenEmap["LocationId"].isNull())
openEmapsObject.locationId = valueOpenEmapsOpenEmap["LocationId"].asString();
if(!valueOpenEmapsOpenEmap["EmapId"].isNull())
openEmapsObject.emapId = valueOpenEmapsOpenEmap["EmapId"].asString();
if(!valueOpenEmapsOpenEmap["Name"].isNull())
openEmapsObject.name = valueOpenEmapsOpenEmap["Name"].asString();
if(!valueOpenEmapsOpenEmap["EmapUrl"].isNull())
openEmapsObject.emapUrl = valueOpenEmapsOpenEmap["EmapUrl"].asString();
openEmaps_.push_back(openEmapsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::vector<ListEmapResult::OpenEmap> ListEmapResult::getOpenEmaps()const
{
return openEmaps_;
}
std::string ListEmapResult::getErrorCode()const
{
return errorCode_;
}
std::string ListEmapResult::getErrorMessage()const
{
return errorMessage_;
}
bool ListEmapResult::getSuccess()const
{
return success_;
}

View File

@@ -0,0 +1,40 @@
/*
* 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/reid/model/ListLocationRequest.h>
using AlibabaCloud::Reid::Model::ListLocationRequest;
ListLocationRequest::ListLocationRequest() :
RpcServiceRequest("reid", "2019-09-28", "ListLocation")
{
setMethod(HttpRequest::Method::Post);
}
ListLocationRequest::~ListLocationRequest()
{}
long ListLocationRequest::getStoreId()const
{
return storeId_;
}
void ListLocationRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}

View File

@@ -0,0 +1,112 @@
/*
* 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/reid/model/ListLocationResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
ListLocationResult::ListLocationResult() :
ServiceResult()
{}
ListLocationResult::ListLocationResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListLocationResult::~ListLocationResult()
{}
void ListLocationResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allLocationInfoItemsNode = value["LocationInfoItems"]["LocationInfoItem"];
for (auto valueLocationInfoItemsLocationInfoItem : allLocationInfoItemsNode)
{
LocationInfoItem locationInfoItemsObject;
if(!valueLocationInfoItemsLocationInfoItem["ExternalId"].isNull())
locationInfoItemsObject.externalId = valueLocationInfoItemsLocationInfoItem["ExternalId"].asString();
if(!valueLocationInfoItemsLocationInfoItem["LocationType"].isNull())
locationInfoItemsObject.locationType = valueLocationInfoItemsLocationInfoItem["LocationType"].asString();
if(!valueLocationInfoItemsLocationInfoItem["Status"].isNull())
locationInfoItemsObject.status = std::stoi(valueLocationInfoItemsLocationInfoItem["Status"].asString());
if(!valueLocationInfoItemsLocationInfoItem["StoreId"].isNull())
locationInfoItemsObject.storeId = std::stol(valueLocationInfoItemsLocationInfoItem["StoreId"].asString());
if(!valueLocationInfoItemsLocationInfoItem["GmtCreate"].isNull())
locationInfoItemsObject.gmtCreate = std::stol(valueLocationInfoItemsLocationInfoItem["GmtCreate"].asString());
if(!valueLocationInfoItemsLocationInfoItem["ParentLocationId"].isNull())
locationInfoItemsObject.parentLocationId = std::stol(valueLocationInfoItemsLocationInfoItem["ParentLocationId"].asString());
if(!valueLocationInfoItemsLocationInfoItem["GmtModified"].isNull())
locationInfoItemsObject.gmtModified = std::stol(valueLocationInfoItemsLocationInfoItem["GmtModified"].asString());
if(!valueLocationInfoItemsLocationInfoItem["LocationName"].isNull())
locationInfoItemsObject.locationName = valueLocationInfoItemsLocationInfoItem["LocationName"].asString();
if(!valueLocationInfoItemsLocationInfoItem["LayerType"].isNull())
locationInfoItemsObject.layerType = valueLocationInfoItemsLocationInfoItem["LayerType"].asString();
if(!valueLocationInfoItemsLocationInfoItem["LocationId"].isNull())
locationInfoItemsObject.locationId = std::stol(valueLocationInfoItemsLocationInfoItem["LocationId"].asString());
auto allRectRoisNode = allLocationInfoItemsNode["RectRois"]["RectRoi"];
for (auto allLocationInfoItemsNodeRectRoisRectRoi : allRectRoisNode)
{
LocationInfoItem::RectRoi rectRoisObject;
auto allPointsNode = allRectRoisNode["Points"]["Point"];
for (auto allRectRoisNodePointsPoint : allPointsNode)
{
LocationInfoItem::RectRoi::Point pointsObject;
if(!allRectRoisNodePointsPoint["X"].isNull())
pointsObject.x = std::stof(allRectRoisNodePointsPoint["X"].asString());
if(!allRectRoisNodePointsPoint["Y"].isNull())
pointsObject.y = std::stof(allRectRoisNodePointsPoint["Y"].asString());
rectRoisObject.points.push_back(pointsObject);
}
locationInfoItemsObject.rectRois.push_back(rectRoisObject);
}
locationInfoItems_.push_back(locationInfoItemsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::vector<ListLocationResult::LocationInfoItem> ListLocationResult::getLocationInfoItems()const
{
return locationInfoItems_;
}
std::string ListLocationResult::getErrorCode()const
{
return errorCode_;
}
std::string ListLocationResult::getErrorMessage()const
{
return errorMessage_;
}
bool ListLocationResult::getSuccess()const
{
return success_;
}

View File

@@ -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.
*/
#include <alibabacloud/reid/model/ListPersonByImageRequest.h>
using AlibabaCloud::Reid::Model::ListPersonByImageRequest;
ListPersonByImageRequest::ListPersonByImageRequest() :
RpcServiceRequest("reid", "2019-09-28", "ListPersonByImage")
{
setMethod(HttpRequest::Method::Post);
}
ListPersonByImageRequest::~ListPersonByImageRequest()
{}
long ListPersonByImageRequest::getStoreId()const
{
return storeId_;
}
void ListPersonByImageRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
std::string ListPersonByImageRequest::getImageUrl()const
{
return imageUrl_;
}
void ListPersonByImageRequest::setImageUrl(const std::string& imageUrl)
{
imageUrl_ = imageUrl;
setCoreParameter("ImageUrl", imageUrl);
}

View File

@@ -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.
*/
#include <alibabacloud/reid/model/ListPersonByImageResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
ListPersonByImageResult::ListPersonByImageResult() :
ServiceResult()
{}
ListPersonByImageResult::ListPersonByImageResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListPersonByImageResult::~ListPersonByImageResult()
{}
void ListPersonByImageResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allPersonSearchResultItemsNode = value["PersonSearchResultItems"]["PersonSearchResultItem"];
for (auto valuePersonSearchResultItemsPersonSearchResultItem : allPersonSearchResultItemsNode)
{
PersonSearchResultItem personSearchResultItemsObject;
if(!valuePersonSearchResultItemsPersonSearchResultItem["UkId"].isNull())
personSearchResultItemsObject.ukId = std::stol(valuePersonSearchResultItemsPersonSearchResultItem["UkId"].asString());
if(!valuePersonSearchResultItemsPersonSearchResultItem["Score"].isNull())
personSearchResultItemsObject.score = std::stof(valuePersonSearchResultItemsPersonSearchResultItem["Score"].asString());
personSearchResultItems_.push_back(personSearchResultItemsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::vector<ListPersonByImageResult::PersonSearchResultItem> ListPersonByImageResult::getPersonSearchResultItems()const
{
return personSearchResultItems_;
}
std::string ListPersonByImageResult::getErrorCode()const
{
return errorCode_;
}
std::string ListPersonByImageResult::getErrorMessage()const
{
return errorMessage_;
}
bool ListPersonByImageResult::getSuccess()const
{
return success_;
}

View File

@@ -0,0 +1,29 @@
/*
* 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/reid/model/ListStoreRequest.h>
using AlibabaCloud::Reid::Model::ListStoreRequest;
ListStoreRequest::ListStoreRequest() :
RpcServiceRequest("reid", "2019-09-28", "ListStore")
{
setMethod(HttpRequest::Method::Post);
}
ListStoreRequest::~ListStoreRequest()
{}

View File

@@ -0,0 +1,96 @@
/*
* 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/reid/model/ListStoreResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
ListStoreResult::ListStoreResult() :
ServiceResult()
{}
ListStoreResult::ListStoreResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
ListStoreResult::~ListStoreResult()
{}
void ListStoreResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allStoresNode = value["Stores"]["OpenStore"];
for (auto valueStoresOpenStore : allStoresNode)
{
OpenStore storesObject;
if(!valueStoresOpenStore["StoreId"].isNull())
storesObject.storeId = std::stol(valueStoresOpenStore["StoreId"].asString());
if(!valueStoresOpenStore["GmtCreate"].isNull())
storesObject.gmtCreate = std::stol(valueStoresOpenStore["GmtCreate"].asString());
if(!valueStoresOpenStore["Sqm"].isNull())
storesObject.sqm = std::stof(valueStoresOpenStore["Sqm"].asString());
if(!valueStoresOpenStore["Status"].isNull())
storesObject.status = std::stoi(valueStoresOpenStore["Status"].asString());
if(!valueStoresOpenStore["Name"].isNull())
storesObject.name = valueStoresOpenStore["Name"].asString();
if(!valueStoresOpenStore["OpeningEndTime"].isNull())
storesObject.openingEndTime = valueStoresOpenStore["OpeningEndTime"].asString();
if(!valueStoresOpenStore["OpeningStartTime"].isNull())
storesObject.openingStartTime = valueStoresOpenStore["OpeningStartTime"].asString();
if(!valueStoresOpenStore["StoreType"].isNull())
storesObject.storeType = valueStoresOpenStore["StoreType"].asString();
if(!valueStoresOpenStore["GmtModified"].isNull())
storesObject.gmtModified = std::stol(valueStoresOpenStore["GmtModified"].asString());
if(!valueStoresOpenStore["Address"].isNull())
storesObject.address = valueStoresOpenStore["Address"].asString();
stores_.push_back(storesObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
}
std::vector<ListStoreResult::OpenStore> ListStoreResult::getStores()const
{
return stores_;
}
std::string ListStoreResult::getErrorCode()const
{
return errorCode_;
}
std::string ListStoreResult::getErrorMessage()const
{
return errorMessage_;
}
bool ListStoreResult::getSuccess()const
{
return success_;
}

View File

@@ -0,0 +1,73 @@
/*
* 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/reid/model/PullActionDataRequest.h>
using AlibabaCloud::Reid::Model::PullActionDataRequest;
PullActionDataRequest::PullActionDataRequest() :
RpcServiceRequest("reid", "2019-09-28", "PullActionData")
{
setMethod(HttpRequest::Method::Post);
}
PullActionDataRequest::~PullActionDataRequest()
{}
long PullActionDataRequest::getStoreId()const
{
return storeId_;
}
void PullActionDataRequest::setStoreId(long storeId)
{
storeId_ = storeId;
setCoreParameter("StoreId", std::to_string(storeId));
}
long PullActionDataRequest::getEndMessageId()const
{
return endMessageId_;
}
void PullActionDataRequest::setEndMessageId(long endMessageId)
{
endMessageId_ = endMessageId;
setCoreParameter("EndMessageId", std::to_string(endMessageId));
}
int PullActionDataRequest::getLimit()const
{
return limit_;
}
void PullActionDataRequest::setLimit(int limit)
{
limit_ = limit;
setCoreParameter("Limit", std::to_string(limit));
}
long PullActionDataRequest::getStartMessageId()const
{
return startMessageId_;
}
void PullActionDataRequest::setStartMessageId(long startMessageId)
{
startMessageId_ = startMessageId;
setCoreParameter("StartMessageId", std::to_string(startMessageId));
}

View File

@@ -0,0 +1,139 @@
/*
* 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/reid/model/PullActionDataResult.h>
#include <json/json.h>
using namespace AlibabaCloud::Reid;
using namespace AlibabaCloud::Reid::Model;
PullActionDataResult::PullActionDataResult() :
ServiceResult()
{}
PullActionDataResult::PullActionDataResult(const std::string &payload) :
ServiceResult()
{
parse(payload);
}
PullActionDataResult::~PullActionDataResult()
{}
void PullActionDataResult::parse(const std::string &payload)
{
Json::Reader reader;
Json::Value value;
reader.parse(payload, value);
setRequestId(value["RequestId"].asString());
auto allActionsNode = value["Actions"]["Action"];
for (auto valueActionsAction : allActionsNode)
{
Action actionsObject;
if(!valueActionsAction["StoreId"].isNull())
actionsObject.storeId = std::stol(valueActionsAction["StoreId"].asString());
if(!valueActionsAction["GmtCreate"].isNull())
actionsObject.gmtCreate = std::stol(valueActionsAction["GmtCreate"].asString());
if(!valueActionsAction["LeaveTimestamp"].isNull())
actionsObject.leaveTimestamp = std::stol(valueActionsAction["LeaveTimestamp"].asString());
if(!valueActionsAction["LocationLayerType"].isNull())
actionsObject.locationLayerType = valueActionsAction["LocationLayerType"].asString();
if(!valueActionsAction["StayValid"].isNull())
actionsObject.stayValid = valueActionsAction["StayValid"].asString() == "true";
if(!valueActionsAction["Gender"].isNull())
actionsObject.gender = valueActionsAction["Gender"].asString();
if(!valueActionsAction["UkId"].isNull())
actionsObject.ukId = std::stol(valueActionsAction["UkId"].asString());
if(!valueActionsAction["ArriveTimestamp"].isNull())
actionsObject.arriveTimestamp = std::stol(valueActionsAction["ArriveTimestamp"].asString());
if(!valueActionsAction["GmtModified"].isNull())
actionsObject.gmtModified = std::stol(valueActionsAction["GmtModified"].asString());
if(!valueActionsAction["ImageType"].isNull())
actionsObject.imageType = valueActionsAction["ImageType"].asString();
if(!valueActionsAction["InStay"].isNull())
actionsObject.inStay = std::stol(valueActionsAction["InStay"].asString());
if(!valueActionsAction["Status"].isNull())
actionsObject.status = std::stoi(valueActionsAction["Status"].asString());
if(!valueActionsAction["Age"].isNull())
actionsObject.age = std::stoi(valueActionsAction["Age"].asString());
if(!valueActionsAction["Id"].isNull())
actionsObject.id = std::stol(valueActionsAction["Id"].asString());
if(!valueActionsAction["ImageUrl"].isNull())
actionsObject.imageUrl = valueActionsAction["ImageUrl"].asString();
if(!valueActionsAction["LocationId"].isNull())
actionsObject.locationId = std::stol(valueActionsAction["LocationId"].asString());
if(!valueActionsAction["StayPeriod"].isNull())
actionsObject.stayPeriod = std::stoi(valueActionsAction["StayPeriod"].asString());
if(!valueActionsAction["Score"].isNull())
actionsObject.score = std::stof(valueActionsAction["Score"].asString());
if(!valueActionsAction["SpecialType"].isNull())
actionsObject.specialType = valueActionsAction["SpecialType"].asString();
if(!valueActionsAction["ImageObjectKey"].isNull())
actionsObject.imageObjectKey = valueActionsAction["ImageObjectKey"].asString();
if(!valueActionsAction["FacePointNumber"].isNull())
actionsObject.facePointNumber = std::stoi(valueActionsAction["FacePointNumber"].asString());
auto objectPositionInImageNode = value["ObjectPositionInImage"];
if(!objectPositionInImageNode["Bottom"].isNull())
actionsObject.objectPositionInImage.bottom = std::stof(objectPositionInImageNode["Bottom"].asString());
if(!objectPositionInImageNode["Left"].isNull())
actionsObject.objectPositionInImage.left = std::stof(objectPositionInImageNode["Left"].asString());
if(!objectPositionInImageNode["Top"].isNull())
actionsObject.objectPositionInImage.top = std::stof(objectPositionInImageNode["Top"].asString());
if(!objectPositionInImageNode["Right"].isNull())
actionsObject.objectPositionInImage.right = std::stof(objectPositionInImageNode["Right"].asString());
auto pointInMapNode = value["PointInMap"];
if(!pointInMapNode["X"].isNull())
actionsObject.pointInMap.x = std::stof(pointInMapNode["X"].asString());
if(!pointInMapNode["Y"].isNull())
actionsObject.pointInMap.y = std::stof(pointInMapNode["Y"].asString());
actions_.push_back(actionsObject);
}
if(!value["ErrorCode"].isNull())
errorCode_ = value["ErrorCode"].asString();
if(!value["ErrorMessage"].isNull())
errorMessage_ = value["ErrorMessage"].asString();
if(!value["Success"].isNull())
success_ = value["Success"].asString() == "true";
if(!value["NextMessageId"].isNull())
nextMessageId_ = std::stol(value["NextMessageId"].asString());
}
std::vector<PullActionDataResult::Action> PullActionDataResult::getActions()const
{
return actions_;
}
long PullActionDataResult::getNextMessageId()const
{
return nextMessageId_;
}
std::string PullActionDataResult::getErrorCode()const
{
return errorCode_;
}
std::string PullActionDataResult::getErrorMessage()const
{
return errorMessage_;
}
bool PullActionDataResult::getSuccess()const
{
return success_;
}