aspose.barcode 21.8.5 → 21.9.5

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.
@@ -7,7 +7,7 @@ const recognition_ = require("./Recognition");
7
7
 
8
8
  function pushJar()
9
9
  {
10
- java.classpath.push(__dirname + "/aspose-barcode-nodejs-21.8.jar");
10
+ java.classpath.push(__dirname + "/aspose-barcode-nodejs-21.9.jar");
11
11
  }
12
12
  pushJar();
13
13
 
@@ -16,9 +16,8 @@ const joint = require("./Joint");
16
16
  class BarCodeReader extends joint.BaseJavaClass
17
17
  {
18
18
  qualitySettings;
19
- barcodeRegion;
20
- code128DataPortions;
21
19
  recognizedResults;
20
+ barcodeSettings;
22
21
 
23
22
  static get javaClassName()
24
23
  {
@@ -68,7 +67,11 @@ class BarCodeReader extends joint.BaseJavaClass
68
67
  try
69
68
  {
70
69
  let java_class_link = new java.import(BarCodeReader.javaClassName);
71
- let java_class = new java_class_link(image, rectangles, decodeTypes);
70
+ let java_class = null;
71
+ if(image == null && rectangles == null && image == null)
72
+ java_class = new java_class_link();
73
+ else
74
+ java_class = new java_class_link(image, rectangles, decodeTypes);
72
75
  super(java_class);
73
76
  this.init()
74
77
  } catch (e)
@@ -78,6 +81,13 @@ class BarCodeReader extends joint.BaseJavaClass
78
81
  }
79
82
  }
80
83
 
84
+ static construct(javaClass)
85
+ {
86
+ let barcodeReader = new BarCodeReader(null, null, null);
87
+ barcodeReader.setJavaClass(javaClass);
88
+ return barcodeReader;
89
+ }
90
+
81
91
  static isPath(image)
82
92
  {
83
93
  if (image.length < 256 && image.includes("/") || image.includes("\\"))
@@ -152,6 +162,7 @@ class BarCodeReader extends joint.BaseJavaClass
152
162
  init()
153
163
  {
154
164
  this.qualitySettings = new QualitySettings(this.getJavaClass().getQualitySettingsSync());
165
+ this.barcodeSettings = BarcodeSettings.construct(this.getJavaClass().getBarcodeSettingsSync());
155
166
  }
156
167
 
157
168
  /**
@@ -387,13 +398,24 @@ class BarCodeReader extends joint.BaseJavaClass
387
398
  */
388
399
  readBarCodes()
389
400
  {
390
- this.recognizedResults = [];
391
- let javaReadBarcodes = this.getJavaClass().readBarCodesSync();
392
- for (let i = 0; i < javaReadBarcodes.length; i++)
401
+ try
393
402
  {
394
- this.recognizedResults[i] = new BarCodeResult(javaReadBarcodes[i]);
403
+ this.recognizedResults = [];
404
+ let javaReadBarcodes = this.getJavaClass().readBarCodesSync();
405
+ for (let i = 0; i < javaReadBarcodes.length; i++)
406
+ {
407
+ this.recognizedResults[i] = new BarCodeResult(javaReadBarcodes[i]);
408
+ }
409
+ return this.recognizedResults;
410
+ }
411
+ catch (e)
412
+ {
413
+ if((e.toString().includes("RecognitionAbortedException")))
414
+ {
415
+ throw new RecognitionAbortedException(e.toString(), null);
416
+ }
417
+ throw e;
395
418
  }
396
- return this.recognizedResults;
397
419
  }
398
420
 
399
421
  /**
@@ -474,6 +496,15 @@ class BarCodeReader extends joint.BaseJavaClass
474
496
  this.getJavaClass().setQualitySettingsSync(value.getJavaClass());
475
497
  }
476
498
 
499
+ /**
500
+ * The main BarCode decoding parameters. Contains parameters which make influence on recognized data.
501
+ * @return The main BarCode decoding parameters
502
+ */
503
+ getBarcodeSettings()
504
+ {
505
+ return this.barcodeSettings;
506
+ }
507
+
477
508
  /**
478
509
  * A flag which force engine to detect codetext encoding for Unicode codesets.
479
510
  * @example
@@ -619,7 +650,39 @@ class BarCodeReader extends joint.BaseJavaClass
619
650
  */
620
651
  exportToXml(xmlFile)
621
652
  {
622
- return this.getJavaClass().exportToXmlSync(xmlFile);
653
+ try
654
+ {
655
+ let xmlData = this.getJavaClass().exportToXmlSync();
656
+ let isSaved = xmlData != null;
657
+ if(isSaved)
658
+ fs.writeFileSync(xmlFile, xmlData);
659
+ return isSaved;
660
+ }
661
+ catch (ex)
662
+ {
663
+ let barcode_exception = new joint.BarcodeException(ex);
664
+ throw barcode_exception;
665
+ }
666
+ }
667
+
668
+ /**
669
+ * Exports BarCode properties to the xml-file specified
670
+ * @param xmlFile The name for the file
671
+ * @return Whether or not export completed successfully. Returns True in case of success; False Otherwise
672
+ */
673
+ static importFromXml(xmlFile)
674
+ {
675
+ try
676
+ {
677
+ let xmlData = fs.readFileSync(xmlFile).toString();
678
+ let java_class_link = new java.import(BarCodeReader.javaClassName);
679
+ return BarCodeReader.construct(java_class_link.importFromXmlSync(xmlData.substring(3, xmlData.length)));
680
+ }
681
+ catch (ex)
682
+ {
683
+ let barcode_exception = new joint.BarcodeException(ex);
684
+ throw barcode_exception;
685
+ }
623
686
  }
624
687
  }
