You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`BarcodeScanResult` is a result class that contains all decoded barcodes from one scan and the additional information.
13
+
`BarcodeScanResult` is a result class that contains all decoded barcodes and their associated info from a single scan.
14
14
15
15
## Definition
16
16
@@ -26,14 +26,14 @@ class BarcodeScanResult
26
26
27
27
| Method | Description |
28
28
| ------ | ----------- |
29
-
| [`getBarcodes`](#getbarcodes) | Returns an array of [`BarcodeResultItem`]({{ site.dbr_android_api }}barcode-result-item.html), which is the basic item of the captured results. |
30
-
| [`getResultStatus`](#getresultstatus) |Get the status of the result, which can be finished, canceled or exception. |
29
+
| [`getBarcodes`](#getbarcodes) | Returns an array of [`BarcodeResultItem`]({{ site.dbr_android_api }}barcode-result-item.html), which represents a single barocde result. |
30
+
| [`getResultStatus`](#getresultstatus) |Returns the status of the `BarcodeScanResult`, which can indicate success or failure. |
31
31
| [`getErrorCode`](#geterrorcode) |Returns the error code should something go wrong during the barcode recognition process. |
32
32
| [`getErrorString`](#geterrorstring) |Returns the error message associated with the error code should something go wrong during the barcode recognition process. |
33
33
34
34
### getBarcodes
35
35
36
-
Returns an array of [`BarcodeResultItem`]({{ site.dbr_android_api }}barcode-result-item.html), which is the basic item of the captured results.
36
+
Returns an array of [`BarcodeResultItem`]({{ site.dbr_android_api }}barcode-result-item.html), which represents a single barocde result and is the most basic unit of the captured results.
37
37
38
38
```java
39
39
BarcodeResultItem[] getBarcodes();
@@ -45,7 +45,7 @@ An array of [`BarcodeResultItems`]({{ site.dbr_android_api }}barcode-result-item
45
45
46
46
### getResultStatus
47
47
48
-
Get the status of the result, which can be finished, canceled or exception.
48
+
Returns the status of the `BarcodeScanResult`, which can be one of *finished*, *canceled* or *exception*.
`BarcodeScannerConfig` is the class that defines the configurations for barcode scanning. It is set via the input value of `BarcodeScannerActivity.ResultContract`
13
+
`BarcodeScannerConfig` is the class that defines the configurations for barcode scanning. Once the `BarcodeScannerConfig` object is made, it is set via the `BarcodeScannerActivity.ResultContract`.
14
14
15
15
## Definition
16
16
@@ -26,28 +26,28 @@ final class BarcodeScannerConfig
26
26
27
27
| Method | Description |
28
28
| ------ | ----------- |
29
-
| [`setLicense`](#setlicense) | Set the license. |
30
-
| [`setTemplateFilePath`](#settemplatefilepath) | Set a path for the SDK to load template file. |
31
-
| [`setBarcodeFormats`](#setbarcodeformats) | Set the barcode formats to read. |
32
-
| [`setScanRegion`](#setscanregion) | Set a scan region. Only the barcodes located in the scan region can be decoded. |
33
-
| [`setTorchButtonVisible`](#settorchbuttonvisible) | Set whether to display the torch button when scanning. Uses can click the torch button to turn on/off the torch. |
34
-
| [`setBeepEnabled`](#setbeepenabled) | Set whether to trigger a beep sound when a barcode is detected. |
35
-
| [`setScanLaserVisible`](#setscanlaservisible) | Set whether to display a scan laser when scanning. |
36
-
| [`setAutoZoomEnabled`](#setautozoomenabled) | Set whether to enable the auto-zoom feature when scanning. |
37
-
| [`setCloseButtonVisible`](#setclosebuttonvisible) | Set whether to display a button for uses to close the scanner page. |
38
-
| [`getLicense`](#getlicense) | Returns the license string. |
39
-
| [`getTemplateFilePath`](#gettemplatefilepath) | Get the file path of the template file. |
29
+
| [`setLicense`](#setlicense) | Sets the license key for the Barcode Reader. |
30
+
| [`setTemplateFilePath`](#settemplatefilepath) | Sets the parameters template for the Barcode Reader via a local JSON file path. |
31
+
| [`setBarcodeFormats`](#setbarcodeformats) | Sets the barcode format(s) to read. |
32
+
| [`setScanRegion`](#setscanregion) | Sets a scan region where only the barcodes located in the scan region can be decoded. |
33
+
| [`setTorchButtonVisible`](#settorchbuttonvisible) | Sets whether to display the torch button when scanning or not. Uses can click the torch button to turn on/off the torch. |
34
+
| [`setBeepEnabled`](#setbeepenabled) | Sets whether to trigger a beep sound when a barcode is detected. |
35
+
| [`setScanLaserVisible`](#setscanlaservisible) | Sets whether to display a scan laser when scanning. |
36
+
| [`setAutoZoomEnabled`](#setautozoomenabled) | Sets whether to enable the auto-zoom feature when scanning. |
37
+
| [`setCloseButtonVisible`](#setclosebuttonvisible) | Sets whether to display a button that can close the scanner page. |
38
+
| [`getLicense`](#getlicense) | Returns the license key string. |
39
+
| [`getTemplateFilePath`](#gettemplatefilepath) | Returns the file path of the template file if one is being used. |
40
40
| [`isTorchButtonVisible`](#istorchbuttonvisible) | Returns whether the button is visible. |
41
-
| [`getBarcodeFormats`](#getbarcodeformats) | Returns the barcode format settings. |
42
-
| [`getScanRegion`](#getscanregion) | Get the scan region. |
41
+
| [`getBarcodeFormats`](#getbarcodeformats) | Returns the barcode format(s) that the library will accept. |
42
+
| [`getScanRegion`](#getscanregion) | Returns the scan region. |
43
43
| [`isBeepEnabled`](#isbeepenabled) | Returns whether the beep sound is enabled. |
44
44
| [`isScanLaserVisible`](#isscanlaservisible) | Returns whether the scan laser is visible. |
45
-
| [`isAutoZoomEnabled`](#isautozoomenabled) | Returns whether the auto-zoom is enabled. |
45
+
| [`isAutoZoomEnabled`](#isautozoomenabled) | Returns whether the auto-zoom feature is enabled. |
46
46
| [`isCloseButtonVisible`](#isclosebuttonvisible) | Returns whether the close button is visible. |
`EnumResultStatus` is a enumeration class that defines the result status of the `BarcodeScanResult`.
13
+
`EnumResultStatus` is an enumeration class that defines the result status of the `BarcodeScanResult`.
14
+
15
+
If the status is **finished**, that indicates that the result has been decoded and is available - while **canceled** indicates that the operation has been halted. If the result status is **exception**, then that means that an error has occurred during the barcode detection process.
Copy file name to clipboardExpand all lines: programming/android/user-guide.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,14 +12,14 @@ enableLanguageSelection: true
12
12
13
13
# Android User Guide for Barcode Scanning
14
14
15
-
This user guide will walk through the [ScanSingleBarcode](https://github.com/Dynamsoft/barcode-reader-mobile-samples/tree/main/android/BarcodeScannerAPISamples/) sample app. When creating your own project, please use this sample as a reference. This guide uses RTU (Ready to Use) APIs which aim to elevate the UI creation process with less code and offer a more pleasant and intuitive UI for your app.
15
+
This user guide will walk through the [ScanSingleBarcode](https://github.com/Dynamsoft/barcode-reader-mobile-samples/tree/main/android/BarcodeScannerAPISamples/) sample app. When creating your own project, please use this sample as a reference. This guide uses [`BarcodeScanner`](api-reference/barcode-scanner/index.md) API which aim to elevate the UI creation process with less code and offer a more pleasant and intuitive UI for your app.
16
16
17
17
> Note:
18
18
>
19
19
> This guide aims at scanning a single barcode with the `BarcodeScanner` component.
20
20
>
21
21
> - If you have requirement for scanning multiple barcodes, you may refer to the [DecodeMultipleBrcodes sample](https://github.com/Dynamsoft/barcode-reader-mobile-samples/tree/main/android/FoundationalAPISamples/DecodeMultipleBarcodes).
22
-
> - If you have higher customization requirements for the interface, you may refer to the [Foundational API Samples](https://github.com/Dynamsoft/barcode-reader-mobile-samples/tree/main/android/FoundationalAPISamples/) or [Build your APP with Foundational APIs]({{ site.android }}user-guide.html) article.
22
+
> - If you have more complex customization requirements for the interface, you may refer to the [Foundational API Samples](https://github.com/Dynamsoft/barcode-reader-mobile-samples/tree/main/android/FoundationalAPISamples/) or [Build your APP with Foundational APIs]({{ site.android }}user-guide.html) article.
23
23
24
24
## Requirements
25
25
@@ -57,7 +57,7 @@ There are two ways in which you can include the `dynamsoftbarcodereaderbundle` l
57
57
58
58
### Option 2: Add the Libraries via Local .aar Files
59
59
60
-
1. Download the SDK package from the <ahref="https://www.dynamsoft.com/barcode-reader/downloads/?utm_source=docs#mobile"target="_blank">Dynamsoft Website</a>. After unzipping, you should find a single **aar**file can be found in the **Dynamsoft\Libs** directory:
60
+
1. Download the SDK package from the <ahref="https://www.dynamsoft.com/barcode-reader/downloads/?utm_source=docs#mobile"target="_blank">Dynamsoft Website</a>. After unzipping, several **aar**files can be found in the **Dynamsoft\Libs** directory:
61
61
62
62
- 📄 **DynamsoftBarcodeReaderBundle.aar**
63
63
- 📄 **DynamsoftCaptureVisionRouter.aar**
@@ -68,7 +68,7 @@ There are two ways in which you can include the `dynamsoftbarcodereaderbundle` l
68
68
- 📄 **DynamsoftImageProcessing.aar**
69
69
- 📄 **DynamsoftUtility.aar**
70
70
71
-
2. Copy the above **aar**file to the target directory such as `[App Project Root Path]\app\libs`
71
+
2. Copy the above **.aar**files to the target directory such as *[App Project Root Path]\app\libs*
72
72
73
73
3. Open the file `[App Project Root Path]\app\build.gradle` and add the reference in the dependencies:
74
74
@@ -305,7 +305,7 @@ Now that the code has been written and the project complete, it's time to run th
305
305
306
306
## Conclusion
307
307
308
-
Now that your RTU project is up and running you should be able to see a clean and simplified UI that contains all the necessary UI elements that are needed to make the barcode scanning process as easy and intuitive for the user as it can be.
308
+
Now that your `BarcodeScanner` project is up and running you should be able to see a clean and simplified UI that contains all the necessary UI elements that are needed to make the barcode scanning process as easy and intuitive for the user as it can be.
`DSBarcodeScanResult` is a result class that contains all decoded barcodes from one scan and the additional information.
13
+
`DSBarcodeScanResult` is a result class that contains all decoded barcodes and their associated info from a single scan.
14
14
15
15
## Definition
16
16
@@ -34,13 +34,13 @@ class BarcodeScanResult : NSObject
34
34
| Property | Type | Description |
35
35
| -------- | ---- | ----------- |
36
36
|[`barcodes`](#barcodes)|*NSArray<DSBarcodeResultItem\*> \**| An array of [`DSBarcodeResultItem`]({{ site.dbr_ios_api }}barcode-result-item.html), which is the basic item of the captured results. |
37
-
|[`resultStatus`](#resultstatus)|*DSResultStatus*| The status of the result, which can be finished, canceled or exception. |
37
+
|[`resultStatus`](#resultstatus)|*DSResultStatus*| The status of the `BarcodeScanResult`, which can indicate success or failure. |
38
38
|[`errorCode`](#errorcode)|*NSInteger*| The error code should something go wrong during the barcode recognition process. |
39
39
|[`errorString`](#errorstring)|*NSString \**| The error message associated with the error code should something go wrong during the barcode recognition process. |
40
40
41
41
### barcodes
42
42
43
-
An array of [`DSBarcodeResultItem`]({{ site.dbr_ios_api }}barcode-result-item.html), which is the basic item of the captured results.
43
+
An array of [`DSBarcodeResultItem`]({{ site.dbr_ios_api }}barcode-result-item.html), which is the basic item of the captured results and is the most basic unit of the captured results.
44
44
45
45
<div class="sample-code-prefix"></div>
46
46
>- Objective-C
@@ -57,7 +57,7 @@ var barcodes: [BarcodeResultItem] {get}
57
57
58
58
### resultStatus
59
59
60
-
The status of the result, which can be finished, canceled or exception.
60
+
The status of the result, which can be one of *finished*, *canceled* or *exception*.
0 commit comments