Add algorithm type for ListPerson.

This commit is contained in:
sdk-team
2020-07-21 14:09:08 +08:00
parent b64262402e
commit 6f44f27802
17 changed files with 131 additions and 16 deletions

View File

@@ -31,21 +31,21 @@ VcsClient::VcsClient(const Credentials &credentials, const ClientConfiguration &
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, "vcs");
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
}
VcsClient::VcsClient(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, "vcs");
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
}
VcsClient::VcsClient(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, "vcs");
endpointProvider_ = std::make_shared<EndpointProvider>(locationClient, configuration.regionId(), SERVICE_NAME, "");
}
VcsClient::~VcsClient()

View File

@@ -27,6 +27,17 @@ CreateCorpRequest::CreateCorpRequest() :
CreateCorpRequest::~CreateCorpRequest()
{}
std::string CreateCorpRequest::getAlgorithmType()const
{
return algorithmType_;
}
void CreateCorpRequest::setAlgorithmType(const std::string& algorithmType)
{
algorithmType_ = algorithmType;
setBodyParameter("AlgorithmType", algorithmType);
}
std::string CreateCorpRequest::getParentCorpId()const
{
return parentCorpId_;

View File

@@ -49,15 +49,15 @@ void CreateVideoSummaryTaskRequest::setLiveVideoSummary(const std::string& liveV
setBodyParameter("LiveVideoSummary", liveVideoSummary);
}
std::string CreateVideoSummaryTaskRequest::getStartTimeStamp()const
long CreateVideoSummaryTaskRequest::getStartTimeStamp()const
{
return startTimeStamp_;
}
void CreateVideoSummaryTaskRequest::setStartTimeStamp(const std::string& startTimeStamp)
void CreateVideoSummaryTaskRequest::setStartTimeStamp(long startTimeStamp)
{
startTimeStamp_ = startTimeStamp;
setBodyParameter("StartTimeStamp", startTimeStamp);
setBodyParameter("StartTimeStamp", std::to_string(startTimeStamp));
}
std::string CreateVideoSummaryTaskRequest::getDeviceId()const
@@ -71,15 +71,15 @@ void CreateVideoSummaryTaskRequest::setDeviceId(const std::string& deviceId)
setBodyParameter("DeviceId", deviceId);
}
std::string CreateVideoSummaryTaskRequest::getEndTimeStamp()const
long CreateVideoSummaryTaskRequest::getEndTimeStamp()const
{
return endTimeStamp_;
}
void CreateVideoSummaryTaskRequest::setEndTimeStamp(const std::string& endTimeStamp)
void CreateVideoSummaryTaskRequest::setEndTimeStamp(long endTimeStamp)
{
endTimeStamp_ = endTimeStamp;
setBodyParameter("EndTimeStamp", endTimeStamp);
setBodyParameter("EndTimeStamp", std::to_string(endTimeStamp));
}
std::string CreateVideoSummaryTaskRequest::getOptionList()const

View File

@@ -27,6 +27,17 @@ GetPersonDetailRequest::GetPersonDetailRequest() :
GetPersonDetailRequest::~GetPersonDetailRequest()
{}
std::string GetPersonDetailRequest::getAlgorithmType()const
{
return algorithmType_;
}
void GetPersonDetailRequest::setAlgorithmType(const std::string& algorithmType)
{
algorithmType_ = algorithmType;
setBodyParameter("AlgorithmType", algorithmType);
}
std::string GetPersonDetailRequest::getCorpId()const
{
return corpId_;

View File

@@ -82,6 +82,18 @@ void ListBodyAlgorithmResultsResult::parse(const std::string &payload)
recordsItemObject.shotTime = dataNodeRecordsRecordsItem["ShotTime"].asString();
if(!dataNodeRecordsRecordsItem["TargetPicUrlPath"].isNull())
recordsItemObject.targetPicUrlPath = dataNodeRecordsRecordsItem["TargetPicUrlPath"].asString();
if(!dataNodeRecordsRecordsItem["CoatLength"].isNull())
recordsItemObject.coatLength = dataNodeRecordsRecordsItem["CoatLength"].asString();
if(!dataNodeRecordsRecordsItem["CoatStyle"].isNull())
recordsItemObject.coatStyle = dataNodeRecordsRecordsItem["CoatStyle"].asString();
if(!dataNodeRecordsRecordsItem["TrousersLength"].isNull())
recordsItemObject.trousersLength = dataNodeRecordsRecordsItem["TrousersLength"].asString();
if(!dataNodeRecordsRecordsItem["TrousersStyle"].isNull())
recordsItemObject.trousersStyle = dataNodeRecordsRecordsItem["TrousersStyle"].asString();
if(!dataNodeRecordsRecordsItem["CoatColor"].isNull())
recordsItemObject.coatColor = dataNodeRecordsRecordsItem["CoatColor"].asString();
if(!dataNodeRecordsRecordsItem["TrousersColor"].isNull())
recordsItemObject.trousersColor = dataNodeRecordsRecordsItem["TrousersColor"].asString();
data_.records.push_back(recordsItemObject);
}
if(!value["Code"].isNull())

