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 information returned from the server after file downloading

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 the following method httpUploadAsync

See Also

getErrorCode()
getErrorString()