625
688
 
@@ -2105,7 +2168,7 @@ class QualitySettings extends joint.BaseJavaClass
2105
2168
 
2106
2169
  /**
2107
2170
  * Allows engine to recognize 1D barcodes with checksum by checking more recognition variants. Default value: False.
2108
- * @param $value If True, allows engine to recognize 1D barcodes with checksum.
2171
+ * @param value If True, allows engine to recognize 1D barcodes with checksum.
2109
2172
  */
2110
2173
  setCheckMore1DVariants(value)
2111
2174
  {
@@ -2582,6 +2645,374 @@ class DataBarExtendedParameters extends joint.BaseJavaClass
2582
2645
  }
2583
2646
  }
2584
2647
 
2648
+ /**
2649
+ * AustraliaPost decoding parameters. Contains parameters which make influence on recognized data of AustraliaPost symbology.
2650
+ */
2651
+ class AustraliaPostSettings extends joint.BaseJavaClass
2652
+ {
2653
+ static get javaClassName()
2654
+ {
2655
+ return "com.aspose.mw.barcode.recognition.MwAustraliaPostSettings";
2656
+ }
2657
+
2658
+ init()
2659
+ {
2660
+ }
2661
+
2662
+ /**
2663
+ * AustraliaPostSettings constructor
2664
+ */
2665
+ constructor(settings)
2666
+ {
2667
+ if (settings != null)
2668
+ {
2669
+ super(settings.getJavaClass());
2670
+ } else
2671
+ {
2672
+ let java_link = java.import(AustraliaPostSettings.javaClassName);
2673
+ let australiaPostSettings = new java_link();
2674
+ super(australiaPostSettings);
2675
+ }
2676
+ }
2677
+
2678
+ static construct(javaClass)
2679
+ {
2680
+ let australiaPostSettings = new AustraliaPostSettings(null);
2681
+ australiaPostSettings.setJavaClass(javaClass);
2682
+ return australiaPostSettings;
2683
+ }
2684
+
2685
+ /**
2686
+ * Gets or sets the Interpreting Type for the Customer Information of AustralianPost BarCode.DEFAULT is CustomerInformationInterpretingType.OTHER.
2687
+ * @return The interpreting type (CTable, NTable or Other) of customer information for AustralianPost BarCode
2688
+ */
2689
+ getCustomerInformationInterpretingType()
2690
+ {
2691
+ return this.getJavaClass().getCustomerInformationInterpretingTypeSync();
2692
+ }
2693
+
2694
+ /**
2695
+ * Gets or sets the Interpreting Type for the Customer Information of AustralianPost BarCode.DEFAULT is CustomerInformationInterpretingType.OTHER.
2696
+ * @param value The interpreting type (CTable, NTable or Other) of customer information for AustralianPost BarCode
2697
+ */
2698
+ setCustomerInformationInterpretingType(value)
2699
+ {
2700
+ this.getJavaClass().setCustomerInformationInterpretingTypeSync(value);
2701
+ }
2702
+
2703
+ /**
2704
+ * The flag which force AustraliaPost decoder to ignore last filling patterns in Customer Information Field during decoding as CTable method.
2705
+ * CTable encoding method does not have any gaps in encoding table and sequnce "333" of filling paterns is decoded as letter "z".
2706
+ *
2707
+ * Example
2708
+ *
2709
+ * let generator = new BarcodeGenerator(EncodeTypes.AUSTRALIA_POST, "5912345678AB");
2710
+ * generator.getParameters().getBarcode().getAustralianPost().setAustralianPostEncodingTable(CustomerInformationInterpretingType.C_TABLE);
2711
+ * let image = generator.generateBarCodeImage(BarcodeImageFormat.PNG);
2712
+ * let reader = new BarCodeReader(image, null, DecodeType.AUSTRALIA_POST);
2713
+ * reader.getBarcodeSettings().getAustraliaPost().setCustomerInformationInterpretingType(CustomerInformationInterpretingType.C_TABLE);
2714
+ * reader.getBarcodeSettings().getAustraliaPost().setIgnoreEndingFillingPatternsForCTable(true);
2715
+ * reader.readBarCodes().forEach(function(result, i, results)
2716
+ * {
2717
+ * console.log("BarCode Type: ".result.getCodeType());
2718
+ * console.log("BarCode CodeText: ".result.getCodeText());
2719
+ * });
2720
+ *
2721
+ * @return The flag which force AustraliaPost decoder to ignore last filling patterns during CTable method decoding
2722
+ */
2723
+ getIgnoreEndingFillingPatternsForCTable()
2724
+ {
2725
+ return this.getJavaClass().getIgnoreEndingFillingPatternsForCTableSync();
2726
+ }
2727
+
2728
+ setIgnoreEndingFillingPatternsForCTable(value)
2729
+ {
2730
+ this.getJavaClass().setIgnoreEndingFillingPatternsForCTableSync(value);
2731
+ }
2732
+ }
2733
+
2734
+ class BarcodeSettings extends joint.BaseJavaClass
2735
+ {
2736
+
2737
+ _australiaPost;
2738
+
2739
+ static get javaClassName()
2740
+ {
2741
+ return "com.aspose.mw.barcode.recognition.MwBarcodeSettings";
2742
+ }
2743
+
2744
+ /**
2745
+ * BarcodeSettings copy constructor
2746
+ * @param settings The source of the data
2747
+ */
2748
+ constructor(settings)
2749
+ {
2750
+ if (settings != null)
2751
+ {
2752
+ super(settings.getJavaClass());
2753
+ } else
2754
+ {
2755
+ let java_link = java.import(BarcodeSettings.javaClassName);
2756
+ let barcodeSettings = new java_link();
2757
+ super(barcodeSettings);
2758
+ }
2759
+ }
2760
+
2761
+ /**
2762
+ * BarcodeSettings copy constructor
2763
+ * @param settings The source of the data
2764
+ */
2765
+ static construct(javaClass)
2766
+ {
2767
+ let barcodeSettings = new BarcodeSettings(null);
2768
+ barcodeSettings.setJavaClass(javaClass);
2769
+ return barcodeSettings;
2770
+ }
2771
+
2772
+ init()
2773
+ {
2774
+ this._australiaPost = AustraliaPostSettings.construct(this.getJavaClass().getAustraliaPostSync());
2775
+ }
2776
+
2777
+ /**
2778
+ * Enable checksum validation during recognition for 1D and Postal barcodes.
2779
+ * Default is treated as Yes for symbologies which must contain checksum, as No where checksum only possible.
2780
+ * Checksum never used: Codabar, PatchCode, Pharmacode, DataLogic2of5
2781
+ * Checksum is possible: Code39 Standard/Extended, Standard2of5, Interleaved2of5, ItalianPost25, Matrix2of5, MSI, ItalianPost25, DeutschePostIdentcode, DeutschePostLeitcode, VIN
2782
+ * Checksum always used: Rest symbologies
2783
+ *
2784
+ * Example
2785
+ *
2786
+ * let generator = new BarcodeGenerator(EncodeTypes.EAN_13, "1234567890128");
2787
+ * generator.save("c:/test.png", BarcodeImageFormat.PNG);
2788
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.EAN_13);
2789
+ * //checksum disabled
2790
+ * reader.getBarcodeSettings().setChecksumValidation(ChecksumValidation.OFF);
2791
+ * reader.readBarCodes().forEach(function(result, i, results)
2792
+ * {
2793
+ * console.log ("BarCode CodeText: ".result.getCodeText());
2794
+ * console.log ("BarCode Value: " + result.getExtended().getOneD().getValue());
2795
+ * console.log ("BarCode Checksum: " + result.getExtended().getOneD().getCheckSum());
2796
+ * });
2797
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.EAN_13);
2798
+ * //checksum enabled
2799
+ * reader.getBarcodeSettings().setChecksumValidation(ChecksumValidation.ON);
2800
+ * reader.readBarCodes().forEach(function(result, i, results)
2801
+ * {
2802
+ * console.log ("BarCode CodeText: " + result.CodeText);
2803
+ * console.log ("BarCode Value: " + result.getExtended().getOneD().getValue());
2804
+ * console.log ("BarCode Checksum: " + result.getExtended().getOneD().getCheckSum());
2805
+ * });
2806
+ * @return Enable checksum validation during recognition for 1D and Postal barcodes.
2807
+ */
2808
+ getChecksumValidation()
2809
+ {
2810
+ return this.getJavaClass().getChecksumValidationSync();
2811
+ }
2812
+
2813
+ /**
2814
+ * Enable checksum validation during recognition for 1D and Postal barcodes.
2815
+ * Default is treated as Yes for symbologies which must contain checksum, as No where checksum only possible.
2816
+ * Checksum never used: Codabar, PatchCode, Pharmacode, DataLogic2of5
2817
+ * Checksum is possible: Code39 Standard/Extended, Standard2of5, Interleaved2of5, ItalianPost25, Matrix2of5, MSI, ItalianPost25, DeutschePostIdentcode, DeutschePostLeitcode, VIN
2818
+ * Checksum always used: Rest symbologies
2819
+ *
2820
+ * Example
2821
+ *
2822
+ * let generator = new BarcodeGenerator(EncodeTypes.EAN_13, "1234567890128");
2823
+ * generator.save("c:/test.png", BarcodeImageFormat.PNG);
2824
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.EAN_13);
2825
+ * //checksum disabled
2826
+ * reader.getBarcodeSettings().setChecksumValidation(ChecksumValidation.OFF);
2827
+ * reader.readBarCodes().forEach(function(result, i, results)
2828
+ * {
2829
+ * console.log ("BarCode CodeText: ".result.getCodeText());
2830
+ * console.log ("BarCode Value: " + result.getExtended().getOneD().getValue());
2831
+ * console.log ("BarCode Checksum: " + result.getExtended().getOneD().getCheckSum());
2832
+ * });
2833
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.EAN_13);
2834
+ * //checksum enabled
2835
+ * reader.getBarcodeSettings().setChecksumValidation(ChecksumValidation.ON);
2836
+ * reader.readBarCodes().forEach(function(result, i, results)
2837
+ * {
2838
+ * console.log ("BarCode CodeText: " + result.CodeText);
2839
+ * console.log ("BarCode Value: " + result.getExtended().getOneD().getValue());
2840
+ * console.log ("BarCode Checksum: " + result.getExtended().getOneD().getCheckSum());
2841
+ * });
2842
+ * @param value Enable checksum validation during recognition for 1D and Postal barcodes.
2843
+ */
2844
+ setChecksumValidation(value)
2845
+ {
2846
+ this.getJavaClass().setChecksumValidationSync(value);
2847
+ }
2848
+
2849
+ /**
2850
+ * Strip FNC1, FNC2, FNC3 characters from codetext. Default value is false.
2851
+ *
2852
+ * Example
2853
+ *
2854
+ * let generator = new BarcodeGenerator(EncodeTypes.GS_1_CODE_128, "(02)04006664241007(37)1(400)7019590754");
2855
+ * generator.save("c:/test.png", BarcodeImageFormat.PNG);
2856
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.CODE_128);
2857
+ *
2858
+ * //StripFNC disabled
2859
+ * reader.getBarcodeSettings().setStripFNC(false);
2860
+ * reader.readBarCodes().forEach(function(result, i, results)
2861
+ * {
2862
+ * console.log ("BarCode CodeText: ".result.getCodeText());
2863
+ * });
2864
+ *
2865
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.CODE_128);
2866
+ *
2867
+ * //StripFNC enabled
2868
+ * reader.getBarcodeSettings().setStripFNC(true);
2869
+ * reader.readBarCodes().forEach(function(result, i, results)
2870
+ * {
2871
+ * console.log ("BarCode CodeText: ".result.getCodeText());
2872
+ * });
2873
+ *
2874
+ * @return Strip FNC1, FNC2, FNC3 characters from codetext. Default value is false.
2875
+ */
2876
+ getStripFNC()
2877
+ {
2878
+ return this.getJavaClass().getStripFNCSync();
2879
+ }
2880
+
2881
+ /**
2882
+ * Strip FNC1, FNC2, FNC3 characters from codetext. Default value is false.
2883
+ *
2884
+ * Example
2885
+ *
2886
+ * let generator = new BarcodeGenerator(EncodeTypes.GS_1_CODE_128, "(02)04006664241007(37)1(400)7019590754");
2887
+ * generator.save("c:/test.png", BarcodeImageFormat.PNG);
2888
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.CODE_128);
2889
+ *
2890
+ * //StripFNC disabled
2891
+ * reader.getBarcodeSettings().setStripFNC(false);
2892
+ * reader.readBarCodes().forEach(function(result, i, results)
2893
+ * {
2894
+ * console.log ("BarCode CodeText: ".result.getCodeText());
2895
+ * });
2896
+ *
2897
+ * let reader = new BarCodeReader("c:/test.png", DecodeType.CODE_128);
2898
+ *
2899
+ * //StripFNC enabled
2900
+ * reader.getBarcodeSettings().setStripFNC(true);
2901
+ * reader.readBarCodes().forEach(function(result, i, results)
2902
+ * {
2903
+ * console.log ("BarCode CodeText: ".result.getCodeText());
2904
+ * });
2905
+ *
2906
+ * @param value Strip FNC1, FNC2, FNC3 characters from codetext. Default value is false.
2907
+ */
2908
+ setStripFNC(value)
2909
+ {
2910
+ this.getJavaClass().setStripFNCSync(value);
2911
+ }
2912
+
2913
+ /**
2914
+ * The flag which force engine to detect codetext encoding for Unicode codesets. Default value is true.
2915
+ *
2916
+ * Example
2917
+ *
2918
+ * let generator = new BarcodeGenerator(EncodeTypes.QR, "Слово"))
2919
+ * $im = generator.generateBarcodeImage(BarcodeImageFormat.PNG);
2920
+ *
2921
+ * //detects encoding for Unicode codesets is enabled
2922
+ * let reader = new BarCodeReader(im, DecodeType.QR);
2923
+ * reader.getBarcodeSettings().setDetectEncoding(true);
2924
+ * reader.readBarCodes().forEach(function(result, i, results)
2925
+ * {
2926
+ * console.log ("BarCode CodeText: ".result.getCodeText());
2927
+ * });
2928
+ * //detect encoding is disabled
2929
+ * let reader = new BarCodeReader(im, DecodeType.QR);
2930
+ * reader.getBarcodeSettings().setDetectEncoding(false);
2931
+ * reader.readBarCodes().forEach(function(result, i, results)
2932
+ * console.log ("BarCode CodeText: " + result.getCodeText());
2933
+ *
2934
+ * @return The flag which force engine to detect codetext encoding for Unicode codesets
2935
+ */
2936
+ getDetectEncoding()
2937
+ {
2938
+ return this.getJavaClass().getDetectEncodingSync();
2939
+ }
2940
+
2941
+ setDetectEncoding(value)
2942
+ {
2943
+ this.getJavaClass().setDetectEncodingSync(value);
2944
+ }
2945
+
2946
+ /**
2947
+ * Gets AustraliaPost decoding parameters
2948
+ * @return The AustraliaPost decoding parameters which make influence on recognized data of AustraliaPost symbology
2949
+ */
2950
+ getAustraliaPost()
2951
+ {
2952
+ return this._australiaPost;
2953
+ }
2954
+ }
2955
+
2956
+ class RecognitionAbortedException extends Error
2957
+ {
2958
+ javaClass;
2959
+
2960
+ static get javaClassName()
2961
+ {
2962
+ return "com.aspose.mw.barcode.recognition.MwRecognitionAbortedException";
2963
+ }
2964
+ /**
2965
+ * Gets the execution time of current recognition session
2966
+ * @return The execution time of current recognition session
2967
+ */
2968
+ getExecutionTime()
2969
+ {
2970
+ return this.javaClass.getExecutionTimeSync();
2971
+ }
2972
+
2973
+ /**
2974
+ * Sets the execution time of current recognition session
2975
+ * @param value The execution time of current recognition session
2976
+ */
2977
+ setExecutionTime(value)
2978
+ {
2979
+ this.javaClass.setExecutionTimeSync(value);
2980
+ }
2981
+
2982
+ /**
2983
+ * Initializes a new instance of the <see cref="RecognitionAbortedException" /> class with specified recognition abort message.
2984
+ * @param message The error message of the exception.
2985
+ * @param executionTime The execution time of current recognition session.
2986
+ */
2987
+ constructor(message, executionTime)
2988
+ {
2989
+ super(message);
2990
+ let java_class_link = new java.import(RecognitionAbortedException.javaClassName);
2991
+ if(message != null && executionTime != null)
2992
+ {
2993
+ this.javaClass = new java_class_link(message, executionTime);
2994
+ }
2995
+ else if (executionTime != null)
2996
+ {
2997
+ this.javaClass = new java_class_link(executionTime);
2998
+ }
2999
+ else
3000
+ this.javaClass = new java_class_link();
3001
+ }
3002
+
3003
+ static construct(javaClass)
3004
+ {
3005
+ let exception = new RecognitionAbortedException(null, null);
3006
+ exception.javaClass = javaClass;
3007
+ return exception;
3008
+ }
3009
+
3010
+ init()
3011
+ {
3012
+
3013
+ }
3014
+ }
3015
+
2585
3016
  /**
2586
3017
  * Specify the type of barcode to read.
2587
3018
  * @example
@@ -3061,17 +3492,58 @@ Code128SubType =
3061
3492
  * @enum
3062
3493
  */
