function Prototypes

Description

The following are all the function prototypes used in Dynamsoft Camera SDK.

onHttpDownloadSuccess()

Parameters Type Description
None N/A N/A

onHttpDownloadFailure(errorCode, errorString, httpResponse)

Parameters Type Description
errorCode <int> the error code
errorString <string> the error string
httpResponse <string> the error information returned from the server

bool onHttpDownloading(percentage)

onHttpDownloading() is triggered during image downloading. You can get percentage has been downloaded or cancel downloading with this function. If it returns true, the downloading will be cancelled, otherwise the downloading will continue.

Parameters Type Description
percentage <short> the percentage that has been downloaded. The range is 0~100.

onHttpDownloadSuccess(), onHttpDownloadFailure() and onHttpDownloading() are Function prototypes for the callback function used in method httpDownloadAsync.

onHttpUploadSuccess(httpResponse)

Parameters Type Description
httpResponse <string> the information returned from the server after the upload

onHttpUploadFailure(errorCode, errorString, httpResponse)

Parameters Type Description
errorCode <int> the error code
errorString <string> the error string
httpResponse <string> the detailed error information returned from the server

bool onhttpuploading(percentage)

onhttpuploading() is triggered during image uploading. You can get percentage has been uploaded or cancel uploading with this function. If it returns true, the uploading will be cancelled, otherwise the uploading will continue.

Parameters Type Description
percentage <short> the percentage that has been uploaded. The range is 0~100.

onHttpUploadSuccess(), onHttpUploadFailure() and onhttpuploading() are Function prototypes for the callback function used in method httpUploadAsync.

onSaveSuccess(filePath)

Parameters Type Description
filePath <string> the absolute path of the file to be saved.

onSaveFailure(errorCode, errorString, filePath)

Parameters Type Description
errorCode <int> the error code
errorString <string> the error string
filePath <string> the absolute path of the file that failed to be saved.

onSaveSuccess() and onSaveFailure() are Function prototypes for the callback function used in method saveAsync.

See Also

getErrorCode()
getErrorString()

Is this page helpful?

Leave a Reply

Your email address will not be published.