Constructor
new BarCodeResult()
- Source:
Example
//This sample shows how to obtain BarCodeResult.
let generator = new BarcodeGenerator(EncodeTypes.Code128, "12345");
generator.save("test.png");
let reader = new BarCodeReader("test.png", null, [ DecodeType.CODE_39, DecodeType.CODE_128 ]);
reader.readBarCodes().forEach(function(result, i, results)
{
console.log("BarCode Type: " + result.getCodeTypeName());
console.log("BarCode CodeText: " + result.getCodeText());
console.log("BarCode Confidence: " + result.getConfidence());
console.log("BarCode ReadingQuality: " + result.getReadingQuality());
console.log("BarCode Angle: " + result.getRegion().getAngle());
});
Methods
deepClone()
Creates a copy of BarCodeResult class.
Returns:
Type | Description |
---|---|
Returns copy of BarCodeResult class. |
- Source:
equals(other)
Returns a value indicating whether this instance is equal to a specified BarCodeResult value.
Parameters:
Name | Type | Description |
---|---|---|
other |
An BarCodeResult value to compare to this instance. |
Returns:
Type | Description |
---|---|
true if obj has the same value as this instance; otherwise, false. |
- Source:
getCodeBytes()
Gets the encoded code bytes Value: The code bytes of the barcode
- Source:
getCodeText()
Gets the code text Value: The code text of the barcode
- Source:
getCodeType()
Gets the barcode type Value: The type information of the recognized barcode
- Source:
getCodeTypeName()
Gets the name of the barcode type Value: The type name of the recognized barcode
- Source:
getConfidence()
Gets recognition confidence level of the recognized barcode Value:
BarCodeConfidence.Strong does not have fakes or misrecognitions, BarCodeConfidence.Moderate
could sometimes have fakes or incorrect codetext because this confidence level for barcodews with weak cheksum or even without it,
BarCodeConfidence.NONE always has incorrect codetext and could be fake recognitions
BarCodeConfidence.Strong does not have fakes or misrecognitions, BarCodeConfidence.Moderate
could sometimes have fakes or incorrect codetext because this confidence level for barcodews with weak cheksum or even without it,
BarCodeConfidence.NONE always has incorrect codetext and could be fake recognitions
- Source:
getExtended()
Gets extended parameters of recognized barcode Value: The extended parameters of recognized barcode
- Source:
getReadingQuality()
Gets the reading quality. Works for 1D and postal barcodes. Value: The reading quality percent
- Source:
getRegion()
Gets the barcode region Value: The region of the recognized barcode
- Source:
hashCode()
Returns the hash code for this instance.
Returns:
Type | Description |
---|---|
A 32-bit signed integer hash code. |
- Source:
toString()
Returns a human-readable string representation of this BarCodeResult.
Returns:
Type | Description |
---|---|
A string that represents this BarCodeResult. |
- Source: