Add face quality detection API.
This commit is contained in:
@@ -29,6 +29,8 @@ set(vcs_public_header_model
|
||||
include/alibabacloud/vcs/model/CreateCorpResult.h
|
||||
include/alibabacloud/vcs/model/DeleteDeviceRequest.h
|
||||
include/alibabacloud/vcs/model/DeleteDeviceResult.h
|
||||
include/alibabacloud/vcs/model/DeleteRecordsRequest.h
|
||||
include/alibabacloud/vcs/model/DeleteRecordsResult.h
|
||||
include/alibabacloud/vcs/model/GetBodyOptionsRequest.h
|
||||
include/alibabacloud/vcs/model/GetBodyOptionsResult.h
|
||||
include/alibabacloud/vcs/model/GetDeviceLiveUrlRequest.h
|
||||
@@ -49,6 +51,8 @@ set(vcs_public_header_model
|
||||
include/alibabacloud/vcs/model/ListDevicesResult.h
|
||||
include/alibabacloud/vcs/model/ListPersonsRequest.h
|
||||
include/alibabacloud/vcs/model/ListPersonsResult.h
|
||||
include/alibabacloud/vcs/model/RecognizeFaceQualityRequest.h
|
||||
include/alibabacloud/vcs/model/RecognizeFaceQualityResult.h
|
||||
include/alibabacloud/vcs/model/RecognizeImageRequest.h
|
||||
include/alibabacloud/vcs/model/RecognizeImageResult.h
|
||||
include/alibabacloud/vcs/model/SearchBodyRequest.h
|
||||
@@ -74,6 +78,8 @@ set(vcs_src
|
||||
src/model/CreateCorpResult.cc
|
||||
src/model/DeleteDeviceRequest.cc
|
||||
src/model/DeleteDeviceResult.cc
|
||||
src/model/DeleteRecordsRequest.cc
|
||||
src/model/DeleteRecordsResult.cc
|
||||
src/model/GetBodyOptionsRequest.cc
|
||||
src/model/GetBodyOptionsResult.cc
|
||||
src/model/GetDeviceLiveUrlRequest.cc
|
||||
@@ -94,6 +100,8 @@ set(vcs_src
|
||||
src/model/ListDevicesResult.cc
|
||||
src/model/ListPersonsRequest.cc
|
||||
src/model/ListPersonsResult.cc
|
||||
src/model/RecognizeFaceQualityRequest.cc
|
||||
src/model/RecognizeFaceQualityResult.cc
|
||||
src/model/RecognizeImageRequest.cc
|
||||
src/model/RecognizeImageResult.cc
|
||||
src/model/SearchBodyRequest.cc
|
||||
|
||||
@@ -30,6 +30,8 @@
|
||||
#include "model/CreateCorpResult.h"
|
||||
#include "model/DeleteDeviceRequest.h"
|
||||
#include "model/DeleteDeviceResult.h"
|
||||
#include "model/DeleteRecordsRequest.h"
|
||||
#include "model/DeleteRecordsResult.h"
|
||||
#include "model/GetBodyOptionsRequest.h"
|
||||
#include "model/GetBodyOptionsResult.h"
|
||||
#include "model/GetDeviceLiveUrlRequest.h"
|
||||
@@ -50,6 +52,8 @@
|
||||
#include "model/ListDevicesResult.h"
|
||||
#include "model/ListPersonsRequest.h"
|
||||
#include "model/ListPersonsResult.h"
|
||||
#include "model/RecognizeFaceQualityRequest.h"
|
||||
#include "model/RecognizeFaceQualityResult.h"
|
||||
#include "model/RecognizeImageRequest.h"
|
||||
#include "model/RecognizeImageResult.h"
|
||||
#include "model/SearchBodyRequest.h"
|
||||
@@ -85,6 +89,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::DeleteDeviceResult> DeleteDeviceOutcome;
|
||||
typedef std::future<DeleteDeviceOutcome> DeleteDeviceOutcomeCallable;
|
||||
typedef std::function<void(const VcsClient*, const Model::DeleteDeviceRequest&, const DeleteDeviceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteDeviceAsyncHandler;
|
||||
typedef Outcome<Error, Model::DeleteRecordsResult> DeleteRecordsOutcome;
|
||||
typedef std::future<DeleteRecordsOutcome> DeleteRecordsOutcomeCallable;
|
||||
typedef std::function<void(const VcsClient*, const Model::DeleteRecordsRequest&, const DeleteRecordsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DeleteRecordsAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetBodyOptionsResult> GetBodyOptionsOutcome;
|
||||
typedef std::future<GetBodyOptionsOutcome> GetBodyOptionsOutcomeCallable;
|
||||
typedef std::function<void(const VcsClient*, const Model::GetBodyOptionsRequest&, const GetBodyOptionsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetBodyOptionsAsyncHandler;
|
||||
@@ -115,6 +122,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::ListPersonsResult> ListPersonsOutcome;
|
||||
typedef std::future<ListPersonsOutcome> ListPersonsOutcomeCallable;
|
||||
typedef std::function<void(const VcsClient*, const Model::ListPersonsRequest&, const ListPersonsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListPersonsAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeFaceQualityResult> RecognizeFaceQualityOutcome;
|
||||
typedef std::future<RecognizeFaceQualityOutcome> RecognizeFaceQualityOutcomeCallable;
|
||||
typedef std::function<void(const VcsClient*, const Model::RecognizeFaceQualityRequest&, const RecognizeFaceQualityOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeFaceQualityAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeImageResult> RecognizeImageOutcome;
|
||||
typedef std::future<RecognizeImageOutcome> RecognizeImageOutcomeCallable;
|
||||
typedef std::function<void(const VcsClient*, const Model::RecognizeImageRequest&, const RecognizeImageOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeImageAsyncHandler;
|
||||
@@ -153,6 +163,9 @@ namespace AlibabaCloud
|
||||
DeleteDeviceOutcome deleteDevice(const Model::DeleteDeviceRequest &request)const;
|
||||
void deleteDeviceAsync(const Model::DeleteDeviceRequest& request, const DeleteDeviceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DeleteDeviceOutcomeCallable deleteDeviceCallable(const Model::DeleteDeviceRequest& request) const;
|
||||
DeleteRecordsOutcome deleteRecords(const Model::DeleteRecordsRequest &request)const;
|
||||
void deleteRecordsAsync(const Model::DeleteRecordsRequest& request, const DeleteRecordsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DeleteRecordsOutcomeCallable deleteRecordsCallable(const Model::DeleteRecordsRequest& request) const;
|
||||
GetBodyOptionsOutcome getBodyOptions(const Model::GetBodyOptionsRequest &request)const;
|
||||
void getBodyOptionsAsync(const Model::GetBodyOptionsRequest& request, const GetBodyOptionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetBodyOptionsOutcomeCallable getBodyOptionsCallable(const Model::GetBodyOptionsRequest& request) const;
|
||||
@@ -183,6 +196,9 @@ namespace AlibabaCloud
|
||||
ListPersonsOutcome listPersons(const Model::ListPersonsRequest &request)const;
|
||||
void listPersonsAsync(const Model::ListPersonsRequest& request, const ListPersonsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListPersonsOutcomeCallable listPersonsCallable(const Model::ListPersonsRequest& request) const;
|
||||
RecognizeFaceQualityOutcome recognizeFaceQuality(const Model::RecognizeFaceQualityRequest &request)const;
|
||||
void recognizeFaceQualityAsync(const Model::RecognizeFaceQualityRequest& request, const RecognizeFaceQualityAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeFaceQualityOutcomeCallable recognizeFaceQualityCallable(const Model::RecognizeFaceQualityRequest& request) const;
|
||||
RecognizeImageOutcome recognizeImage(const Model::RecognizeImageRequest &request)const;
|
||||
void recognizeImageAsync(const Model::RecognizeImageRequest& request, const RecognizeImageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeImageOutcomeCallable recognizeImageCallable(const Model::RecognizeImageRequest& request) const;
|
||||
|
||||
60
vcs/include/alibabacloud/vcs/model/DeleteRecordsRequest.h
Normal file
60
vcs/include/alibabacloud/vcs/model/DeleteRecordsRequest.h
Normal file
@@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_VCS_MODEL_DELETERECORDSREQUEST_H_
|
||||
#define ALIBABACLOUD_VCS_MODEL_DELETERECORDSREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/vcs/VcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Vcs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_VCS_EXPORT DeleteRecordsRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
DeleteRecordsRequest();
|
||||
~DeleteRecordsRequest();
|
||||
|
||||
std::string getAlgorithmType()const;
|
||||
void setAlgorithmType(const std::string& algorithmType);
|
||||
std::string getCorpId()const;
|
||||
void setCorpId(const std::string& corpId);
|
||||
std::string getAttributeName()const;
|
||||
void setAttributeName(const std::string& attributeName);
|
||||
std::string getOperatorType()const;
|
||||
void setOperatorType(const std::string& operatorType);
|
||||
std::string getValue()const;
|
||||
void setValue(const std::string& value);
|
||||
|
||||
private:
|
||||
std::string algorithmType_;
|
||||
std::string corpId_;
|
||||
std::string attributeName_;
|
||||
std::string operatorType_;
|
||||
std::string value_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_VCS_MODEL_DELETERECORDSREQUEST_H_
|
||||
55
vcs/include/alibabacloud/vcs/model/DeleteRecordsResult.h
Normal file
55
vcs/include/alibabacloud/vcs/model/DeleteRecordsResult.h
Normal file
@@ -0,0 +1,55 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_VCS_MODEL_DELETERECORDSRESULT_H_
|
||||
#define ALIBABACLOUD_VCS_MODEL_DELETERECORDSRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/vcs/VcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Vcs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_VCS_EXPORT DeleteRecordsResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
|
||||
|
||||
DeleteRecordsResult();
|
||||
explicit DeleteRecordsResult(const std::string &payload);
|
||||
~DeleteRecordsResult();
|
||||
std::string getMessage()const;
|
||||
std::string getData()const;
|
||||
std::string getCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
std::string data_;
|
||||
std::string code_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_VCS_MODEL_DELETERECORDSRESULT_H_
|
||||
@@ -0,0 +1,54 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_VCS_MODEL_RECOGNIZEFACEQUALITYREQUEST_H_
|
||||
#define ALIBABACLOUD_VCS_MODEL_RECOGNIZEFACEQUALITYREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <alibabacloud/vcs/VcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Vcs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_VCS_EXPORT RecognizeFaceQualityRequest : public RpcServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
RecognizeFaceQualityRequest();
|
||||
~RecognizeFaceQualityRequest();
|
||||
|
||||
std::string getCorpId()const;
|
||||
void setCorpId(const std::string& corpId);
|
||||
std::string getPicContent()const;
|
||||
void setPicContent(const std::string& picContent);
|
||||
std::string getPicFormat()const;
|
||||
void setPicFormat(const std::string& picFormat);
|
||||
|
||||
private:
|
||||
std::string corpId_;
|
||||
std::string picContent_;
|
||||
std::string picFormat_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_VCS_MODEL_RECOGNIZEFACEQUALITYREQUEST_H_
|
||||
@@ -0,0 +1,60 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_VCS_MODEL_RECOGNIZEFACEQUALITYRESULT_H_
|
||||
#define ALIBABACLOUD_VCS_MODEL_RECOGNIZEFACEQUALITYRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/vcs/VcsExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Vcs
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_VCS_EXPORT RecognizeFaceQualityResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string description;
|
||||
std::string qualityScore;
|
||||
};
|
||||
|
||||
|
||||
RecognizeFaceQualityResult();
|
||||
explicit RecognizeFaceQualityResult(const std::string &payload);
|
||||
~RecognizeFaceQualityResult();
|
||||
std::string getMessage()const;
|
||||
Data getData()const;
|
||||
std::string getCode()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
std::string message_;
|
||||
Data data_;
|
||||
std::string code_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_VCS_MODEL_RECOGNIZEFACEQUALITYRESULT_H_
|
||||
@@ -195,6 +195,42 @@ VcsClient::DeleteDeviceOutcomeCallable VcsClient::deleteDeviceCallable(const Del
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
VcsClient::DeleteRecordsOutcome VcsClient::deleteRecords(const DeleteRecordsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DeleteRecordsOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DeleteRecordsOutcome(DeleteRecordsResult(outcome.result()));
|
||||
else
|
||||
return DeleteRecordsOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void VcsClient::deleteRecordsAsync(const DeleteRecordsRequest& request, const DeleteRecordsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, deleteRecords(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
VcsClient::DeleteRecordsOutcomeCallable VcsClient::deleteRecordsCallable(const DeleteRecordsRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DeleteRecordsOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->deleteRecords(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
VcsClient::GetBodyOptionsOutcome VcsClient::getBodyOptions(const GetBodyOptionsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -555,6 +591,42 @@ VcsClient::ListPersonsOutcomeCallable VcsClient::listPersonsCallable(const ListP
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
VcsClient::RecognizeFaceQualityOutcome VcsClient::recognizeFaceQuality(const RecognizeFaceQualityRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RecognizeFaceQualityOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RecognizeFaceQualityOutcome(RecognizeFaceQualityResult(outcome.result()));
|
||||
else
|
||||
return RecognizeFaceQualityOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void VcsClient::recognizeFaceQualityAsync(const RecognizeFaceQualityRequest& request, const RecognizeFaceQualityAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, recognizeFaceQuality(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
VcsClient::RecognizeFaceQualityOutcomeCallable VcsClient::recognizeFaceQualityCallable(const RecognizeFaceQualityRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RecognizeFaceQualityOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->recognizeFaceQuality(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
VcsClient::RecognizeImageOutcome VcsClient::recognizeImage(const RecognizeImageRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
84
vcs/src/model/DeleteRecordsRequest.cc
Normal file
84
vcs/src/model/DeleteRecordsRequest.cc
Normal 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/vcs/model/DeleteRecordsRequest.h>
|
||||
|
||||
using AlibabaCloud::Vcs::Model::DeleteRecordsRequest;
|
||||
|
||||
DeleteRecordsRequest::DeleteRecordsRequest() :
|
||||
RpcServiceRequest("vcs", "2020-05-15", "DeleteRecords")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DeleteRecordsRequest::~DeleteRecordsRequest()
|
||||
{}
|
||||
|
||||
std::string DeleteRecordsRequest::getAlgorithmType()const
|
||||
{
|
||||
return algorithmType_;
|
||||
}
|
||||
|
||||
void DeleteRecordsRequest::setAlgorithmType(const std::string& algorithmType)
|
||||
{
|
||||
algorithmType_ = algorithmType;
|
||||
setBodyParameter("AlgorithmType", algorithmType);
|
||||
}
|
||||
|
||||
std::string DeleteRecordsRequest::getCorpId()const
|
||||
{
|
||||
return corpId_;
|
||||
}
|
||||
|
||||
void DeleteRecordsRequest::setCorpId(const std::string& corpId)
|
||||
{
|
||||
corpId_ = corpId;
|
||||
setBodyParameter("CorpId", corpId);
|
||||
}
|
||||
|
||||
std::string DeleteRecordsRequest::getAttributeName()const
|
||||
{
|
||||
return attributeName_;
|
||||
}
|
||||
|
||||
void DeleteRecordsRequest::setAttributeName(const std::string& attributeName)
|
||||
{
|
||||
attributeName_ = attributeName;
|
||||
setBodyParameter("AttributeName", attributeName);
|
||||
}
|
||||
|
||||
std::string DeleteRecordsRequest::getOperatorType()const
|
||||
{
|
||||
return operatorType_;
|
||||
}
|
||||
|
||||
void DeleteRecordsRequest::setOperatorType(const std::string& operatorType)
|
||||
{
|
||||
operatorType_ = operatorType;
|
||||
setBodyParameter("OperatorType", operatorType);
|
||||
}
|
||||
|
||||
std::string DeleteRecordsRequest::getValue()const
|
||||
{
|
||||
return value_;
|
||||
}
|
||||
|
||||
void DeleteRecordsRequest::setValue(const std::string& value)
|
||||
{
|
||||
value_ = value;
|
||||
setBodyParameter("Value", value);
|
||||
}
|
||||
|
||||
65
vcs/src/model/DeleteRecordsResult.cc
Normal file
65
vcs/src/model/DeleteRecordsResult.cc
Normal file
@@ -0,0 +1,65 @@
|
||||
/*
|
||||
* 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/vcs/model/DeleteRecordsResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Vcs;
|
||||
using namespace AlibabaCloud::Vcs::Model;
|
||||
|
||||
DeleteRecordsResult::DeleteRecordsResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DeleteRecordsResult::DeleteRecordsResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DeleteRecordsResult::~DeleteRecordsResult()
|
||||
{}
|
||||
|
||||
void DeleteRecordsResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
if(!value["Data"].isNull())
|
||||
data_ = value["Data"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string DeleteRecordsResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
std::string DeleteRecordsResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string DeleteRecordsResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
62
vcs/src/model/RecognizeFaceQualityRequest.cc
Normal file
62
vcs/src/model/RecognizeFaceQualityRequest.cc
Normal 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/vcs/model/RecognizeFaceQualityRequest.h>
|
||||
|
||||
using AlibabaCloud::Vcs::Model::RecognizeFaceQualityRequest;
|
||||
|
||||
RecognizeFaceQualityRequest::RecognizeFaceQualityRequest() :
|
||||
RpcServiceRequest("vcs", "2020-05-15", "RecognizeFaceQuality")
|
||||
{
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RecognizeFaceQualityRequest::~RecognizeFaceQualityRequest()
|
||||
{}
|
||||
|
||||
std::string RecognizeFaceQualityRequest::getCorpId()const
|
||||
{
|
||||
return corpId_;
|
||||
}
|
||||
|
||||
void RecognizeFaceQualityRequest::setCorpId(const std::string& corpId)
|
||||
{
|
||||
corpId_ = corpId;
|
||||
setBodyParameter("CorpId", corpId);
|
||||
}
|
||||
|
||||
std::string RecognizeFaceQualityRequest::getPicContent()const
|
||||
{
|
||||
return picContent_;
|
||||
}
|
||||
|
||||
void RecognizeFaceQualityRequest::setPicContent(const std::string& picContent)
|
||||
{
|
||||
picContent_ = picContent;
|
||||
setBodyParameter("PicContent", picContent);
|
||||
}
|
||||
|
||||
std::string RecognizeFaceQualityRequest::getPicFormat()const
|
||||
{
|
||||
return picFormat_;
|
||||
}
|
||||
|
||||
void RecognizeFaceQualityRequest::setPicFormat(const std::string& picFormat)
|
||||
{
|
||||
picFormat_ = picFormat;
|
||||
setBodyParameter("PicFormat", picFormat);
|
||||
}
|
||||
|
||||
68
vcs/src/model/RecognizeFaceQualityResult.cc
Normal file
68
vcs/src/model/RecognizeFaceQualityResult.cc
Normal file
@@ -0,0 +1,68 @@
|
||||
/*
|
||||
* 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/vcs/model/RecognizeFaceQualityResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Vcs;
|
||||
using namespace AlibabaCloud::Vcs::Model;
|
||||
|
||||
RecognizeFaceQualityResult::RecognizeFaceQualityResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RecognizeFaceQualityResult::RecognizeFaceQualityResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RecognizeFaceQualityResult::~RecognizeFaceQualityResult()
|
||||
{}
|
||||
|
||||
void RecognizeFaceQualityResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
if(!dataNode["QualityScore"].isNull())
|
||||
data_.qualityScore = dataNode["QualityScore"].asString();
|
||||
if(!dataNode["Description"].isNull())
|
||||
data_.description = dataNode["Description"].asString();
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string RecognizeFaceQualityResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
RecognizeFaceQualityResult::Data RecognizeFaceQualityResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string RecognizeFaceQualityResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user