Click or drag to resize
BarcodeScannerSession Class
Keeps track of decoded and localized barcodes and handles duplicate removal.
Inheritance Hierarchy
SystemObject
  Scandit.RecognitionBarcodeScannerSession

Namespace: Scandit.Recognition
Assembly: Scandit.Recognition (in Scandit.Recognition.dll) Version: 4.16.0.0 (4.16.0.0)
Syntax
public class BarcodeScannerSession : IDisposable

The BarcodeScannerSession type exposes the following members.

Methods
  NameDescription
Public methodClear
Remove all codes from the scan session.
Public methodDispose
Dispose the BarcodeScannerSession.
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetAllRecognizedCodes
Get all recognized codes
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetNewlyLocalizedCodes
Get codes localized but not recognized in the last processed frame.
Public methodGetNewlyRecognizedCodes
Get codes that were recognized in the last processed frame.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Remarks

Obtaining the barcode scanner session

The barcode scanner session can be obtained at any time from a barcode scanner object by accessing the Session property. The session contains the decoded as well as localized barcodes after the last call to ProcessFrame(ImageDescription, Byte).

Configuring Session Behaviour

The scan session is responsible for determining the list of relevant barcodes by filtering out duplicates. Depending on your app, different duplicate removal is required. For some applications, only one barcode is required. The scanning process is stopped as soon as one code is decoded. For other applications, multiple codes are scanned after another. For example, a scanner at the cash desk may need to scan multiple products. To avoid duplicates, the same barcode should not be scanned in short succession. The same barcode (data, symbology) should not count as a duplicate if encountered again after a few seconds.

By default, if a barcode has the same symbology and data as code that was decoded less than 500ms ago, it is filtered out as a duplicate. The exact filtering behaviour can be changed by setting the "code duplicate filter", and "code caching duration" in BarcodeScannerSettings.

See Also