View File

@@ -68,6 +68,8 @@ void ListEventAlgorithmResultsResult::parse(const std::string &payload)
recordsItemObject.shotTime = dataNodeRecordsRecordsItem["ShotTime"].asString();
if(!dataNodeRecordsRecordsItem["TargetPicUrlPath"].isNull())
recordsItemObject.targetPicUrlPath = dataNodeRecordsRecordsItem["TargetPicUrlPath"].asString();
if(!dataNodeRecordsRecordsItem["RecordId"].isNull())
recordsItemObject.recordId = dataNodeRecordsRecordsItem["RecordId"].asString();
data_.records.push_back(recordsItemObject);
}
if(!value["Code"].isNull())

View File

@@ -78,6 +78,20 @@ void ListMotorAlgorithmResultsResult::parse(const std::string &payload)
recordsItemObject.motorStyle = dataNodeRecordsRecordsItem["MotorStyle"].asString();
if(!dataNodeRecordsRecordsItem["MotorModel"].isNull())
recordsItemObject.motorModel = dataNodeRecordsRecordsItem["MotorModel"].asString();
if(!dataNodeRecordsRecordsItem["MotorColor"].isNull())
recordsItemObject.motorColor = dataNodeRecordsRecordsItem["MotorColor"].asString();
if(!dataNodeRecordsRecordsItem["MotorClass"].isNull())
recordsItemObject.motorClass = dataNodeRecordsRecordsItem["MotorClass"].asString();
if(!dataNodeRecordsRecordsItem["MotorBrand"].isNull())
recordsItemObject.motorBrand = dataNodeRecordsRecordsItem["MotorBrand"].asString();
if(!dataNodeRecordsRecordsItem["PlateColor"].isNull())
recordsItemObject.plateColor = dataNodeRecordsRecordsItem["PlateColor"].asString();
if(!dataNodeRecordsRecordsItem["PlateClass"].isNull())
recordsItemObject.plateClass = dataNodeRecordsRecordsItem["PlateClass"].asString();
if(!dataNodeRecordsRecordsItem["SafetyBelt"].isNull())
recordsItemObject.safetyBelt = dataNodeRecordsRecordsItem["SafetyBelt"].asString();
if(!dataNodeRecordsRecordsItem["Calling"].isNull())
recordsItemObject.calling = dataNodeRecordsRecordsItem["Calling"].asString();
data_.records.push_back(recordsItemObject);
}
if(!value["Code"].isNull())

View File

@@ -27,6 +27,17 @@ ListPersonsRequest::ListPersonsRequest() :
ListPersonsRequest::~ListPersonsRequest()
{}
std::string ListPersonsRequest::getAlgorithmType()const
{
return algorithmType_;
}
void ListPersonsRequest::setAlgorithmType(const std::string& algorithmType)
{
algorithmType_ = algorithmType;
setBodyParameter("AlgorithmType", algorithmType);
}
std::string ListPersonsRequest::getCorpId()const
{
return corpId_;
@@ -38,6 +49,28 @@ void ListPersonsRequest::setCorpId(const std::string& corpId)
setBodyParameter("CorpId", corpId);
}
std::string ListPersonsRequest::getEndTime()const
{
return endTime_;
}
void ListPersonsRequest::setEndTime(const std::string& endTime)
{
endTime_ = endTime;
setBodyParameter("EndTime", endTime);
}
std::string ListPersonsRequest::getStartTime()const
{
return startTime_;
}
void ListPersonsRequest::setStartTime(const std::string& startTime)
{
startTime_ = startTime;
setBodyParameter("StartTime", startTime);
}
std::string ListPersonsRequest::getPageNo()const
{
return pageNo_;