Skip to content

Commit de60897

Browse files
Updating mobile API references
1 parent 2d3d74d commit de60897

File tree

19 files changed

+872
-1
lines changed

19 files changed

+872
-1
lines changed

_includes/release-notes/product-highlight-2.0.0.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

22
* `DynamsoftCodeParser` SDK has been revamped to integrate with `DynamsoftCaptureVision (DCV)` architecture, which is newly established to aggregate the features of functional products powered by Dynamsoft. The features are designed to be pluggable, customizable and interactable. In addition, the functional products share the computation so that their processing speed is much higher than working individually.
3-
* Added C++ Edition. With this new edition, developers can effortlessly integrate code parsing capabilities into their C++ applications.
3+
* Added Mobile Editions. With these new editions, developers can effortlessly integrate code parsing capabilities into their Android and iOS applications.
44
* Added supports to parse following code types:
55
* [MRTD_TD1_ID]({{ site.code_types }}mrtd.html)
66
* [MRTD_TD2_ID]({{ site.code_types }}mrtd.html)
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
layout: default-layout
3+
title: CCodeParserModule Class - Dynamsoft Code Parser SDK Android Edition API Reference
4+
description: This page shows CCodeParserModule Class of Dynamsoft Code Parser SDK Android Edition.
5+
keywords: CCodeParserModule, api reference, Android
6+
needAutoGenerateSidebar: true
7+
---
8+
9+
# CodeParserModule Class
10+
11+
`CodeParserModule` class defines general functions of the code parser module.
12+
13+
| Method | Description |
14+
|----------------------|-------------|
15+
| [`getVersion`](#getversion) | Get version information of SDK.|
16+
17+
## getVersion
18+
19+
Get version information of SDK.
20+
21+
```java
22+
static String getVersion();
23+
```
24+
25+
**Return Value**
26+
27+
The version information string.
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
---
2+
layout: default-layout
3+
title: CCodeParser Class - Dynamsoft Code Parser SDK Android Edition API Reference
4+
description: This page shows CCodeParser Class of Dynamsoft Code Parser SDK Android Edition.
5+
keywords: CCodeParser, api reference, Android
6+
needAutoGenerateSidebar: true
7+
---
8+
9+
# CodeParser Class
10+
11+
```java
12+
class CodeParser
13+
```
14+
15+
| Method | Description |
16+
| ------ | ----------- |
17+
| [`CodeParser`](#codeparser) | The constructor.|
18+
| [`initSettingsFromFile`](#initsettingsfromfile) | Initialize runtime settings with the settings in a given JSON file. |
19+
| [`initSettings`](#initsettings) | Initialize runtime settings with the settings in a given JSON string. |
20+
| [`parse`](#parse) | Parses code data for readable results. |
21+
| [`resetSettings`](#resetsettings) | Reset runtime settings to default. |
22+
23+
## CodeParser
24+
25+
Default constructor of a `CodeParser` object.
26+
27+
```java
28+
CodeParser();
29+
```
30+
31+
## Parse
32+
33+
Parses code data for human-readable results.
34+
35+
```java
36+
ParsedResultItem parse(byte[] bytes, String taskSettingName) throws CodeParserException;
37+
```
38+
39+
**Parameters**
40+
41+
`[in] bytes` The array of bytes which contain the code string.
42+
43+
`[in] taskSettingName`<sub>Optional</sub> The name of [`CodeParserTaskSetting`]({{site.parameters}}file/task-settings/code-parser-task-settings.html) which defines the settings used for code parsing.
44+
45+
**Return Value**
46+
47+
Returns [`ParsedResultItem`](parsed-result-item.md) which stores the human-readable results.
48+
49+
## ResetSettings
50+
51+
Reset all parameters to default values.
52+
53+
```java
54+
void resetSettings();
55+
```
56+
57+
## InitSettingsFromFile
58+
59+
Initialize settings from a given file.
60+
61+
```java
62+
void initSettingsFromFile(String filePath) throws CodeParserException;
63+
```
64+
65+
**Parameters**
66+
67+
`[in] filePath` The path of the settings file.
68+
69+
## InitSettings
70+
71+
Initialize settings from a given string.
72+
73+
```java
74+
void initSettings(String content) throws CodeParserException;
75+
```
76+
77+
**Parameters**
78+
79+
`[in] content` A JSON string that represents the content of the settings.
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
layout: default-layout
3+
title: Main Page - Dynamsoft Code Parser SDK Android Edition API Reference
4+
description: This is the main page of Dynamsoft Code Parser SDK Android Edition API Reference.
5+
keywords: api reference, Android
6+
needAutoGenerateSidebar: true
7+
needGenerateH3Content: true
8+
---
9+
10+
# API Reference - Dynamsoft Code Parser SDK Android Edition
11+
12+
## Classes
13+
14+
* [`CodeParser`](code-parser.md)
15+
* [`LicenseManager`]({{ site.dcv_cpp_api }}license/license-manager.html)
16+
* [`ParsedResultItem`](parsed-result-item.md)
17+
18+
## Enumerations
19+
20+
* [`ErrorCode`]({{ site.enumerations }}core/error-code.html?lang=cpp)
21+
* [`MappingStatus`]({{ site.enumerations }}code-parser/mapping-status.html?lang=cpp)
22+
* [`ValidationStatus`]({{ site.enumerations }}code-parser/validation-status.html?lang=cpp)
Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
---
2+
layout: default-layout
3+
title: CParsedResultItem Class - Dynamsoft Code Parser SDK Android Edition API Reference
4+
description: This page shows CParsedResultItem Class of Dynamsoft Code Parser SDK Android Edition.
5+
keywords: CParsedResultItem, api reference, Android
6+
needAutoGenerateSidebar: true
7+
---
8+
9+
# ParsedResultItem Class
10+
11+
```java
12+
class ParsedResultItem extends CapturedResultItem
13+
```
14+
15+
| Method | Description |
16+
|----------------------|-------------|
17+
| [`getCodeType`](#getcodetype) | Gets the code type of the parsed result. |
18+
| [`getFieldMappingStatus`](#getfieldmappingstatus) | Gets the mapping status of a specified field from the parsed result. |
19+
| [`getFieldValidationStatus`](#getfieldvalidationstatus) | Gets the validation status of a specified field from the parsed result. |
20+
| [`getFieldValue`](#getfieldvalue) | Gets the value of a specified field from the parsed result. |
21+
| [`getJsonString`](#getjsonstring) | Gets the parsed result as a JSON formatted string. |
22+
23+
## getCodeType
24+
25+
Gets the code type of the parsed result.
26+
27+
```java
28+
String getCodeType();
29+
```
30+
31+
**Return Value**
32+
33+
Returns a string value representing the code type.
34+
35+
## getJsonString
36+
37+
Gets the parsed result as a JSON formatted string.
38+
39+
```java
40+
String getJsonString();
41+
```
42+
43+
**Return Value**
44+
45+
Returns a JSON formatted string representing the parsed result.
46+
47+
## getFieldValue
48+
49+
Gets the value of a specified field from the parsed result.
50+
51+
```java
52+
String getFieldValue(String fieldName);
53+
```
54+
55+
**Parameters**
56+
57+
`[in] fieldName`: The name of the field.
58+
59+
**Return Value**
60+
61+
Returns a string representing the specified field value.
62+
63+
## getFieldMappingStatus
64+
65+
Gets the mapping status of a specified field from the parsed result.
66+
67+
```java
68+
EnumMappingStatus getFieldMappingStatus(String fieldName);
69+
```
70+
71+
**Parameters**
72+
73+
`[in] fieldName`: The name of the field.
74+
75+
**Return Value**
76+
77+
Returns a [MappingStatus]({{ site.enumerations }}code-parser/mapping-status.html?lang=android) enumeration value representing the mapping status of a specified field.
78+
79+
**See Also**
80+
81+
[MappingStatus]({{ site.enumerations }}code-parser/mapping-status.html?lang=android)
82+
83+
## getFieldValidationStatus
84+
85+
Gets the validation status of a specified field from the parsed result.
86+
87+
```java
88+
EnumValidationStatus getFieldValidationStatus(String fieldName);
89+
```
90+
91+
**Parameters**
92+
93+
`[in] fieldName`: The name of the field.
94+
95+
**Return Value**
96+
97+
Returns a [ValidationStatus]({{ site.enumerations }}code-parser/validation-status.html?lang=android) enumeration value representing the validation status of a specified field.
98+
99+
**See Also**
100+
101+
[ValidationStatus]({{ site.enumerations }}code-parser/validation-status.html?lang=android)
102+
103+
## getParsedFields
104+
105+
Get the field names and values of the parsed fields as a `HashMap`. The field names are stored as the key of the HashMap while the field values are stored as the value.
106+
107+
```java
108+
HashMap<String, String> getParsedFields();
109+
```
110+
111+
**Return Value**
112+
113+
A HashMap that contains the names and values of the parsed fields.
Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
---
2+
layout: default-layout
3+
title: ParsedResult Class - Dynamsoft Code Parser SDK Android Edition API Reference
4+
description: This page shows ParsedResult Class of Dynamsoft Code Parser SDK Android Edition.
5+
keywords: ParsedResult, api reference, Android
6+
needAutoGenerateSidebar: true
7+
---
8+
9+
10+
# ParsedResult Class
11+
12+
```java
13+
class ParsedResult
14+
```
15+
16+
| Method | Description |
17+
|----------------------|-------------|
18+
| [`getOriginalImageHashId`](#getoriginalimagehashid) | Gets the hash ID of the source image. |
19+
| [`getOriginalImageTag`](#getoriginalimagetag) | Gets the tag of the source image. |
20+
| [`getItems`](#getitems) | Gets the parsed result item at the specified index. |
21+
| [`getErrorCode`](#geterrorcode) | Gets the error code of the parsed result, if an error occurred. |
22+
| [`getErrorString`](#geterrormessage) | Gets the error message of the parsed result, if an error occurred. |
23+
24+
### getOriginalImageHashId
25+
26+
Gets the hash ID of the source image.
27+
28+
```java
29+
String getOriginalImageHashId();
30+
```
31+
32+
**Return value**
33+
34+
Returns a pointer to a null-terminated string containing the hash ID of the source image.
35+
36+
### getOriginalImageTag
37+
38+
Gets the tag of the source image.
39+
40+
```java
41+
ImageTag getOriginalImageTag();
42+
```
43+
44+
**Return value**
45+
46+
Returns a pointer to a CImageTag object representing the tag of the source image.
47+
48+
**See Also**
49+
50+
[ImageTag]({{ site.dcv_android_api }}core/basic-structures/image-tag.html)
51+
52+
### getItems
53+
54+
Gets the parsed result item at the specified index.
55+
56+
```java
57+
ParsedResultItem[] getItems();
58+
```
59+
60+
**Return value**
61+
62+
Returns an array of `ParsedResultItem`.
63+
64+
**See Also**
65+
66+
[ParsedResultItem]({{ site.dcp_android_api }}parsed-result-item.html)
67+
68+
### getErrorCode
69+
70+
Gets the error code of the parsed result, if an error occurred.
71+
72+
```java
73+
int getErrorCode();
74+
```
75+
76+
**Return value**
77+
78+
Returns the error code of the parsed result, or 0 if no error occurred.
79+
80+
### getErrorMessage
81+
82+
Gets the error message of the parsed result, if an error occurred.
83+
84+
```java
85+
String getErrorMessage();
86+
```
87+
88+
**Return value**
89+
90+
Returns a pointer to a null-terminated string containing the error message of the parsed result, or a pointer to an empty string if no error occurred.

programming/android/index.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
layout: default-layout
3+
title: Main Page - Dynamsoft Code Parser SDK Android Edition
4+
description: This is the main page of Dynamsoft Code Parser SDK Android Edition.
5+
keywords: Android
6+
needAutoGenerateSidebar: true
7+
needGenerateH3Content: true
8+
---
9+
10+
# Dynamsoft Code Parser Android Edition Documentation
11+
12+
## Getting Started
13+
14+
- [User Guide](user-guide/getting-started.md)
15+
16+
## API Reference
17+
18+
- [API Reference](api-reference/index.md)
19+
20+
## Release Notes
21+
22+
- [Version 2.x](release-notes/cpp-2.md)
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
layout: default-layout
3+
title: Release Notes v2.x - Dynamsoft Code Parser SDK Android Edition
4+
description: This is the release notes page of Dynamsoft Code Parser SDK Android Edition v2.x.
5+
keywords: release notes, Android
6+
needGenerateH3Content: false
7+
---
8+
9+
# Release Notes for Android Edition - 2.x
10+
11+
## 2.0.20 (10/26/2023)
12+
13+
{%- include release-notes/product-highlight-2.0.0.md -%}
14+
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
layout: default-layout
3+
title: Release Notes - Dynamsoft Code Parser SDK Android Edition
4+
description: This is the release notes page of Dynamsoft Code Parser SDK Android Edition.
5+
keywords: release notes, Android
6+
needAutoGenerateSidebar: false
7+
---
8+
9+
# Release Notes - Android Edition
10+
11+
- [2.0.20 (10/26/2023)](cpp-2.md#2020-10262023)
12+
- [2.0.10 (08/08/2023)](cpp-2.md#2010-08082023)
13+
- [2.0.0 (07/04/2023)](cpp-2.md#200-07042023)

0 commit comments

Comments
 (0)