AI-generated Key Takeaways
-
BarcodeScannerOptionsallows you to configure barcode scanning behavior, such as specifying the desired barcode formats to detect. -
By default, the scanner is initialized to detect all supported barcode formats, but you can customize this using the
formatsproperty or during initialization. -
Initializing the scanner with specific formats can improve detection speed by limiting the search scope.
BarcodeScannerOptions
class BarcodeScannerOptions : NSObjectOptions for specifying a barcode scanner.
-
The barcode formats detected in an image. Note that the detection time will increase for each additional format that is specified.
Declaration
Swift
var formats: BarcodeFormat { get } -
Initializes an instance that scans all supported barcode formats.
Declaration
Swift
convenience init()Return Value
A new instance of barcode scanner options.
-
Initializes an instance with the given barcode formats to look for.
Declaration
Swift
init(formats: BarcodeFormat)Parameters
formatsThe barcode formats to initialize the barcode scanner options.
Return Value
A new instance of barcode scanner options.