Update TrimDocument.
This commit is contained in:
@@ -21,12 +21,8 @@ set(ocr_public_header
|
||||
include/alibabacloud/ocr/OcrExport.h )
|
||||
|
||||
set(ocr_public_header_model
|
||||
include/alibabacloud/ocr/model/DetectCardScreenshotRequest.h
|
||||
include/alibabacloud/ocr/model/DetectCardScreenshotResult.h
|
||||
include/alibabacloud/ocr/model/GetAsyncJobResultRequest.h
|
||||
include/alibabacloud/ocr/model/GetAsyncJobResultResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeAccountPageRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeAccountPageResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeBankCardRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeBankCardResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeBusinessCardRequest.h
|
||||
@@ -35,8 +31,6 @@ set(ocr_public_header_model
|
||||
include/alibabacloud/ocr/model/RecognizeBusinessLicenseResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeCharacterRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeCharacterResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeChinapassportRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeChinapassportResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeDriverLicenseRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeDriverLicenseResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeDrivingLicenseRequest.h
|
||||
@@ -45,12 +39,8 @@ set(ocr_public_header_model
|
||||
include/alibabacloud/ocr/model/RecognizeIdentityCardResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeLicensePlateRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeLicensePlateResult.h
|
||||
include/alibabacloud/ocr/model/RecognizePassportMRZRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizePassportMRZResult.h
|
||||
include/alibabacloud/ocr/model/RecognizePdfRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizePdfResult.h
|
||||
include/alibabacloud/ocr/model/RecognizePoiNameRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizePoiNameResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeQrCodeRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeQrCodeResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeQuotaInvoiceRequest.h
|
||||
@@ -59,8 +49,6 @@ set(ocr_public_header_model
|
||||
include/alibabacloud/ocr/model/RecognizeStampResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeTableRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeTableResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeTakeoutOrderRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeTakeoutOrderResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeTaxiInvoiceRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeTaxiInvoiceResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeTicketInvoiceRequest.h
|
||||
@@ -71,21 +59,13 @@ set(ocr_public_header_model
|
||||
include/alibabacloud/ocr/model/RecognizeVATInvoiceResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeVINCodeRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeVINCodeResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeVerificationcodeRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeVerificationcodeResult.h
|
||||
include/alibabacloud/ocr/model/RecognizeVideoCharacterRequest.h
|
||||
include/alibabacloud/ocr/model/RecognizeVideoCharacterResult.h
|
||||
include/alibabacloud/ocr/model/TrimDocumentRequest.h
|
||||
include/alibabacloud/ocr/model/TrimDocumentResult.h )
|
||||
include/alibabacloud/ocr/model/RecognizeVideoCharacterResult.h )
|
||||
|
||||
set(ocr_src
|
||||
src/OcrClient.cc
|
||||
src/model/DetectCardScreenshotRequest.cc
|
||||
src/model/DetectCardScreenshotResult.cc
|
||||
src/model/GetAsyncJobResultRequest.cc
|
||||
src/model/GetAsyncJobResultResult.cc
|
||||
src/model/RecognizeAccountPageRequest.cc
|
||||
src/model/RecognizeAccountPageResult.cc
|
||||
src/model/RecognizeBankCardRequest.cc
|
||||
src/model/RecognizeBankCardResult.cc
|
||||
src/model/RecognizeBusinessCardRequest.cc
|
||||
@@ -94,8 +74,6 @@ set(ocr_src
|
||||
src/model/RecognizeBusinessLicenseResult.cc
|
||||
src/model/RecognizeCharacterRequest.cc
|
||||
src/model/RecognizeCharacterResult.cc
|
||||
src/model/RecognizeChinapassportRequest.cc
|
||||
src/model/RecognizeChinapassportResult.cc
|
||||
src/model/RecognizeDriverLicenseRequest.cc
|
||||
src/model/RecognizeDriverLicenseResult.cc
|
||||
src/model/RecognizeDrivingLicenseRequest.cc
|
||||
@@ -104,12 +82,8 @@ set(ocr_src
|
||||
src/model/RecognizeIdentityCardResult.cc
|
||||
src/model/RecognizeLicensePlateRequest.cc
|
||||
src/model/RecognizeLicensePlateResult.cc
|
||||
src/model/RecognizePassportMRZRequest.cc
|
||||
src/model/RecognizePassportMRZResult.cc
|
||||
src/model/RecognizePdfRequest.cc
|
||||
src/model/RecognizePdfResult.cc
|
||||
src/model/RecognizePoiNameRequest.cc
|
||||
src/model/RecognizePoiNameResult.cc
|
||||
src/model/RecognizeQrCodeRequest.cc
|
||||
src/model/RecognizeQrCodeResult.cc
|
||||
src/model/RecognizeQuotaInvoiceRequest.cc
|
||||
@@ -118,8 +92,6 @@ set(ocr_src
|
||||
src/model/RecognizeStampResult.cc
|
||||
src/model/RecognizeTableRequest.cc
|
||||
src/model/RecognizeTableResult.cc
|
||||
src/model/RecognizeTakeoutOrderRequest.cc
|
||||
src/model/RecognizeTakeoutOrderResult.cc
|
||||
src/model/RecognizeTaxiInvoiceRequest.cc
|
||||
src/model/RecognizeTaxiInvoiceResult.cc
|
||||
src/model/RecognizeTicketInvoiceRequest.cc
|
||||
@@ -130,12 +102,8 @@ set(ocr_src
|
||||
src/model/RecognizeVATInvoiceResult.cc
|
||||
src/model/RecognizeVINCodeRequest.cc
|
||||
src/model/RecognizeVINCodeResult.cc
|
||||
src/model/RecognizeVerificationcodeRequest.cc
|
||||
src/model/RecognizeVerificationcodeResult.cc
|
||||
src/model/RecognizeVideoCharacterRequest.cc
|
||||
src/model/RecognizeVideoCharacterResult.cc
|
||||
src/model/TrimDocumentRequest.cc
|
||||
src/model/TrimDocumentResult.cc )
|
||||
src/model/RecognizeVideoCharacterResult.cc )
|
||||
|
||||
add_library(ocr ${LIB_TYPE}
|
||||
${ocr_public_header}
|
||||
|
||||
@@ -22,12 +22,8 @@
|
||||
#include <alibabacloud/core/EndpointProvider.h>
|
||||
#include <alibabacloud/core/RpcServiceClient.h>
|
||||
#include "OcrExport.h"
|
||||
#include "model/DetectCardScreenshotRequest.h"
|
||||
#include "model/DetectCardScreenshotResult.h"
|
||||
#include "model/GetAsyncJobResultRequest.h"
|
||||
#include "model/GetAsyncJobResultResult.h"
|
||||
#include "model/RecognizeAccountPageRequest.h"
|
||||
#include "model/RecognizeAccountPageResult.h"
|
||||
#include "model/RecognizeBankCardRequest.h"
|
||||
#include "model/RecognizeBankCardResult.h"
|
||||
#include "model/RecognizeBusinessCardRequest.h"
|
||||
@@ -36,8 +32,6 @@
|
||||
#include "model/RecognizeBusinessLicenseResult.h"
|
||||
#include "model/RecognizeCharacterRequest.h"
|
||||
#include "model/RecognizeCharacterResult.h"
|
||||
#include "model/RecognizeChinapassportRequest.h"
|
||||
#include "model/RecognizeChinapassportResult.h"
|
||||
#include "model/RecognizeDriverLicenseRequest.h"
|
||||
#include "model/RecognizeDriverLicenseResult.h"
|
||||
#include "model/RecognizeDrivingLicenseRequest.h"
|
||||
@@ -46,12 +40,8 @@
|
||||
#include "model/RecognizeIdentityCardResult.h"
|
||||
#include "model/RecognizeLicensePlateRequest.h"
|
||||
#include "model/RecognizeLicensePlateResult.h"
|
||||
#include "model/RecognizePassportMRZRequest.h"
|
||||
#include "model/RecognizePassportMRZResult.h"
|
||||
#include "model/RecognizePdfRequest.h"
|
||||
#include "model/RecognizePdfResult.h"
|
||||
#include "model/RecognizePoiNameRequest.h"
|
||||
#include "model/RecognizePoiNameResult.h"
|
||||
#include "model/RecognizeQrCodeRequest.h"
|
||||
#include "model/RecognizeQrCodeResult.h"
|
||||
#include "model/RecognizeQuotaInvoiceRequest.h"
|
||||
@@ -60,8 +50,6 @@
|
||||
#include "model/RecognizeStampResult.h"
|
||||
#include "model/RecognizeTableRequest.h"
|
||||
#include "model/RecognizeTableResult.h"
|
||||
#include "model/RecognizeTakeoutOrderRequest.h"
|
||||
#include "model/RecognizeTakeoutOrderResult.h"
|
||||
#include "model/RecognizeTaxiInvoiceRequest.h"
|
||||
#include "model/RecognizeTaxiInvoiceResult.h"
|
||||
#include "model/RecognizeTicketInvoiceRequest.h"
|
||||
@@ -72,12 +60,8 @@
|
||||
#include "model/RecognizeVATInvoiceResult.h"
|
||||
#include "model/RecognizeVINCodeRequest.h"
|
||||
#include "model/RecognizeVINCodeResult.h"
|
||||
#include "model/RecognizeVerificationcodeRequest.h"
|
||||
#include "model/RecognizeVerificationcodeResult.h"
|
||||
#include "model/RecognizeVideoCharacterRequest.h"
|
||||
#include "model/RecognizeVideoCharacterResult.h"
|
||||
#include "model/TrimDocumentRequest.h"
|
||||
#include "model/TrimDocumentResult.h"
|
||||
|
||||
|
||||
namespace AlibabaCloud
|
||||
@@ -87,15 +71,9 @@ namespace AlibabaCloud
|
||||
class ALIBABACLOUD_OCR_EXPORT OcrClient : public RpcServiceClient
|
||||
{
|
||||
public:
|
||||
typedef Outcome<Error, Model::DetectCardScreenshotResult> DetectCardScreenshotOutcome;
|
||||
typedef std::future<DetectCardScreenshotOutcome> DetectCardScreenshotOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::DetectCardScreenshotRequest&, const DetectCardScreenshotOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DetectCardScreenshotAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetAsyncJobResultResult> GetAsyncJobResultOutcome;
|
||||
typedef std::future<GetAsyncJobResultOutcome> GetAsyncJobResultOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::GetAsyncJobResultRequest&, const GetAsyncJobResultOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetAsyncJobResultAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeAccountPageResult> RecognizeAccountPageOutcome;
|
||||
typedef std::future<RecognizeAccountPageOutcome> RecognizeAccountPageOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeAccountPageRequest&, const RecognizeAccountPageOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeAccountPageAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeBankCardResult> RecognizeBankCardOutcome;
|
||||
typedef std::future<RecognizeBankCardOutcome> RecognizeBankCardOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeBankCardRequest&, const RecognizeBankCardOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeBankCardAsyncHandler;
|
||||
@@ -108,9 +86,6 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::RecognizeCharacterResult> RecognizeCharacterOutcome;
|
||||
typedef std::future<RecognizeCharacterOutcome> RecognizeCharacterOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeCharacterRequest&, const RecognizeCharacterOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeCharacterAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeChinapassportResult> RecognizeChinapassportOutcome;
|
||||
typedef std::future<RecognizeChinapassportOutcome> RecognizeChinapassportOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeChinapassportRequest&, const RecognizeChinapassportOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeChinapassportAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeDriverLicenseResult> RecognizeDriverLicenseOutcome;
|
||||
typedef std::future<RecognizeDriverLicenseOutcome> RecognizeDriverLicenseOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeDriverLicenseRequest&, const RecognizeDriverLicenseOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeDriverLicenseAsyncHandler;
|
||||
@@ -123,15 +98,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::RecognizeLicensePlateResult> RecognizeLicensePlateOutcome;
|
||||
typedef std::future<RecognizeLicensePlateOutcome> RecognizeLicensePlateOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeLicensePlateRequest&, const RecognizeLicensePlateOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeLicensePlateAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizePassportMRZResult> RecognizePassportMRZOutcome;
|
||||
typedef std::future<RecognizePassportMRZOutcome> RecognizePassportMRZOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizePassportMRZRequest&, const RecognizePassportMRZOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizePassportMRZAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizePdfResult> RecognizePdfOutcome;
|
||||
typedef std::future<RecognizePdfOutcome> RecognizePdfOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizePdfRequest&, const RecognizePdfOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizePdfAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizePoiNameResult> RecognizePoiNameOutcome;
|
||||
typedef std::future<RecognizePoiNameOutcome> RecognizePoiNameOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizePoiNameRequest&, const RecognizePoiNameOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizePoiNameAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeQrCodeResult> RecognizeQrCodeOutcome;
|
||||
typedef std::future<RecognizeQrCodeOutcome> RecognizeQrCodeOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeQrCodeRequest&, const RecognizeQrCodeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeQrCodeAsyncHandler;
|
||||
@@ -144,9 +113,6 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::RecognizeTableResult> RecognizeTableOutcome;
|
||||
typedef std::future<RecognizeTableOutcome> RecognizeTableOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeTableRequest&, const RecognizeTableOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeTableAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeTakeoutOrderResult> RecognizeTakeoutOrderOutcome;
|
||||
typedef std::future<RecognizeTakeoutOrderOutcome> RecognizeTakeoutOrderOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeTakeoutOrderRequest&, const RecognizeTakeoutOrderOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeTakeoutOrderAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeTaxiInvoiceResult> RecognizeTaxiInvoiceOutcome;
|
||||
typedef std::future<RecognizeTaxiInvoiceOutcome> RecognizeTaxiInvoiceOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeTaxiInvoiceRequest&, const RecognizeTaxiInvoiceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeTaxiInvoiceAsyncHandler;
|
||||
@@ -162,29 +128,17 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::RecognizeVINCodeResult> RecognizeVINCodeOutcome;
|
||||
typedef std::future<RecognizeVINCodeOutcome> RecognizeVINCodeOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeVINCodeRequest&, const RecognizeVINCodeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeVINCodeAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeVerificationcodeResult> RecognizeVerificationcodeOutcome;
|
||||
typedef std::future<RecognizeVerificationcodeOutcome> RecognizeVerificationcodeOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeVerificationcodeRequest&, const RecognizeVerificationcodeOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeVerificationcodeAsyncHandler;
|
||||
typedef Outcome<Error, Model::RecognizeVideoCharacterResult> RecognizeVideoCharacterOutcome;
|
||||
typedef std::future<RecognizeVideoCharacterOutcome> RecognizeVideoCharacterOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::RecognizeVideoCharacterRequest&, const RecognizeVideoCharacterOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> RecognizeVideoCharacterAsyncHandler;
|
||||
typedef Outcome<Error, Model::TrimDocumentResult> TrimDocumentOutcome;
|
||||
typedef std::future<TrimDocumentOutcome> TrimDocumentOutcomeCallable;
|
||||
typedef std::function<void(const OcrClient*, const Model::TrimDocumentRequest&, const TrimDocumentOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> TrimDocumentAsyncHandler;
|
||||
|
||||
OcrClient(const Credentials &credentials, const ClientConfiguration &configuration);
|
||||
OcrClient(const std::shared_ptr<CredentialsProvider> &credentialsProvider, const ClientConfiguration &configuration);
|
||||
OcrClient(const std::string &accessKeyId, const std::string &accessKeySecret, const ClientConfiguration &configuration);
|
||||
~OcrClient();
|
||||
DetectCardScreenshotOutcome detectCardScreenshot(const Model::DetectCardScreenshotRequest &request)const;
|
||||
void detectCardScreenshotAsync(const Model::DetectCardScreenshotRequest& request, const DetectCardScreenshotAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DetectCardScreenshotOutcomeCallable detectCardScreenshotCallable(const Model::DetectCardScreenshotRequest& request) const;
|
||||
GetAsyncJobResultOutcome getAsyncJobResult(const Model::GetAsyncJobResultRequest &request)const;
|
||||
void getAsyncJobResultAsync(const Model::GetAsyncJobResultRequest& request, const GetAsyncJobResultAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetAsyncJobResultOutcomeCallable getAsyncJobResultCallable(const Model::GetAsyncJobResultRequest& request) const;
|
||||
RecognizeAccountPageOutcome recognizeAccountPage(const Model::RecognizeAccountPageRequest &request)const;
|
||||
void recognizeAccountPageAsync(const Model::RecognizeAccountPageRequest& request, const RecognizeAccountPageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeAccountPageOutcomeCallable recognizeAccountPageCallable(const Model::RecognizeAccountPageRequest& request) const;
|
||||
RecognizeBankCardOutcome recognizeBankCard(const Model::RecognizeBankCardRequest &request)const;
|
||||
void recognizeBankCardAsync(const Model::RecognizeBankCardRequest& request, const RecognizeBankCardAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeBankCardOutcomeCallable recognizeBankCardCallable(const Model::RecognizeBankCardRequest& request) const;
|
||||
@@ -197,9 +151,6 @@ namespace AlibabaCloud
|
||||
RecognizeCharacterOutcome recognizeCharacter(const Model::RecognizeCharacterRequest &request)const;
|
||||
void recognizeCharacterAsync(const Model::RecognizeCharacterRequest& request, const RecognizeCharacterAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeCharacterOutcomeCallable recognizeCharacterCallable(const Model::RecognizeCharacterRequest& request) const;
|
||||
RecognizeChinapassportOutcome recognizeChinapassport(const Model::RecognizeChinapassportRequest &request)const;
|
||||
void recognizeChinapassportAsync(const Model::RecognizeChinapassportRequest& request, const RecognizeChinapassportAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeChinapassportOutcomeCallable recognizeChinapassportCallable(const Model::RecognizeChinapassportRequest& request) const;
|
||||
RecognizeDriverLicenseOutcome recognizeDriverLicense(const Model::RecognizeDriverLicenseRequest &request)const;
|
||||
void recognizeDriverLicenseAsync(const Model::RecognizeDriverLicenseRequest& request, const RecognizeDriverLicenseAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeDriverLicenseOutcomeCallable recognizeDriverLicenseCallable(const Model::RecognizeDriverLicenseRequest& request) const;
|
||||
@@ -212,15 +163,9 @@ namespace AlibabaCloud
|
||||
RecognizeLicensePlateOutcome recognizeLicensePlate(const Model::RecognizeLicensePlateRequest &request)const;
|
||||
void recognizeLicensePlateAsync(const Model::RecognizeLicensePlateRequest& request, const RecognizeLicensePlateAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeLicensePlateOutcomeCallable recognizeLicensePlateCallable(const Model::RecognizeLicensePlateRequest& request) const;
|
||||
RecognizePassportMRZOutcome recognizePassportMRZ(const Model::RecognizePassportMRZRequest &request)const;
|
||||
void recognizePassportMRZAsync(const Model::RecognizePassportMRZRequest& request, const RecognizePassportMRZAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizePassportMRZOutcomeCallable recognizePassportMRZCallable(const Model::RecognizePassportMRZRequest& request) const;
|
||||
RecognizePdfOutcome recognizePdf(const Model::RecognizePdfRequest &request)const;
|
||||
void recognizePdfAsync(const Model::RecognizePdfRequest& request, const RecognizePdfAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizePdfOutcomeCallable recognizePdfCallable(const Model::RecognizePdfRequest& request) const;
|
||||
RecognizePoiNameOutcome recognizePoiName(const Model::RecognizePoiNameRequest &request)const;
|
||||
void recognizePoiNameAsync(const Model::RecognizePoiNameRequest& request, const RecognizePoiNameAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizePoiNameOutcomeCallable recognizePoiNameCallable(const Model::RecognizePoiNameRequest& request) const;
|
||||
RecognizeQrCodeOutcome recognizeQrCode(const Model::RecognizeQrCodeRequest &request)const;
|
||||
void recognizeQrCodeAsync(const Model::RecognizeQrCodeRequest& request, const RecognizeQrCodeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeQrCodeOutcomeCallable recognizeQrCodeCallable(const Model::RecognizeQrCodeRequest& request) const;
|
||||
@@ -233,9 +178,6 @@ namespace AlibabaCloud
|
||||
RecognizeTableOutcome recognizeTable(const Model::RecognizeTableRequest &request)const;
|
||||
void recognizeTableAsync(const Model::RecognizeTableRequest& request, const RecognizeTableAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeTableOutcomeCallable recognizeTableCallable(const Model::RecognizeTableRequest& request) const;
|
||||
RecognizeTakeoutOrderOutcome recognizeTakeoutOrder(const Model::RecognizeTakeoutOrderRequest &request)const;
|
||||
void recognizeTakeoutOrderAsync(const Model::RecognizeTakeoutOrderRequest& request, const RecognizeTakeoutOrderAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeTakeoutOrderOutcomeCallable recognizeTakeoutOrderCallable(const Model::RecognizeTakeoutOrderRequest& request) const;
|
||||
RecognizeTaxiInvoiceOutcome recognizeTaxiInvoice(const Model::RecognizeTaxiInvoiceRequest &request)const;
|
||||
void recognizeTaxiInvoiceAsync(const Model::RecognizeTaxiInvoiceRequest& request, const RecognizeTaxiInvoiceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeTaxiInvoiceOutcomeCallable recognizeTaxiInvoiceCallable(const Model::RecognizeTaxiInvoiceRequest& request) const;
|
||||
@@ -251,15 +193,9 @@ namespace AlibabaCloud
|
||||
RecognizeVINCodeOutcome recognizeVINCode(const Model::RecognizeVINCodeRequest &request)const;
|
||||
void recognizeVINCodeAsync(const Model::RecognizeVINCodeRequest& request, const RecognizeVINCodeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeVINCodeOutcomeCallable recognizeVINCodeCallable(const Model::RecognizeVINCodeRequest& request) const;
|
||||
RecognizeVerificationcodeOutcome recognizeVerificationcode(const Model::RecognizeVerificationcodeRequest &request)const;
|
||||
void recognizeVerificationcodeAsync(const Model::RecognizeVerificationcodeRequest& request, const RecognizeVerificationcodeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeVerificationcodeOutcomeCallable recognizeVerificationcodeCallable(const Model::RecognizeVerificationcodeRequest& request) const;
|
||||
RecognizeVideoCharacterOutcome recognizeVideoCharacter(const Model::RecognizeVideoCharacterRequest &request)const;
|
||||
void recognizeVideoCharacterAsync(const Model::RecognizeVideoCharacterRequest& request, const RecognizeVideoCharacterAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
RecognizeVideoCharacterOutcomeCallable recognizeVideoCharacterCallable(const Model::RecognizeVideoCharacterRequest& request) const;
|
||||
TrimDocumentOutcome trimDocument(const Model::TrimDocumentRequest &request)const;
|
||||
void trimDocumentAsync(const Model::TrimDocumentRequest& request, const TrimDocumentAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
TrimDocumentOutcomeCallable trimDocumentCallable(const Model::TrimDocumentRequest& request) const;
|
||||
|
||||
private:
|
||||
std::shared_ptr<EndpointProvider> endpointProvider_;
|
||||
|
||||
@@ -1,42 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_DETECTCARDSCREENSHOTREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_DETECTCARDSCREENSHOTREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT DetectCardScreenshotRequest : public RpcServiceRequest {
|
||||
public:
|
||||
DetectCardScreenshotRequest();
|
||||
~DetectCardScreenshotRequest();
|
||||
std::string getImageURL() const;
|
||||
void setImageURL(const std::string &imageURL);
|
||||
|
||||
private:
|
||||
std::string imageURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_DETECTCARDSCREENSHOTREQUEST_H_
|
||||
@@ -1,67 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_DETECTCARDSCREENSHOTRESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_DETECTCARDSCREENSHOTRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT DetectCardScreenshotResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
struct SpoofResult
|
||||
{
|
||||
struct ResultMap
|
||||
{
|
||||
float screenScore;
|
||||
float screenThreshold;
|
||||
};
|
||||
ResultMap resultMap;
|
||||
bool isSpoof;
|
||||
};
|
||||
SpoofResult spoofResult;
|
||||
bool isBlur;
|
||||
bool isCard;
|
||||
};
|
||||
|
||||
|
||||
DetectCardScreenshotResult();
|
||||
explicit DetectCardScreenshotResult(const std::string &payload);
|
||||
~DetectCardScreenshotResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_DETECTCARDSCREENSHOTRESULT_H_
|
||||
@@ -1,45 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEACCOUNTPAGEREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEACCOUNTPAGEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeAccountPageRequest : public RpcServiceRequest {
|
||||
public:
|
||||
RecognizeAccountPageRequest();
|
||||
~RecognizeAccountPageRequest();
|
||||
int getImageType() const;
|
||||
void setImageType(int imageType);
|
||||
std::string getImageURL() const;
|
||||
void setImageURL(const std::string &imageURL);
|
||||
|
||||
private:
|
||||
int imageType_;
|
||||
std::string imageURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEACCOUNTPAGEREQUEST_H_
|
||||
@@ -1,103 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEACCOUNTPAGERESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEACCOUNTPAGERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeAccountPageResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
struct TitleArea
|
||||
{
|
||||
int left;
|
||||
int top;
|
||||
int height;
|
||||
int width;
|
||||
};
|
||||
struct RegisterStampArea
|
||||
{
|
||||
int left;
|
||||
int top;
|
||||
int height;
|
||||
int width;
|
||||
};
|
||||
struct OtherStampArea
|
||||
{
|
||||
int left;
|
||||
int top;
|
||||
int height;
|
||||
int width;
|
||||
};
|
||||
struct UndertakeStampArea
|
||||
{
|
||||
int left;
|
||||
int top;
|
||||
int height;
|
||||
int width;
|
||||
};
|
||||
struct InvalidStampArea
|
||||
{
|
||||
int left;
|
||||
int top;
|
||||
int height;
|
||||
int width;
|
||||
};
|
||||
std::string nativePlace;
|
||||
std::vector<OtherStampArea> otherStampAreas;
|
||||
std::string birthPlace;
|
||||
std::vector<RegisterStampArea> registerStampAreas;
|
||||
std::string gender;
|
||||
std::vector<InvalidStampArea> invalidStampAreas;
|
||||
std::string nationality;
|
||||
std::string name;
|
||||
std::vector<UndertakeStampArea> undertakeStampAreas;
|
||||
std::string relation;
|
||||
float angle;
|
||||
TitleArea titleArea;
|
||||
std::string birthDate;
|
||||
std::string iDNumber;
|
||||
};
|
||||
|
||||
|
||||
RecognizeAccountPageResult();
|
||||
explicit RecognizeAccountPageResult(const std::string &payload);
|
||||
~RecognizeAccountPageResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEACCOUNTPAGERESULT_H_
|
||||
@@ -1,42 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZECHINAPASSPORTREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZECHINAPASSPORTREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeChinapassportRequest : public RpcServiceRequest {
|
||||
public:
|
||||
RecognizeChinapassportRequest();
|
||||
~RecognizeChinapassportRequest();
|
||||
std::string getImageURL() const;
|
||||
void setImageURL(const std::string &imageURL);
|
||||
|
||||
private:
|
||||
std::string imageURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZECHINAPASSPORTREQUEST_H_
|
||||
@@ -1,76 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZECHINAPASSPORTRESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZECHINAPASSPORTRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeChinapassportResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string expiryDate;
|
||||
std::string sourceCountry;
|
||||
std::string birthPlace;
|
||||
std::string issuePlaceRaw;
|
||||
std::string nameChineseRaw;
|
||||
std::string authority;
|
||||
std::string sex;
|
||||
std::string issueDate;
|
||||
std::string lineZero;
|
||||
std::string birthDay;
|
||||
std::string issuePlace;
|
||||
std::string expiryDay;
|
||||
bool success;
|
||||
std::string name;
|
||||
std::string lineOne;
|
||||
std::string type;
|
||||
std::string nameChinese;
|
||||
std::string personId;
|
||||
std::string passportNo;
|
||||
std::string birthPlaceRaw;
|
||||
std::string country;
|
||||
std::string birthDate;
|
||||
};
|
||||
|
||||
|
||||
RecognizeChinapassportResult();
|
||||
explicit RecognizeChinapassportResult(const std::string &payload);
|
||||
~RecognizeChinapassportResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZECHINAPASSPORTRESULT_H_
|
||||
@@ -1,42 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEPASSPORTMRZREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEPASSPORTMRZREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizePassportMRZRequest : public RpcServiceRequest {
|
||||
public:
|
||||
RecognizePassportMRZRequest();
|
||||
~RecognizePassportMRZRequest();
|
||||
std::string getImageURL() const;
|
||||
void setImageURL(const std::string &imageURL);
|
||||
|
||||
private:
|
||||
std::string imageURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEPASSPORTMRZREQUEST_H_
|
||||
@@ -1,63 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEPASSPORTMRZRESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEPASSPORTMRZRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizePassportMRZResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
struct Region
|
||||
{
|
||||
std::string content;
|
||||
float recognitionScore;
|
||||
std::vector<std::string> bandBoxes;
|
||||
float detectionScore;
|
||||
std::string name;
|
||||
};
|
||||
std::vector<Region> regions;
|
||||
};
|
||||
|
||||
|
||||
RecognizePassportMRZResult();
|
||||
explicit RecognizePassportMRZResult(const std::string &payload);
|
||||
~RecognizePassportMRZResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEPASSPORTMRZRESULT_H_
|
||||
@@ -1,42 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEPOINAMEREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEPOINAMEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizePoiNameRequest : public RpcServiceRequest {
|
||||
public:
|
||||
RecognizePoiNameRequest();
|
||||
~RecognizePoiNameRequest();
|
||||
std::string getImageURL() const;
|
||||
void setImageURL(const std::string &imageURL);
|
||||
|
||||
private:
|
||||
std::string imageURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEPOINAMEREQUEST_H_
|
||||
@@ -1,73 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEPOINAMERESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEPOINAMERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizePoiNameResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
struct Summary
|
||||
{
|
||||
std::string brand;
|
||||
float score;
|
||||
};
|
||||
struct SignboardsItem
|
||||
{
|
||||
struct TextsItem
|
||||
{
|
||||
std::string type;
|
||||
float score;
|
||||
std::vector<std::string> points;
|
||||
std::string label;
|
||||
std::string tag;
|
||||
};
|
||||
std::vector<SignboardsItem::TextsItem> texts;
|
||||
};
|
||||
std::vector<SignboardsItem> signboards;
|
||||
Summary summary;
|
||||
};
|
||||
|
||||
|
||||
RecognizePoiNameResult();
|
||||
explicit RecognizePoiNameResult(const std::string &payload);
|
||||
~RecognizePoiNameResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEPOINAMERESULT_H_
|
||||
@@ -1,42 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZETAKEOUTORDERREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZETAKEOUTORDERREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeTakeoutOrderRequest : public RpcServiceRequest {
|
||||
public:
|
||||
RecognizeTakeoutOrderRequest();
|
||||
~RecognizeTakeoutOrderRequest();
|
||||
std::string getImageURL() const;
|
||||
void setImageURL(const std::string &imageURL);
|
||||
|
||||
private:
|
||||
std::string imageURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZETAKEOUTORDERREQUEST_H_
|
||||
@@ -1,62 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZETAKEOUTORDERRESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZETAKEOUTORDERRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeTakeoutOrderResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
struct Element
|
||||
{
|
||||
float score;
|
||||
std::string value;
|
||||
std::string name;
|
||||
std::vector<std::string> boxes;
|
||||
};
|
||||
std::vector<Element> elements;
|
||||
};
|
||||
|
||||
|
||||
RecognizeTakeoutOrderResult();
|
||||
explicit RecognizeTakeoutOrderResult(const std::string &payload);
|
||||
~RecognizeTakeoutOrderResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZETAKEOUTORDERRESULT_H_
|
||||
@@ -1,42 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEVERIFICATIONCODEREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEVERIFICATIONCODEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeVerificationcodeRequest : public RpcServiceRequest {
|
||||
public:
|
||||
RecognizeVerificationcodeRequest();
|
||||
~RecognizeVerificationcodeRequest();
|
||||
std::string getImageURL() const;
|
||||
void setImageURL(const std::string &imageURL);
|
||||
|
||||
private:
|
||||
std::string imageURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEVERIFICATIONCODEREQUEST_H_
|
||||
@@ -1,55 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_RECOGNIZEVERIFICATIONCODERESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_RECOGNIZEVERIFICATIONCODERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT RecognizeVerificationcodeResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string content;
|
||||
};
|
||||
|
||||
|
||||
RecognizeVerificationcodeResult();
|
||||
explicit RecognizeVerificationcodeResult(const std::string &payload);
|
||||
~RecognizeVerificationcodeResult();
|
||||
Data getData()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Data data_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_RECOGNIZEVERIFICATIONCODERESULT_H_
|
||||
@@ -1,51 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_TRIMDOCUMENTREQUEST_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_TRIMDOCUMENTREQUEST_H_
|
||||
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Ocr {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_OCR_EXPORT TrimDocumentRequest : public RpcServiceRequest {
|
||||
public:
|
||||
TrimDocumentRequest();
|
||||
~TrimDocumentRequest();
|
||||
std::string getFileType() const;
|
||||
void setFileType(const std::string &fileType);
|
||||
std::string getOutputType() const;
|
||||
void setOutputType(const std::string &outputType);
|
||||
bool getAsync() const;
|
||||
void setAsync(bool async);
|
||||
std::string getFileURL() const;
|
||||
void setFileURL(const std::string &fileURL);
|
||||
|
||||
private:
|
||||
std::string fileType_;
|
||||
std::string outputType_;
|
||||
bool async_;
|
||||
std::string fileURL_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Ocr
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_OCR_MODEL_TRIMDOCUMENTREQUEST_H_
|
||||
@@ -1,59 +0,0 @@
|
||||
/*
|
||||
* 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_OCR_MODEL_TRIMDOCUMENTRESULT_H_
|
||||
#define ALIBABACLOUD_OCR_MODEL_TRIMDOCUMENTRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/ocr/OcrExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Ocr
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_OCR_EXPORT TrimDocumentResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
std::string content;
|
||||
};
|
||||
|
||||
|
||||
TrimDocumentResult();
|
||||
explicit TrimDocumentResult(const std::string &payload);
|
||||
~TrimDocumentResult();
|
||||
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_OCR_MODEL_TRIMDOCUMENTRESULT_H_
|
||||
@@ -51,42 +51,6 @@ OcrClient::OcrClient(const std::string & accessKeyId, const std::string & access
|
||||
OcrClient::~OcrClient()
|
||||
{}
|
||||
|
||||
OcrClient::DetectCardScreenshotOutcome OcrClient::detectCardScreenshot(const DetectCardScreenshotRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DetectCardScreenshotOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DetectCardScreenshotOutcome(DetectCardScreenshotResult(outcome.result()));
|
||||
else
|
||||
return DetectCardScreenshotOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::detectCardScreenshotAsync(const DetectCardScreenshotRequest& request, const DetectCardScreenshotAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, detectCardScreenshot(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::DetectCardScreenshotOutcomeCallable OcrClient::detectCardScreenshotCallable(const DetectCardScreenshotRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DetectCardScreenshotOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->detectCardScreenshot(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::GetAsyncJobResultOutcome OcrClient::getAsyncJobResult(const GetAsyncJobResultRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -123,42 +87,6 @@ OcrClient::GetAsyncJobResultOutcomeCallable OcrClient::getAsyncJobResultCallable
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeAccountPageOutcome OcrClient::recognizeAccountPage(const RecognizeAccountPageRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RecognizeAccountPageOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RecognizeAccountPageOutcome(RecognizeAccountPageResult(outcome.result()));
|
||||
else
|
||||
return RecognizeAccountPageOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::recognizeAccountPageAsync(const RecognizeAccountPageRequest& request, const RecognizeAccountPageAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, recognizeAccountPage(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::RecognizeAccountPageOutcomeCallable OcrClient::recognizeAccountPageCallable(const RecognizeAccountPageRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RecognizeAccountPageOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->recognizeAccountPage(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeBankCardOutcome OcrClient::recognizeBankCard(const RecognizeBankCardRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -303,42 +231,6 @@ OcrClient::RecognizeCharacterOutcomeCallable OcrClient::recognizeCharacterCallab
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeChinapassportOutcome OcrClient::recognizeChinapassport(const RecognizeChinapassportRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RecognizeChinapassportOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RecognizeChinapassportOutcome(RecognizeChinapassportResult(outcome.result()));
|
||||
else
|
||||
return RecognizeChinapassportOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::recognizeChinapassportAsync(const RecognizeChinapassportRequest& request, const RecognizeChinapassportAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, recognizeChinapassport(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::RecognizeChinapassportOutcomeCallable OcrClient::recognizeChinapassportCallable(const RecognizeChinapassportRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RecognizeChinapassportOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->recognizeChinapassport(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeDriverLicenseOutcome OcrClient::recognizeDriverLicense(const RecognizeDriverLicenseRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -483,42 +375,6 @@ OcrClient::RecognizeLicensePlateOutcomeCallable OcrClient::recognizeLicensePlate
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizePassportMRZOutcome OcrClient::recognizePassportMRZ(const RecognizePassportMRZRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RecognizePassportMRZOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RecognizePassportMRZOutcome(RecognizePassportMRZResult(outcome.result()));
|
||||
else
|
||||
return RecognizePassportMRZOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::recognizePassportMRZAsync(const RecognizePassportMRZRequest& request, const RecognizePassportMRZAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, recognizePassportMRZ(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::RecognizePassportMRZOutcomeCallable OcrClient::recognizePassportMRZCallable(const RecognizePassportMRZRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RecognizePassportMRZOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->recognizePassportMRZ(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizePdfOutcome OcrClient::recognizePdf(const RecognizePdfRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -555,42 +411,6 @@ OcrClient::RecognizePdfOutcomeCallable OcrClient::recognizePdfCallable(const Rec
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizePoiNameOutcome OcrClient::recognizePoiName(const RecognizePoiNameRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RecognizePoiNameOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RecognizePoiNameOutcome(RecognizePoiNameResult(outcome.result()));
|
||||
else
|
||||
return RecognizePoiNameOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::recognizePoiNameAsync(const RecognizePoiNameRequest& request, const RecognizePoiNameAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, recognizePoiName(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::RecognizePoiNameOutcomeCallable OcrClient::recognizePoiNameCallable(const RecognizePoiNameRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RecognizePoiNameOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->recognizePoiName(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeQrCodeOutcome OcrClient::recognizeQrCode(const RecognizeQrCodeRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -735,42 +555,6 @@ OcrClient::RecognizeTableOutcomeCallable OcrClient::recognizeTableCallable(const
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeTakeoutOrderOutcome OcrClient::recognizeTakeoutOrder(const RecognizeTakeoutOrderRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RecognizeTakeoutOrderOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RecognizeTakeoutOrderOutcome(RecognizeTakeoutOrderResult(outcome.result()));
|
||||
else
|
||||
return RecognizeTakeoutOrderOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::recognizeTakeoutOrderAsync(const RecognizeTakeoutOrderRequest& request, const RecognizeTakeoutOrderAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, recognizeTakeoutOrder(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::RecognizeTakeoutOrderOutcomeCallable OcrClient::recognizeTakeoutOrderCallable(const RecognizeTakeoutOrderRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RecognizeTakeoutOrderOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->recognizeTakeoutOrder(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeTaxiInvoiceOutcome OcrClient::recognizeTaxiInvoice(const RecognizeTaxiInvoiceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -951,42 +735,6 @@ OcrClient::RecognizeVINCodeOutcomeCallable OcrClient::recognizeVINCodeCallable(c
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeVerificationcodeOutcome OcrClient::recognizeVerificationcode(const RecognizeVerificationcodeRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return RecognizeVerificationcodeOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return RecognizeVerificationcodeOutcome(RecognizeVerificationcodeResult(outcome.result()));
|
||||
else
|
||||
return RecognizeVerificationcodeOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::recognizeVerificationcodeAsync(const RecognizeVerificationcodeRequest& request, const RecognizeVerificationcodeAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, recognizeVerificationcode(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::RecognizeVerificationcodeOutcomeCallable OcrClient::recognizeVerificationcodeCallable(const RecognizeVerificationcodeRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<RecognizeVerificationcodeOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->recognizeVerificationcode(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::RecognizeVideoCharacterOutcome OcrClient::recognizeVideoCharacter(const RecognizeVideoCharacterRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -1023,39 +771,3 @@ OcrClient::RecognizeVideoCharacterOutcomeCallable OcrClient::recognizeVideoChara
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
OcrClient::TrimDocumentOutcome OcrClient::trimDocument(const TrimDocumentRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return TrimDocumentOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return TrimDocumentOutcome(TrimDocumentResult(outcome.result()));
|
||||
else
|
||||
return TrimDocumentOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void OcrClient::trimDocumentAsync(const TrimDocumentRequest& request, const TrimDocumentAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, trimDocument(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
OcrClient::TrimDocumentOutcomeCallable OcrClient::trimDocumentCallable(const TrimDocumentRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<TrimDocumentOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->trimDocument(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/DetectCardScreenshotRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::DetectCardScreenshotRequest;
|
||||
|
||||
DetectCardScreenshotRequest::DetectCardScreenshotRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "DetectCardScreenshot") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
DetectCardScreenshotRequest::~DetectCardScreenshotRequest() {}
|
||||
|
||||
std::string DetectCardScreenshotRequest::getImageURL() const {
|
||||
return imageURL_;
|
||||
}
|
||||
|
||||
void DetectCardScreenshotRequest::setImageURL(const std::string &imageURL) {
|
||||
imageURL_ = imageURL;
|
||||
setBodyParameter(std::string("ImageURL"), imageURL);
|
||||
}
|
||||
|
||||
@@ -1,62 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/DetectCardScreenshotResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
DetectCardScreenshotResult::DetectCardScreenshotResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DetectCardScreenshotResult::DetectCardScreenshotResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DetectCardScreenshotResult::~DetectCardScreenshotResult()
|
||||
{}
|
||||
|
||||
void DetectCardScreenshotResult::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["IsBlur"].isNull())
|
||||
data_.isBlur = dataNode["IsBlur"].asString() == "true";
|
||||
if(!dataNode["IsCard"].isNull())
|
||||
data_.isCard = dataNode["IsCard"].asString() == "true";
|
||||
auto spoofResultNode = dataNode["SpoofResult"];
|
||||
if(!spoofResultNode["IsSpoof"].isNull())
|
||||
data_.spoofResult.isSpoof = spoofResultNode["IsSpoof"].asString() == "true";
|
||||
auto resultMapNode = spoofResultNode["ResultMap"];
|
||||
if(!resultMapNode["ScreenThreshold"].isNull())
|
||||
data_.spoofResult.resultMap.screenThreshold = std::stof(resultMapNode["ScreenThreshold"].asString());
|
||||
if(!resultMapNode["ScreenScore"].isNull())
|
||||
data_.spoofResult.resultMap.screenScore = std::stof(resultMapNode["ScreenScore"].asString());
|
||||
|
||||
}
|
||||
|
||||
DetectCardScreenshotResult::Data DetectCardScreenshotResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -1,45 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeAccountPageRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::RecognizeAccountPageRequest;
|
||||
|
||||
RecognizeAccountPageRequest::RecognizeAccountPageRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "RecognizeAccountPage") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RecognizeAccountPageRequest::~RecognizeAccountPageRequest() {}
|
||||
|
||||
int RecognizeAccountPageRequest::getImageType() const {
|
||||
return imageType_;
|
||||
}
|
||||
|
||||
void RecognizeAccountPageRequest::setImageType(int imageType) {
|
||||
imageType_ = imageType;
|
||||
setBodyParameter(std::string("ImageType"), std::to_string(imageType));
|
||||
}
|
||||
|
||||
std::string RecognizeAccountPageRequest::getImageURL() const {
|
||||
return imageURL_;
|
||||
}
|
||||
|
||||
void RecognizeAccountPageRequest::setImageURL(const std::string &imageURL) {
|
||||
imageURL_ = imageURL;
|
||||
setBodyParameter(std::string("ImageURL"), imageURL);
|
||||
}
|
||||
|
||||
@@ -1,133 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeAccountPageResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
RecognizeAccountPageResult::RecognizeAccountPageResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RecognizeAccountPageResult::RecognizeAccountPageResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RecognizeAccountPageResult::~RecognizeAccountPageResult()
|
||||
{}
|
||||
|
||||
void RecognizeAccountPageResult::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["Gender"].isNull())
|
||||
data_.gender = dataNode["Gender"].asString();
|
||||
if(!dataNode["Angle"].isNull())
|
||||
data_.angle = std::stof(dataNode["Angle"].asString());
|
||||
if(!dataNode["Nationality"].isNull())
|
||||
data_.nationality = dataNode["Nationality"].asString();
|
||||
if(!dataNode["BirthPlace"].isNull())
|
||||
data_.birthPlace = dataNode["BirthPlace"].asString();
|
||||
if(!dataNode["BirthDate"].isNull())
|
||||
data_.birthDate = dataNode["BirthDate"].asString();
|
||||
if(!dataNode["Relation"].isNull())
|
||||
data_.relation = dataNode["Relation"].asString();
|
||||
if(!dataNode["NativePlace"].isNull())
|
||||
data_.nativePlace = dataNode["NativePlace"].asString();
|
||||
if(!dataNode["Name"].isNull())
|
||||
data_.name = dataNode["Name"].asString();
|
||||
if(!dataNode["IDNumber"].isNull())
|
||||
data_.iDNumber = dataNode["IDNumber"].asString();
|
||||
auto allRegisterStampAreasNode = dataNode["RegisterStampAreas"]["RegisterStampArea"];
|
||||
for (auto dataNodeRegisterStampAreasRegisterStampArea : allRegisterStampAreasNode)
|
||||
{
|
||||
Data::RegisterStampArea registerStampAreaObject;
|
||||
if(!dataNodeRegisterStampAreasRegisterStampArea["Top"].isNull())
|
||||
registerStampAreaObject.top = std::stoi(dataNodeRegisterStampAreasRegisterStampArea["Top"].asString());
|
||||
if(!dataNodeRegisterStampAreasRegisterStampArea["Width"].isNull())
|
||||
registerStampAreaObject.width = std::stoi(dataNodeRegisterStampAreasRegisterStampArea["Width"].asString());
|
||||
if(!dataNodeRegisterStampAreasRegisterStampArea["Height"].isNull())
|
||||
registerStampAreaObject.height = std::stoi(dataNodeRegisterStampAreasRegisterStampArea["Height"].asString());
|
||||
if(!dataNodeRegisterStampAreasRegisterStampArea["Left"].isNull())
|
||||
registerStampAreaObject.left = std::stoi(dataNodeRegisterStampAreasRegisterStampArea["Left"].asString());
|
||||
data_.registerStampAreas.push_back(registerStampAreaObject);
|
||||
}
|
||||
auto allOtherStampAreasNode = dataNode["OtherStampAreas"]["OtherStampArea"];
|
||||
for (auto dataNodeOtherStampAreasOtherStampArea : allOtherStampAreasNode)
|
||||
{
|
||||
Data::OtherStampArea otherStampAreaObject;
|
||||
if(!dataNodeOtherStampAreasOtherStampArea["Top"].isNull())
|
||||
otherStampAreaObject.top = std::stoi(dataNodeOtherStampAreasOtherStampArea["Top"].asString());
|
||||
if(!dataNodeOtherStampAreasOtherStampArea["Width"].isNull())
|
||||
otherStampAreaObject.width = std::stoi(dataNodeOtherStampAreasOtherStampArea["Width"].asString());
|
||||
if(!dataNodeOtherStampAreasOtherStampArea["Height"].isNull())
|
||||
otherStampAreaObject.height = std::stoi(dataNodeOtherStampAreasOtherStampArea["Height"].asString());
|
||||
if(!dataNodeOtherStampAreasOtherStampArea["Left"].isNull())
|
||||
otherStampAreaObject.left = std::stoi(dataNodeOtherStampAreasOtherStampArea["Left"].asString());
|
||||
data_.otherStampAreas.push_back(otherStampAreaObject);
|
||||
}
|
||||
auto allUndertakeStampAreasNode = dataNode["UndertakeStampAreas"]["UndertakeStampArea"];
|
||||
for (auto dataNodeUndertakeStampAreasUndertakeStampArea : allUndertakeStampAreasNode)
|
||||
{
|
||||
Data::UndertakeStampArea undertakeStampAreaObject;
|
||||
if(!dataNodeUndertakeStampAreasUndertakeStampArea["Top"].isNull())
|
||||
undertakeStampAreaObject.top = std::stoi(dataNodeUndertakeStampAreasUndertakeStampArea["Top"].asString());
|
||||
if(!dataNodeUndertakeStampAreasUndertakeStampArea["Width"].isNull())
|
||||
undertakeStampAreaObject.width = std::stoi(dataNodeUndertakeStampAreasUndertakeStampArea["Width"].asString());
|
||||
if(!dataNodeUndertakeStampAreasUndertakeStampArea["Height"].isNull())
|
||||
undertakeStampAreaObject.height = std::stoi(dataNodeUndertakeStampAreasUndertakeStampArea["Height"].asString());
|
||||
if(!dataNodeUndertakeStampAreasUndertakeStampArea["Left"].isNull())
|
||||
undertakeStampAreaObject.left = std::stoi(dataNodeUndertakeStampAreasUndertakeStampArea["Left"].asString());
|
||||
data_.undertakeStampAreas.push_back(undertakeStampAreaObject);
|
||||
}
|
||||
auto allInvalidStampAreasNode = dataNode["InvalidStampAreas"]["InvalidStampArea"];
|
||||
for (auto dataNodeInvalidStampAreasInvalidStampArea : allInvalidStampAreasNode)
|
||||
{
|
||||
Data::InvalidStampArea invalidStampAreaObject;
|
||||
if(!dataNodeInvalidStampAreasInvalidStampArea["Top"].isNull())
|
||||
invalidStampAreaObject.top = std::stoi(dataNodeInvalidStampAreasInvalidStampArea["Top"].asString());
|
||||
if(!dataNodeInvalidStampAreasInvalidStampArea["Width"].isNull())
|
||||
invalidStampAreaObject.width = std::stoi(dataNodeInvalidStampAreasInvalidStampArea["Width"].asString());
|
||||
if(!dataNodeInvalidStampAreasInvalidStampArea["Height"].isNull())
|
||||
invalidStampAreaObject.height = std::stoi(dataNodeInvalidStampAreasInvalidStampArea["Height"].asString());
|
||||
if(!dataNodeInvalidStampAreasInvalidStampArea["Left"].isNull())
|
||||
invalidStampAreaObject.left = std::stoi(dataNodeInvalidStampAreasInvalidStampArea["Left"].asString());
|
||||
data_.invalidStampAreas.push_back(invalidStampAreaObject);
|
||||
}
|
||||
auto titleAreaNode = dataNode["TitleArea"];
|
||||
if(!titleAreaNode["Top"].isNull())
|
||||
data_.titleArea.top = std::stoi(titleAreaNode["Top"].asString());
|
||||
if(!titleAreaNode["Width"].isNull())
|
||||
data_.titleArea.width = std::stoi(titleAreaNode["Width"].asString());
|
||||
if(!titleAreaNode["Height"].isNull())
|
||||
data_.titleArea.height = std::stoi(titleAreaNode["Height"].asString());
|
||||
if(!titleAreaNode["Left"].isNull())
|
||||
data_.titleArea.left = std::stoi(titleAreaNode["Left"].asString());
|
||||
|
||||
}
|
||||
|
||||
RecognizeAccountPageResult::Data RecognizeAccountPageResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeChinapassportRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::RecognizeChinapassportRequest;
|
||||
|
||||
RecognizeChinapassportRequest::RecognizeChinapassportRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "RecognizeChinapassport") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RecognizeChinapassportRequest::~RecognizeChinapassportRequest() {}
|
||||
|
||||
std::string RecognizeChinapassportRequest::getImageURL() const {
|
||||
return imageURL_;
|
||||
}
|
||||
|
||||
void RecognizeChinapassportRequest::setImageURL(const std::string &imageURL) {
|
||||
imageURL_ = imageURL;
|
||||
setBodyParameter(std::string("ImageURL"), imageURL);
|
||||
}
|
||||
|
||||
@@ -1,94 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeChinapassportResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
RecognizeChinapassportResult::RecognizeChinapassportResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RecognizeChinapassportResult::RecognizeChinapassportResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RecognizeChinapassportResult::~RecognizeChinapassportResult()
|
||||
{}
|
||||
|
||||
void RecognizeChinapassportResult::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["Type"].isNull())
|
||||
data_.type = dataNode["Type"].asString();
|
||||
if(!dataNode["Sex"].isNull())
|
||||
data_.sex = dataNode["Sex"].asString();
|
||||
if(!dataNode["Authority"].isNull())
|
||||
data_.authority = dataNode["Authority"].asString();
|
||||
if(!dataNode["IssuePlaceRaw"].isNull())
|
||||
data_.issuePlaceRaw = dataNode["IssuePlaceRaw"].asString();
|
||||
if(!dataNode["Success"].isNull())
|
||||
data_.success = dataNode["Success"].asString() == "true";
|
||||
if(!dataNode["LineOne"].isNull())
|
||||
data_.lineOne = dataNode["LineOne"].asString();
|
||||
if(!dataNode["ExpiryDate"].isNull())
|
||||
data_.expiryDate = dataNode["ExpiryDate"].asString();
|
||||
if(!dataNode["BirthPlace"].isNull())
|
||||
data_.birthPlace = dataNode["BirthPlace"].asString();
|
||||
if(!dataNode["PassportNo"].isNull())
|
||||
data_.passportNo = dataNode["PassportNo"].asString();
|
||||
if(!dataNode["BirthPlaceRaw"].isNull())
|
||||
data_.birthPlaceRaw = dataNode["BirthPlaceRaw"].asString();
|
||||
if(!dataNode["IssueDate"].isNull())
|
||||
data_.issueDate = dataNode["IssueDate"].asString();
|
||||
if(!dataNode["SourceCountry"].isNull())
|
||||
data_.sourceCountry = dataNode["SourceCountry"].asString();
|
||||
if(!dataNode["BirthDate"].isNull())
|
||||
data_.birthDate = dataNode["BirthDate"].asString();
|
||||
if(!dataNode["NameChineseRaw"].isNull())
|
||||
data_.nameChineseRaw = dataNode["NameChineseRaw"].asString();
|
||||
if(!dataNode["IssuePlace"].isNull())
|
||||
data_.issuePlace = dataNode["IssuePlace"].asString();
|
||||
if(!dataNode["NameChinese"].isNull())
|
||||
data_.nameChinese = dataNode["NameChinese"].asString();
|
||||
if(!dataNode["LineZero"].isNull())
|
||||
data_.lineZero = dataNode["LineZero"].asString();
|
||||
if(!dataNode["Country"].isNull())
|
||||
data_.country = dataNode["Country"].asString();
|
||||
if(!dataNode["BirthDay"].isNull())
|
||||
data_.birthDay = dataNode["BirthDay"].asString();
|
||||
if(!dataNode["ExpiryDay"].isNull())
|
||||
data_.expiryDay = dataNode["ExpiryDay"].asString();
|
||||
if(!dataNode["Name"].isNull())
|
||||
data_.name = dataNode["Name"].asString();
|
||||
if(!dataNode["PersonId"].isNull())
|
||||
data_.personId = dataNode["PersonId"].asString();
|
||||
|
||||
}
|
||||
|
||||
RecognizeChinapassportResult::Data RecognizeChinapassportResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizePassportMRZRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::RecognizePassportMRZRequest;
|
||||
|
||||
RecognizePassportMRZRequest::RecognizePassportMRZRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "RecognizePassportMRZ") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RecognizePassportMRZRequest::~RecognizePassportMRZRequest() {}
|
||||
|
||||
std::string RecognizePassportMRZRequest::getImageURL() const {
|
||||
return imageURL_;
|
||||
}
|
||||
|
||||
void RecognizePassportMRZRequest::setImageURL(const std::string &imageURL) {
|
||||
imageURL_ = imageURL;
|
||||
setBodyParameter(std::string("ImageURL"), imageURL);
|
||||
}
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizePassportMRZResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
RecognizePassportMRZResult::RecognizePassportMRZResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RecognizePassportMRZResult::RecognizePassportMRZResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RecognizePassportMRZResult::~RecognizePassportMRZResult()
|
||||
{}
|
||||
|
||||
void RecognizePassportMRZResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
auto allRegionsNode = dataNode["Regions"]["Region"];
|
||||
for (auto dataNodeRegionsRegion : allRegionsNode)
|
||||
{
|
||||
Data::Region regionObject;
|
||||
if(!dataNodeRegionsRegion["RecognitionScore"].isNull())
|
||||
regionObject.recognitionScore = std::stof(dataNodeRegionsRegion["RecognitionScore"].asString());
|
||||
if(!dataNodeRegionsRegion["DetectionScore"].isNull())
|
||||
regionObject.detectionScore = std::stof(dataNodeRegionsRegion["DetectionScore"].asString());
|
||||
if(!dataNodeRegionsRegion["Name"].isNull())
|
||||
regionObject.name = dataNodeRegionsRegion["Name"].asString();
|
||||
if(!dataNodeRegionsRegion["Content"].isNull())
|
||||
regionObject.content = dataNodeRegionsRegion["Content"].asString();
|
||||
auto allBandBoxes = value["BandBoxes"]["BandBox"];
|
||||
for (auto value : allBandBoxes)
|
||||
regionObject.bandBoxes.push_back(value.asString());
|
||||
data_.regions.push_back(regionObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
RecognizePassportMRZResult::Data RecognizePassportMRZResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizePoiNameRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::RecognizePoiNameRequest;
|
||||
|
||||
RecognizePoiNameRequest::RecognizePoiNameRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "RecognizePoiName") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RecognizePoiNameRequest::~RecognizePoiNameRequest() {}
|
||||
|
||||
std::string RecognizePoiNameRequest::getImageURL() const {
|
||||
return imageURL_;
|
||||
}
|
||||
|
||||
void RecognizePoiNameRequest::setImageURL(const std::string &imageURL) {
|
||||
imageURL_ = imageURL;
|
||||
setBodyParameter(std::string("ImageURL"), imageURL);
|
||||
}
|
||||
|
||||
@@ -1,78 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizePoiNameResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
RecognizePoiNameResult::RecognizePoiNameResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RecognizePoiNameResult::RecognizePoiNameResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RecognizePoiNameResult::~RecognizePoiNameResult()
|
||||
{}
|
||||
|
||||
void RecognizePoiNameResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
auto allSignboardsNode = dataNode["Signboards"]["SignboardsItem"];
|
||||
for (auto dataNodeSignboardsSignboardsItem : allSignboardsNode)
|
||||
{
|
||||
Data::SignboardsItem signboardsItemObject;
|
||||
auto allTextsNode = dataNodeSignboardsSignboardsItem["Texts"]["TextsItem"];
|
||||
for (auto dataNodeSignboardsSignboardsItemTextsTextsItem : allTextsNode)
|
||||
{
|
||||
Data::SignboardsItem::TextsItem textsObject;
|
||||
if(!dataNodeSignboardsSignboardsItemTextsTextsItem["Type"].isNull())
|
||||
textsObject.type = dataNodeSignboardsSignboardsItemTextsTextsItem["Type"].asString();
|
||||
if(!dataNodeSignboardsSignboardsItemTextsTextsItem["Score"].isNull())
|
||||
textsObject.score = std::stof(dataNodeSignboardsSignboardsItemTextsTextsItem["Score"].asString());
|
||||
if(!dataNodeSignboardsSignboardsItemTextsTextsItem["Tag"].isNull())
|
||||
textsObject.tag = dataNodeSignboardsSignboardsItemTextsTextsItem["Tag"].asString();
|
||||
if(!dataNodeSignboardsSignboardsItemTextsTextsItem["Label"].isNull())
|
||||
textsObject.label = dataNodeSignboardsSignboardsItemTextsTextsItem["Label"].asString();
|
||||
auto allPoints = value["Points"]["Points"];
|
||||
for (auto value : allPoints)
|
||||
textsObject.points.push_back(value.asString());
|
||||
signboardsItemObject.texts.push_back(textsObject);
|
||||
}
|
||||
data_.signboards.push_back(signboardsItemObject);
|
||||
}
|
||||
auto summaryNode = dataNode["Summary"];
|
||||
if(!summaryNode["Brand"].isNull())
|
||||
data_.summary.brand = summaryNode["Brand"].asString();
|
||||
if(!summaryNode["Score"].isNull())
|
||||
data_.summary.score = std::stof(summaryNode["Score"].asString());
|
||||
|
||||
}
|
||||
|
||||
RecognizePoiNameResult::Data RecognizePoiNameResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeTakeoutOrderRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::RecognizeTakeoutOrderRequest;
|
||||
|
||||
RecognizeTakeoutOrderRequest::RecognizeTakeoutOrderRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "RecognizeTakeoutOrder") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RecognizeTakeoutOrderRequest::~RecognizeTakeoutOrderRequest() {}
|
||||
|
||||
std::string RecognizeTakeoutOrderRequest::getImageURL() const {
|
||||
return imageURL_;
|
||||
}
|
||||
|
||||
void RecognizeTakeoutOrderRequest::setImageURL(const std::string &imageURL) {
|
||||
imageURL_ = imageURL;
|
||||
setBodyParameter(std::string("ImageURL"), imageURL);
|
||||
}
|
||||
|
||||
@@ -1,65 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeTakeoutOrderResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
RecognizeTakeoutOrderResult::RecognizeTakeoutOrderResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RecognizeTakeoutOrderResult::RecognizeTakeoutOrderResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RecognizeTakeoutOrderResult::~RecognizeTakeoutOrderResult()
|
||||
{}
|
||||
|
||||
void RecognizeTakeoutOrderResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto dataNode = value["Data"];
|
||||
auto allElementsNode = dataNode["Elements"]["Element"];
|
||||
for (auto dataNodeElementsElement : allElementsNode)
|
||||
{
|
||||
Data::Element elementObject;
|
||||
if(!dataNodeElementsElement["Value"].isNull())
|
||||
elementObject.value = dataNodeElementsElement["Value"].asString();
|
||||
if(!dataNodeElementsElement["Score"].isNull())
|
||||
elementObject.score = std::stof(dataNodeElementsElement["Score"].asString());
|
||||
if(!dataNodeElementsElement["Name"].isNull())
|
||||
elementObject.name = dataNodeElementsElement["Name"].asString();
|
||||
auto allBoxes = value["Boxes"]["Box"];
|
||||
for (auto value : allBoxes)
|
||||
elementObject.boxes.push_back(value.asString());
|
||||
data_.elements.push_back(elementObject);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
RecognizeTakeoutOrderResult::Data RecognizeTakeoutOrderResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeVerificationcodeRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::RecognizeVerificationcodeRequest;
|
||||
|
||||
RecognizeVerificationcodeRequest::RecognizeVerificationcodeRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "RecognizeVerificationcode") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
RecognizeVerificationcodeRequest::~RecognizeVerificationcodeRequest() {}
|
||||
|
||||
std::string RecognizeVerificationcodeRequest::getImageURL() const {
|
||||
return imageURL_;
|
||||
}
|
||||
|
||||
void RecognizeVerificationcodeRequest::setImageURL(const std::string &imageURL) {
|
||||
imageURL_ = imageURL;
|
||||
setBodyParameter(std::string("ImageURL"), imageURL);
|
||||
}
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/RecognizeVerificationcodeResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
RecognizeVerificationcodeResult::RecognizeVerificationcodeResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
RecognizeVerificationcodeResult::RecognizeVerificationcodeResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
RecognizeVerificationcodeResult::~RecognizeVerificationcodeResult()
|
||||
{}
|
||||
|
||||
void RecognizeVerificationcodeResult::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["Content"].isNull())
|
||||
data_.content = dataNode["Content"].asString();
|
||||
|
||||
}
|
||||
|
||||
RecognizeVerificationcodeResult::Data RecognizeVerificationcodeResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
@@ -1,63 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/TrimDocumentRequest.h>
|
||||
|
||||
using AlibabaCloud::Ocr::Model::TrimDocumentRequest;
|
||||
|
||||
TrimDocumentRequest::TrimDocumentRequest()
|
||||
: RpcServiceRequest("ocr", "2019-12-30", "TrimDocument") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
TrimDocumentRequest::~TrimDocumentRequest() {}
|
||||
|
||||
std::string TrimDocumentRequest::getFileType() const {
|
||||
return fileType_;
|
||||
}
|
||||
|
||||
void TrimDocumentRequest::setFileType(const std::string &fileType) {
|
||||
fileType_ = fileType;
|
||||
setBodyParameter(std::string("FileType"), fileType);
|
||||
}
|
||||
|
||||
std::string TrimDocumentRequest::getOutputType() const {
|
||||
return outputType_;
|
||||
}
|
||||
|
||||
void TrimDocumentRequest::setOutputType(const std::string &outputType) {
|
||||
outputType_ = outputType;
|
||||
setBodyParameter(std::string("OutputType"), outputType);
|
||||
}
|
||||
|
||||
bool TrimDocumentRequest::getAsync() const {
|
||||
return async_;
|
||||
}
|
||||
|
||||
void TrimDocumentRequest::setAsync(bool async) {
|
||||
async_ = async;
|
||||
setBodyParameter(std::string("Async"), async ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string TrimDocumentRequest::getFileURL() const {
|
||||
return fileURL_;
|
||||
}
|
||||
|
||||
void TrimDocumentRequest::setFileURL(const std::string &fileURL) {
|
||||
fileURL_ = fileURL;
|
||||
setBodyParameter(std::string("FileURL"), fileURL);
|
||||
}
|
||||
|
||||
@@ -1,66 +0,0 @@
|
||||
/*
|
||||
* 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/ocr/model/TrimDocumentResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Ocr;
|
||||
using namespace AlibabaCloud::Ocr::Model;
|
||||
|
||||
TrimDocumentResult::TrimDocumentResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
TrimDocumentResult::TrimDocumentResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
TrimDocumentResult::~TrimDocumentResult()
|
||||
{}
|
||||
|
||||
void TrimDocumentResult::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["Content"].isNull())
|
||||
data_.content = dataNode["Content"].asString();
|
||||
if(!value["Code"].isNull())
|
||||
code_ = value["Code"].asString();
|
||||
if(!value["Message"].isNull())
|
||||
message_ = value["Message"].asString();
|
||||
|
||||
}
|
||||
|
||||
std::string TrimDocumentResult::getMessage()const
|
||||
{
|
||||
return message_;
|
||||
}
|
||||
|
||||
TrimDocumentResult::Data TrimDocumentResult::getData()const
|
||||
{
|
||||
return data_;
|
||||
}
|
||||
|
||||
std::string TrimDocumentResult::getCode()const
|
||||
{
|
||||
return code_;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user