pub unsafe extern "C" fn OH_Scan_OpenScanner(
scannerId: *const c_char,
) -> i32Available on crate features
scan and api-12 only.Expand description
This API connects to scanner devices.
ohos.permission.PRINT
§Arguments
scannerId- The id used to connect to the scanner.
§Returns
- [
Scan_ERROR_NONE] Indicates that the scanner was successfully connected. [SCAN_ERROR_NO_PERMISSION] Indicates have no permission to use this interface. [SCAN_ERROR_RPC_FAILURE] Indicates an RPC communication error. [SCAN_ERROR_SERVER_FAILURE] Indicates An error occurs in the scan process. [SCAN_ERROR_DEVICE_BUSY] Indicates that the scanner is busy. [SCAN_ERROR_INVALID_PARAMETER] Indicates that the input parameter is invalid. [SCAN_ERROR_IO_ERROR] Indicates an error occured while communicating with the device. [SCAN_ERROR_NO_MEMORY] Indicates an insufficent amount of memory is available.
Required System Capabilities: SystemCapability.Print.PrintFramework
Available since API-level: 12