aspose.barcode 20.12.7 → 21.3.7
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/lib/AsposeBarcode.js +1 -1
- package/lib/ComplexBarcode.js +2 -182
- package/lib/Generation.js +95 -168
- package/lib/Joint.js +1 -30
- package/lib/Recognition.js +43 -511
- package/lib/{aspose-barcode-nodejs-20.12.jar → aspose-barcode-nodejs-21.3.jar} +0 -0
- package/package.json +1 -1
package/lib/Joint.js
CHANGED
|
@@ -1,35 +1,6 @@
|
|
|
1
1
|
const java = require('java');
|
|
2
2
|
const fs = require("fs");
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
function isPath(image)
|
|
6
|
-
{
|
|
7
|
-
if (image.length < 256 && image.includes("/") || image.includes("\\"))
|
|
8
|
-
{
|
|
9
|
-
if (fs.existsSync(image))
|
|
10
|
-
{
|
|
11
|
-
return true;
|
|
12
|
-
}
|
|
13
|
-
throw new joint.BarcodeException("Path " + image + " does not exist");
|
|
14
|
-
}
|
|
15
|
-
return false;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
function convertResourceToBase64String(resource)
|
|
19
|
-
{
|
|
20
|
-
let is_path_to_image = false;
|
|
21
|
-
is_path_to_image = fs.existsSync(resource);
|
|
22
|
-
|
|
23
|
-
if (is_path_to_image)
|
|
24
|
-
{
|
|
25
|
-
return fs.readFileSync(resource).toString('base64');
|
|
26
|
-
}
|
|
27
|
-
else
|
|
28
|
-
{
|
|
29
|
-
return resource;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
|
|
33
4
|
class BaseJavaClass
|
|
34
5
|
{
|
|
35
6
|
javaClass;
|
|
@@ -435,5 +406,5 @@ class BuildVersionInfo
|
|
|
435
406
|
}
|
|
436
407
|
|
|
437
408
|
module.exports = {
|
|
438
|
-
BaseJavaClass, BarcodeException, Rectangle, Point, License, BuildVersionInfo
|
|
409
|
+
BaseJavaClass, BarcodeException, Rectangle, Point, License, BuildVersionInfo
|
|
439
410
|
};
|