ALScanView Class Reference
| Inherits from | UIView |
|---|---|
| Declared in | ALScanView.h |
Overview
The visible component that manages the acquisition of image frames from the device, as well as user input, and passes them to the scan plugin for processing
– initWithFrame:scanViewPlugin:scanViewConfig:error:
Initializes an ALScanView object with a scan view plugin, and a scan view config object
- (_Nullable instancetype)initWithFrame:(CGRect)frame scanViewPlugin:(NSObject<ALScanViewPluginBase> *)scanViewPlugin scanViewConfig:(ALScanViewConfig *_Nullable)scanViewConfig error:(NSError *_Nullable *_Nullable)errorParameters
frame |
the frame of the scan view within the view hierarchy |
|---|---|
scanViewPlugin |
an |
scanViewConfig |
an optional |
error |
if error is encountered while initializing the ScanView object, this will be populated with the reasons for the failure |
Return Value
the ALScanView object
Declared In
ALScanView.h
– initWithFrame:scanViewPlugin:error:
Initializes an ALScanView object with a scan view plugin
- (_Nullable instancetype)initWithFrame:(CGRect)frame scanViewPlugin:(NSObject<ALScanViewPluginBase> *)scanViewPlugin error:(NSError *_Nullable *_Nullable)errorParameters
frame |
the frame of the scan view within the view hierarchy |
|---|---|
scanViewPlugin |
an |
error |
if error is encountered while initializing the ScanView object, this will be populated with the reasons for the failure |
Return Value
the ALScanView object
Declared In
ALScanView.h
– setScanViewPlugin:error:
Update a scan view with a different scan view plugin. The cutout and feedback layers will also be updated.
- (BOOL)setScanViewPlugin:(NSObject<ALScanViewPluginBase> *)scanViewPlugin error:(NSError *_Nullable *_Nullable)errorParameters
scanViewPlugin |
a different scan view plugin |
|---|---|
error |
if error is encountered while setting the ScanViewPlugin object, this will be populated with the reason for the failure |
Return Value
a boolean indicating whether or not the operation succeeded.
Declared In
ALScanView.h
delegate
The object to be notified of events reported by the scan view
@property (nonatomic, weak) id<ALScanViewDelegate> delegateDeclared In
ALScanView.h
scanViewPlugin
The scan view plugin instance
@property (nonatomic, readonly) NSObject<ALScanViewPluginBase> *scanViewPluginDeclared In
ALScanView.h
flashButtonFrame
The frame of the visible flash toggle button. The frame can be useful for some operations done on the UI layer
@property (nonatomic, readonly) CGRect flashButtonFrameDeclared In
ALScanView.h
scanViewConfig
The scan view config passed to this object during initialization
@property (nonatomic, readonly) ALScanViewConfig *scanViewConfigDeclared In
ALScanView.h
supportedNativeBarcodeFormats
Enable native barcode scanning by providing a list of valid barcode formats to use.
You may also set an empty array to scan all possible types (may impact performance),
or null to disable. In either case, do so before calling startCamera. This is by
default null.
@property (nonatomic, strong, nullable) NSArray<AVMetadataObjectType> *supportedNativeBarcodeFormatsDeclared In
ALScanView.h