Note
This API is still in beta and may change in future versions of Scandit Data Capture SDK.
Scanned Barcode
Defined in framework ScanditBarcodeCapture
- ScannedBarcode
class ScannedBarcode : NSObject, ScannedComponent
Added in version 8.0.0
A scanned barcode component in the item-based scanning APIs. This class represents a detected and decoded barcode with all its associated data and metadata.
ScannedBarcode implements the ScannedComponent protocol, providing a unique identifier and location information, along with barcode-specific properties such as symbology, payload data, and decoding metadata.
- definitionIdentifier
var definitionIdentifier: BarcodeIdentifier { get }
Added in version 8.1.0
The unique identifier for the definition of this barcode component.
- identifier
var identifier: ScannedComponentIdentifier { get }
Added in version 8.0.0
The unique identifier for this instance of the barcode component.
- location
var location: Quadrilateral { get }
Added in version 8.0.0
The location of the barcode as a quadrilateral.
- symbology
var symbology: Symbology { get }
Added in version 8.0.0
The symbology of the scanned barcode.
- payloadString
var payloadString: String? { get }
Added in version 8.0.0
The data of this barcode as a unicode string. May be null for barcodes containing non-printable characters, or characters that cannot be represented as unicode code points, or nul-bytes in the middle of the string
- PayloadData
var payloadData: Data { get }
Added in version 8.0.0
The raw data contained in the barcode. Use this property instead of payloadString when dealing with binary-encoded data.
- addOnPayloadString
var addOnPayloadString: String? { get }
Added in version 8.0.0
The add-on payload string if the barcode has an add-on. null if the barcode does not have an add-on.
- compositePayloadString
var compositePayloadString: String? { get }
Added in version 8.0.0
The composite payload string if the barcode is part of a composite barcode. null if the barcode is not composite.
- compositePayloadData
var compositePayloadData: Data? { get }
Added in version 8.0.0
The raw composite payload data if the barcode is part of a composite barcode. null if the barcode is not composite.
- encodingRanges
var encodingRanges: Array<EncodingRange> { get }
Added in version 8.0.0
Array of encoding ranges. Each entry of the returned encoding array points into bytes of PayloadData and indicates what encoding is used for these bytes. This information can then be used to convert the bytes to unicode, or other representations. For most codes, a single encoding range covers the whole data, but certain 2d symbologies, such as Symbology.qr allow to switch the encoding in the middle of the code.
- isGS1DataCarrier
var isGS1DataCarrier:
Bool{ get }Added in version 8.0.0
True for codes that carry GS1 data.
- compositeFlag
var compositeFlag: CompositeFlag { get }
Added in version 8.0.0
Flag to hint whether the barcode is part of a composite code.
- isColorInverted
var isColorInverted:
Bool{ get }Added in version 8.0.0
Whether the recognized code is color inverted (printed bright on dark background).
- symbolCount
var symbolCount:
Int32{ get }Added in version 8.0.0
The symbol count of this barcode.
- frameId
var frameId:
Int64{ get }Added in version 8.0.0
Id of the frame from which this barcode information was obtained.
- isStructuredAppend
var isStructuredAppend:
Bool{ get }Added in version 8.0.0
Whether the barcode is a structured append barcode.