ALScanViewConfig Class Reference

Inherits from NSObject
Conforms to ALJSONStringRepresentable
Declared in ALScanViewConfig.h

Overview

An object that configures the scan view. Holds the camera and flash configurations

  cameraConfig

Component object configuring the scan view camera

@property (nonatomic, readonly) ALCameraConfig *cameraConfig

Declared In

ALScanViewConfig.h

  flashConfig

Component object configuring the flash / torch module

@property (nonatomic, readonly) ALFlashConfig *flashConfig

Declared In

ALScanViewConfig.h

– initWithCameraConfig:flashConfig:

Initializes an ALScanViewConfig with the camera and flash configuration objects

- (instancetype)initWithCameraConfig:(ALCameraConfig *_Nullable)cameraConfig flashConfig:(ALFlashConfig *_Nullable)flashConfig

Parameters

cameraConfig

Component object configuring the scan view camera

flashConfig

Component object configuring the flash / torch module

Return Value

an instance of ALScanViewConfig

Declared In

ALScanViewConfig.h

– initWithJSONDictionary:error:

Initializes an ALScanViewConfig with a NSDictionary holding the configuration object in JSON

- (instancetype _Nullable)initWithJSONDictionary:(NSDictionary *)JSONDictionary error:(NSError *_Nullable *_Nullable)error

Parameters

JSONDictionary

the Dictionary containing the scan view config

error

will be set with the failure reason if initialization has failed

Return Value

an instance of ALScanViewConfig

Declared In

ALScanViewConfig.h

+ withJSONDictionary:

Creates an ALScanViewConfig with a NSDictionary holding the configuration object in JSON

+ (ALScanViewConfig *_Nullable)withJSONDictionary:(NSDictionary *)JSONDictionary

Parameters

JSONDictionary

the Dictionary containing the scan view config

Return Value

an instance of ALScanViewConfig

Declared In

ALScanViewConfig.h

+ defaultScanViewConfig

Creates an ALScanViewConfig with default values. Useful for further customization

+ (ALScanViewConfig *)defaultScanViewConfig

Return Value

an instance of ALScanViewConfig

Declared In

ALScanViewConfig.h

+ withCameraConfig:flashConfig:

Creates an ALScanViewConfig with the camera and flash configuration objects

+ (ALScanViewConfig *)withCameraConfig:(ALCameraConfig *_Nullable)cameraConfig flashConfig:(ALFlashConfig *_Nullable)flashConfig

Parameters

cameraConfig

Component object configuring the scan view camera

flashConfig

Component object configuring the flash / torch module

Return Value

an instance of ALScanViewConfig

Declared In

ALScanViewConfig.h