Note
This API is still in beta and may change in future versions of Scandit Data Capture SDK.
Scanned Item
Defined under the namespace Scandit.Datacapture.Barcode
- ScannedItem
class ScannedItemAdded in version 8.1.0
A scanned item in the item-based scanning APIs that represents a collection of related scan components. A scanned item can contain multiple barcode and text components that are logically grouped together.
This class provides access to all the individual ScannedComponent objects that make up the item, as well as convenient methods to retrieve specific components by their identifiers.
- identifier
get identifier(): ScannedItemIdentifier | null
Added in version 8.1.0
The unique identifier for this scanned item. May be null if the item doesn’t have a specific identifier.
- definitionIdentifier
get definitionIdentifier(): ScanItemIdentifier | null
Added in version 8.1.0
The unique identifier corresponding to the ScanItemDefinition for this item. May be null if item is located but not defined.
- components
get components(): ScannedComponent<
any>[]Added in version 8.1.0
An array of all scan components that make up this item. Components can be either ScannedBarcode or ScannedText objects.
- barcodeForIdentifier(identifier)
barcodeForIdentifier(identifier: BarcodeIdentifier): ScannedBarcode | null
Added in version 8.1.0
Retrieves a specific barcode component from this item by its identifier.
- Param BarcodeIdentifier identifier
The identifier associated with the barcode definition of the barcode component to retrieve.
- Returns
The ScannedBarcode with the given identifier, or null if no such barcode exists in this item.
- textForIdentifier(identifier)
textForIdentifier(identifier: TextIdentifier): ScannedText | null
Added in version 8.1.0
Retrieves a specific text component from this item by its identifier.
- Param TextIdentifier identifier
The identifier associated with the text definition of the text component to retrieve.
- Returns
The ScannedText with the given identifier, or null if no such text exists in this item.