anyline-ocr-react-native-module 43.0.0 → 43.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.idea/modules.xml +8 -0
- package/.idea/plugin.iml +9 -0
- package/.idea/vcs.xml +6 -0
- package/android/.gradle/6.7/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/6.7/fileChanges/last-build.bin +0 -0
- package/android/.gradle/6.7/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/6.7/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/6.7/gc.properties +0 -0
- package/android/.gradle/7.0/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/7.0/dependencies-accessors/gc.properties +0 -0
- package/android/.gradle/7.0/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.0/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.0/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/7.0/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.0/gc.properties +0 -0
- package/android/.gradle/7.3/checksums/checksums.lock +0 -0
- package/android/.gradle/7.3/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/7.3/dependencies-accessors/gc.properties +0 -0
- package/android/.gradle/7.3/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.3/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.3/gc.properties +0 -0
- package/android/.gradle/7.4/checksums/checksums.lock +0 -0
- package/android/.gradle/7.4/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/7.4/checksums/sha1-checksums.bin +0 -0
- package/android/.gradle/7.4/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/7.4/dependencies-accessors/gc.properties +0 -0
- package/android/.gradle/7.4/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.4/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.4/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/7.4/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.4/fileHashes/resourceHashesCache.bin +0 -0
- package/android/.gradle/7.4/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
- package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/checksums/sha1-checksums.bin +0 -0
- package/android/.gradle/configuration-cache/gc.properties +0 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/.idea/compiler.xml +6 -0
- package/android/.idea/gradle.xml +19 -0
- package/android/.idea/jarRepositories.xml +40 -0
- package/android/.idea/misc.xml +10 -0
- package/android/.idea/vcs.xml +7 -0
- package/android/.settings/org.eclipse.buildship.core.prefs +13 -0
- package/android/local.properties +8 -0
- package/android/src/main/java/com/anyline/reactnative/AnylineSDKPlugin.java +16 -22
- package/package.json +8 -8
package/.idea/plugin.iml
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<module type="JAVA_MODULE" version="4">
|
|
3
|
+
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
|
4
|
+
<exclude-output />
|
|
5
|
+
<content url="file://$MODULE_DIR$" />
|
|
6
|
+
<orderEntry type="inheritedJdk" />
|
|
7
|
+
<orderEntry type="sourceFolder" forTests="false" />
|
|
8
|
+
</component>
|
|
9
|
+
</module>
|
package/.idea/vcs.xml
ADDED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
File without changes
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
Binary file
|
|
File without changes
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="GradleMigrationSettings" migrationVersion="1" />
|
|
4
|
+
<component name="GradleSettings">
|
|
5
|
+
<option name="linkedExternalProjectsSettings">
|
|
6
|
+
<GradleProjectSettings>
|
|
7
|
+
<option name="testRunner" value="GRADLE" />
|
|
8
|
+
<option name="distributionType" value="DEFAULT_WRAPPED" />
|
|
9
|
+
<option name="externalProjectPath" value="$PROJECT_DIR$" />
|
|
10
|
+
<option name="gradleJvm" value="Embedded JDK" />
|
|
11
|
+
<option name="modules">
|
|
12
|
+
<set>
|
|
13
|
+
<option value="$PROJECT_DIR$" />
|
|
14
|
+
</set>
|
|
15
|
+
</option>
|
|
16
|
+
</GradleProjectSettings>
|
|
17
|
+
</option>
|
|
18
|
+
</component>
|
|
19
|
+
</project>
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="RemoteRepositoriesConfiguration">
|
|
4
|
+
<remote-repository>
|
|
5
|
+
<option name="id" value="central" />
|
|
6
|
+
<option name="name" value="Maven Central repository" />
|
|
7
|
+
<option name="url" value="https://repo1.maven.org/maven2" />
|
|
8
|
+
</remote-repository>
|
|
9
|
+
<remote-repository>
|
|
10
|
+
<option name="id" value="jboss.community" />
|
|
11
|
+
<option name="name" value="JBoss Community repository" />
|
|
12
|
+
<option name="url" value="https://repository.jboss.org/nexus/content/repositories/public/" />
|
|
13
|
+
</remote-repository>
|
|
14
|
+
<remote-repository>
|
|
15
|
+
<option name="id" value="maven" />
|
|
16
|
+
<option name="name" value="maven" />
|
|
17
|
+
<option name="url" value="https://anylinesdk.blob.core.windows.net/testing/" />
|
|
18
|
+
</remote-repository>
|
|
19
|
+
<remote-repository>
|
|
20
|
+
<option name="id" value="BintrayJCenter" />
|
|
21
|
+
<option name="name" value="BintrayJCenter" />
|
|
22
|
+
<option name="url" value="https://jcenter.bintray.com/" />
|
|
23
|
+
</remote-repository>
|
|
24
|
+
<remote-repository>
|
|
25
|
+
<option name="id" value="Google" />
|
|
26
|
+
<option name="name" value="Google" />
|
|
27
|
+
<option name="url" value="https://dl.google.com/dl/android/maven2/" />
|
|
28
|
+
</remote-repository>
|
|
29
|
+
<remote-repository>
|
|
30
|
+
<option name="id" value="maven" />
|
|
31
|
+
<option name="name" value="maven" />
|
|
32
|
+
<option name="url" value="https://anylinesdk.blob.core.windows.net/maven/" />
|
|
33
|
+
</remote-repository>
|
|
34
|
+
<remote-repository>
|
|
35
|
+
<option name="id" value="MavenRepo" />
|
|
36
|
+
<option name="name" value="MavenRepo" />
|
|
37
|
+
<option name="url" value="https://repo.maven.apache.org/maven2/" />
|
|
38
|
+
</remote-repository>
|
|
39
|
+
</component>
|
|
40
|
+
</project>
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<project version="4">
|
|
3
|
+
<component name="ExternalStorageConfigurationManager" enabled="true" />
|
|
4
|
+
<component name="ProjectRootManager" version="2" languageLevel="JDK_11" default="true" project-jdk-name="11" project-jdk-type="JavaSDK">
|
|
5
|
+
<output url="file://$PROJECT_DIR$/build/classes" />
|
|
6
|
+
</component>
|
|
7
|
+
<component name="ProjectType">
|
|
8
|
+
<option name="id" value="Android" />
|
|
9
|
+
</component>
|
|
10
|
+
</project>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
arguments=
|
|
2
|
+
auto.sync=false
|
|
3
|
+
build.scans.enabled=false
|
|
4
|
+
connection.gradle.distribution=GRADLE_DISTRIBUTION(WRAPPER)
|
|
5
|
+
connection.project.dir=
|
|
6
|
+
eclipse.preferences.version=1
|
|
7
|
+
gradle.user.home=
|
|
8
|
+
java.home=/Library/Java/JavaVirtualMachines/jdk-15.jdk/Contents/Home
|
|
9
|
+
jvm.arguments=
|
|
10
|
+
offline.mode=false
|
|
11
|
+
override.workspace.settings=true
|
|
12
|
+
show.console.view=true
|
|
13
|
+
show.executions.view=true
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
## This file must *NOT* be checked into Version Control Systems,
|
|
2
|
+
# as it contains information specific to your local configuration.
|
|
3
|
+
#
|
|
4
|
+
# Location of the SDK. This is only used by Gradle.
|
|
5
|
+
# For customization when using a Version Control System, please read the
|
|
6
|
+
# header note.
|
|
7
|
+
#Wed Nov 16 08:15:22 CET 2022
|
|
8
|
+
sdk.dir=/Users/patrickfekete/Library/Android/sdk
|
|
@@ -94,6 +94,7 @@ class AnylineSDKPlugin extends ReactContextBaseJavaModule implements ResultRepor
|
|
|
94
94
|
}
|
|
95
95
|
} catch (JSONException e) {
|
|
96
96
|
e.printStackTrace();
|
|
97
|
+
returnError(e.getMessage());
|
|
97
98
|
}
|
|
98
99
|
}
|
|
99
100
|
|
|
@@ -103,6 +104,7 @@ class AnylineSDKPlugin extends ReactContextBaseJavaModule implements ResultRepor
|
|
|
103
104
|
AnylineSdk.init(license, reactContext);
|
|
104
105
|
} catch (LicenseException e) {
|
|
105
106
|
e.printStackTrace();
|
|
107
|
+
returnError(e.getMessage());
|
|
106
108
|
}
|
|
107
109
|
}
|
|
108
110
|
|
|
@@ -160,36 +162,34 @@ class AnylineSDKPlugin extends ReactContextBaseJavaModule implements ResultRepor
|
|
|
160
162
|
private void scanAnyline4() {
|
|
161
163
|
try {
|
|
162
164
|
configObject = new JSONObject(this.config);
|
|
163
|
-
// JSONObject options = configObject;
|
|
164
165
|
if (configObject != null) {
|
|
165
166
|
scan();
|
|
166
167
|
} else {
|
|
167
168
|
returnError("No ViewPlugin in config. Please check your configuration.");
|
|
168
169
|
}
|
|
170
|
+
} catch (LicenseException e) {
|
|
171
|
+
e.printStackTrace();
|
|
172
|
+
returnError("LICENSE ERROR: " + e.getMessage());
|
|
169
173
|
} catch (JSONException e) {
|
|
170
174
|
e.printStackTrace();
|
|
175
|
+
returnError("JSON ERROR: " + e.getMessage());
|
|
171
176
|
}
|
|
172
177
|
}
|
|
173
178
|
|
|
174
|
-
private void scan() {
|
|
179
|
+
private void scan() throws LicenseException, JSONException {
|
|
175
180
|
|
|
176
181
|
Intent intent = new Intent(getCurrentActivity(), ScanActivity.class);
|
|
177
182
|
|
|
178
|
-
|
|
179
|
-
configObject = new JSONObject(this.config);
|
|
180
|
-
|
|
181
|
-
license = configObject.get("license").toString();
|
|
182
|
-
JSONObject optionsJSONObject = configObject.optJSONObject("options");
|
|
183
|
+
configObject = new JSONObject(this.config);
|
|
183
184
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
EXTRA_ENABLE_BARCODE_SCANNING,
|
|
187
|
-
optionsJSONObject.optBoolean("nativeBarcodeEnabled", false)
|
|
188
|
-
);
|
|
189
|
-
}
|
|
185
|
+
license = configObject.get("license").toString();
|
|
186
|
+
JSONObject optionsJSONObject = configObject.optJSONObject("options");
|
|
190
187
|
|
|
191
|
-
|
|
192
|
-
|
|
188
|
+
if (optionsJSONObject != null) {
|
|
189
|
+
intent.putExtra(
|
|
190
|
+
EXTRA_ENABLE_BARCODE_SCANNING,
|
|
191
|
+
optionsJSONObject.optBoolean("nativeBarcodeEnabled", false)
|
|
192
|
+
);
|
|
193
193
|
}
|
|
194
194
|
|
|
195
195
|
intent.putExtra(EXTRA_LICENSE_KEY, license);
|
|
@@ -198,13 +198,7 @@ class AnylineSDKPlugin extends ReactContextBaseJavaModule implements ResultRepor
|
|
|
198
198
|
ResultReporter.setListener(this);
|
|
199
199
|
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
|
200
200
|
|
|
201
|
-
|
|
202
|
-
AnylineSdk.init(configObject.getString("license"), reactContext);
|
|
203
|
-
} catch (LicenseException e) {
|
|
204
|
-
e.printStackTrace();
|
|
205
|
-
} catch (JSONException e) {
|
|
206
|
-
e.printStackTrace();
|
|
207
|
-
}
|
|
201
|
+
AnylineSdk.init(configObject.getString("license"), reactContext);
|
|
208
202
|
reactContext.startActivityForResult(intent, 1111, intent.getExtras());
|
|
209
203
|
}
|
|
210
204
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"_from": "anyline-ocr-react-native-module@^43.0.
|
|
3
|
-
"_id": "anyline-ocr-react-native-module@^43.0.
|
|
2
|
+
"_from": "anyline-ocr-react-native-module@^43.0.1",
|
|
3
|
+
"_id": "anyline-ocr-react-native-module@^43.0.1",
|
|
4
4
|
"_inBundle": false,
|
|
5
5
|
"_integrity": "sha512-BGi9zNkSsoxXywDBIqzgBRvKUBniQOJHDKBrozZubKthZNRBAj8Ry5tW0Me0yLXt/fauME//hbC0wsenfPJZqw==",
|
|
6
6
|
"_location": "/anyline-ocr-react-native-module",
|
|
@@ -8,19 +8,19 @@
|
|
|
8
8
|
"_requested": {
|
|
9
9
|
"type": "range",
|
|
10
10
|
"registry": true,
|
|
11
|
-
"raw": "anyline-ocr-react-native-module@^43.0.
|
|
11
|
+
"raw": "anyline-ocr-react-native-module@^43.0.1",
|
|
12
12
|
"name": "anyline-ocr-react-native-module",
|
|
13
13
|
"escapedName": "anyline-ocr-react-native-module",
|
|
14
|
-
"rawSpec": "^43.0.
|
|
14
|
+
"rawSpec": "^43.0.1",
|
|
15
15
|
"saveSpec": null,
|
|
16
|
-
"fetchSpec": "^43.0.
|
|
16
|
+
"fetchSpec": "^43.0.1"
|
|
17
17
|
},
|
|
18
18
|
"_requiredBy": [
|
|
19
19
|
"/"
|
|
20
20
|
],
|
|
21
|
-
"_resolved": "https://registry.npmjs.org/anyline-ocr-react-native-module/-/anyline-ocr-react-native-module-43.0.
|
|
21
|
+
"_resolved": "https://registry.npmjs.org/anyline-ocr-react-native-module/-/anyline-ocr-react-native-module-43.0.1.tgz",
|
|
22
22
|
"_shasum": "bacbcd260cc662244f59393ed81a6edba009b52c",
|
|
23
|
-
"_spec": "anyline-ocr-react-native-module@^43.0.
|
|
23
|
+
"_spec": "anyline-ocr-react-native-module@^43.0.1",
|
|
24
24
|
"_where": "/Users/amiransari/Projects/anyline-ocr-react-native-module1/example/RNExampleApp",
|
|
25
25
|
"bugs": {
|
|
26
26
|
"url": "https://github.com/Anyline/anyline-ocr-react-native-module/issues"
|
|
@@ -47,5 +47,5 @@
|
|
|
47
47
|
"type": "git",
|
|
48
48
|
"url": "git+https://github.com/Anyline/anyline-ocr-react-native-module.git"
|
|
49
49
|
},
|
|
50
|
-
"version": "43.0.
|
|
50
|
+
"version": "43.0.1"
|
|
51
51
|
}
|