3063
3494
  CustomerInformationInterpretingType =
3064
- {
3495
+ {
3496
+
3065
3497
  /**
3066
3498
  * Use C_TABLE to interpret the customer information. Allows A..Z, a..z, 1..9, space and # sing.
3499
+ *
3500
+ * @code
3501
+ * let generator = new BarcodeGenerator(EncodeTypes.AUSTRALIA_POST, "5912345678ABCde");
3502
+ * generator.getParameters().getBarcode().getAustralianPost().setAustralianPostEncodingTable(CustomerInformationInterpretingType.C_TABLE);
3503
+ * let image = generator.generateBarcodeImage(BarcodeImageFormat.PNG);
3504
+ * let reader = new BarCodeReader(image, DecodeType.AUSTRALIA_POST);
3505
+ * reader.setCustomerInformationInterpretingType(CustomerInformationInterpretingType.C_TABLE);
3506
+ * reader.readBarCodes().forEach(function(result, i, results)
3507
+ * {
3508
+ * print("BarCode Type: " + result.getCodeType());
3509
+ * print("BarCode CodeText: " + result.getCodeText());
3510
+ * });
3511
+ * @endcode
3067
3512
  */
3068
3513
  C_TABLE: 0,
3514
+
3069
3515
  /**
3070
3516
  * Use N_TABLE to interpret the customer information. Allows digits.
3517
+ *
3518
+ * @code
3519
+ * let generator = new BarcodeGenerator(EncodeTypes.AUSTRALIA_POST, "59123456781234567");
3520
+ * generator.getParameters().getBarcode().getAustralianPost().setAustralianPostEncodingTable(CustomerInformationInterpretingType.N_TABLE);
3521
+ * let image = generator.generateBarcodeImage(BarcodeImageFormat.PNG);
3522
+ * let reader = new BarCodeReader(image, DecodeType.AUSTRALIA_POST);
3523
+ * reader.setCustomerInformationInterpretingType(CustomerInformationInterpretingType.N_TABLE);
3524
+ * reader.readBarCodes().forEach(function(result, i, results)
3525
+ * {
3526
+ * print("BarCode Type: " + result.getCodeType());
3527
+ * print("BarCode CodeText: " + result.getCodeText());
3528
+ * });
3529
+ * @endcode
3071
3530
  */
3072
3531
  N_TABLE: 1,
3073
3532
  /**
3074
3533
  * Do not interpret the customer information. Allows 0, 1, 2 or 3 symbol only.
3534
+ *
3535
+ * @code
3536
+ * let generator = new BarcodeGenerator(EncodeTypes.AUSTRALIA_POST, "59123456780123012301230123");
3537
+ * generator.getParameters().getBarcode().getAustralianPost().setAustralianPostEncodingTable(CustomerInformationInterpretingType.OTHER);
3538
+ * let image = generator.generateBarcodeImage(BarcodeImageFormat.PNG);
3539
+ * let reader = new BarCodeReader(image, DecodeType.AUSTRALIA_POST);
3540
+ * reader.setCustomerInformationInterpretingType(CustomerInformationInterpretingType.OTHER));
3541
+ * reader.readBarCodes().forEach(function(result, i, results)
3542
+ * {
3543
+ * print("BarCode Type: " + result.getCodeType());
3544
+ * print("BarCode CodeText: " + result.getCodeText());
3545
+ * });
3546
+ * @endcode
3075
3547
  */
3076
3548
  OTHER: 2,
3077
3549
  };
@@ -3143,6 +3615,8 @@ module.exports = {
3143
3615
  Code128SubType,
3144
3616
  Code128DataPortion,
3145
3617
  DataBarExtendedParameters,
3146
-
3147
- CustomerInformationInterpretingType
3618
+ AustraliaPostSettings,
3619
+ BarcodeSettings,
3620
+ CustomerInformationInterpretingType,
3621
+ RecognitionAbortedException
3148
3622
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aspose.barcode",
3
- "version": "21.8.5",
3
+ "version": "21.9.5",
4
4
  "description": "barcode generation and recognition component",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"