SBSDKUIBarcodesBatchScannerViewController
@interface SBSDKUIBarcodesBatchScannerViewController
: SBSDKUICameraViewController
A highly customizable camera-based view controller to detect barcodes batches.
-
Creates a new instance of ‘SBSDKUIBarcodesBatchScannerViewController’ and presents it modally.
Declaration
Objective-C
+ (nonnull instancetype) presentOn:(nonnull UIViewController *)presenter withAcceptedMachineCodeTypes: (nullable NSArray<SBSDKBarcodeType *> *)machineCodeTypes configuration: (nonnull SBSDKUIBarcodesBatchScannerConfiguration *) configuration andDelegate: (nullable id< SBSDKUIBarcodesBatchScannerViewControllerDelegate>) delegate;
Swift
class func present(on presenter: UIViewController, withAcceptedMachineCodeTypes machineCodeTypes: [SBSDKBarcodeType]?, configuration: SBSDKUIBarcodesBatchScannerConfiguration, andDelegate delegate: SBSDKUIBarcodesBatchScannerViewControllerDelegate?) -> Self
Parameters
presenter
The view controller the new instance should be presented on.
machineCodeTypes
The types of codes to be detected.
configuration
The configuration to define look and feel of the new detection view controller.
delegate
The delegate of the new detection view controller.
Return Value
A new instance of ‘SBSDKUIBarcodesBatchScannerViewController’.
-
Creates a new instance of ‘SBSDKUIBarcodesBatchScannerViewController’.
Declaration
Objective-C
+ (nonnull instancetype) createNewWithAcceptedMachineCodeTypes: (nullable NSArray<SBSDKBarcodeType *> *)machineCodeTypes configuration: (nonnull SBSDKUIBarcodesBatchScannerConfiguration *) configuration andDelegate: (nullable id< SBSDKUIBarcodesBatchScannerViewControllerDelegate>) delegate;
Swift
class func createNew(withAcceptedMachineCodeTypes machineCodeTypes: [SBSDKBarcodeType]?, configuration: SBSDKUIBarcodesBatchScannerConfiguration, andDelegate delegate: SBSDKUIBarcodesBatchScannerViewControllerDelegate?) -> Self
Parameters
machineCodeTypes
The types of codes to be detected.
configuration
The configuration to define look and feel of the new detection view controller.
delegate
The delegate of the new detection view controller.
Return Value
A new instance of ‘SBSDKUIBarcodesBatchScannerViewController’.
-
Creates a new instance of ‘SBSDKUIBarcodesBatchScannerViewController’ and presents it modally.
Declaration
Objective-C
+ (nonnull instancetype) presentOn:(nonnull UIViewController *)presenter withAcceptedMachineCodeTypes: (nullable NSArray<SBSDKBarcodeType *> *)machineCodeTypes withAcceptedDocumentTypes: (nullable NSArray<SBSDKBarcodeDocumentType *> *)documentTypes configuration: (nonnull SBSDKUIBarcodesBatchScannerConfiguration *) configuration andDelegate: (nullable id< SBSDKUIBarcodesBatchScannerViewControllerDelegate>) delegate;
Swift
class func present(on presenter: UIViewController, withAcceptedMachineCodeTypes machineCodeTypes: [SBSDKBarcodeType]?, withAcceptedDocumentTypes documentTypes: [SBSDKBarcodeDocumentType]?, configuration: SBSDKUIBarcodesBatchScannerConfiguration, andDelegate delegate: SBSDKUIBarcodesBatchScannerViewControllerDelegate?) -> Self
Parameters
presenter
The view controller the new instance should be presented on.
machineCodeTypes
The types of codes to be detected.
documentTypes
The types of code documents to be detected.
configuration
The configuration to define look and feel of the new detection view controller.
delegate
The delegate of the new detection view controller.
Return Value
A new instance of ‘SBSDKUIBarcodesBatchScannerViewController’.
-
Creates a new instance of ‘SBSDKUIBarcodesBatchScannerViewController’.
Declaration
Objective-C
+ (nonnull instancetype) createNewWithAcceptedMachineCodeTypes: (nullable NSArray<SBSDKBarcodeType *> *)machineCodeTypes withAcceptedDocumentTypes: (nullable NSArray<SBSDKBarcodeDocumentType *> *) documentTypes configuration: (nonnull SBSDKUIBarcodesBatchScannerConfiguration *) configuration andDelegate: (nullable id< SBSDKUIBarcodesBatchScannerViewControllerDelegate>) delegate;
Swift
class func createNew(withAcceptedMachineCodeTypes machineCodeTypes: [SBSDKBarcodeType]?, withAcceptedDocumentTypes documentTypes: [SBSDKBarcodeDocumentType]?, configuration: SBSDKUIBarcodesBatchScannerConfiguration, andDelegate delegate: SBSDKUIBarcodesBatchScannerViewControllerDelegate?) -> Self
Parameters
machineCodeTypes
The types of codes to be detected.
documentTypes
The types of code documents to be detected.
configuration
The configuration to define look and feel of the new detection view controller.
delegate
The delegate of the new detection view controller.
Return Value
A new instance of ‘SBSDKUIBarcodesBatchScannerViewController’.
-
Enables or disables the barcode detection.
Declaration
Objective-C
@property (nonatomic, assign, unsafe_unretained, readwrite, getter=isRecognitionEnabled) BOOL recognitionEnabled;
Swift
var isRecognitionEnabled: Bool { get set }
-
The receivers delegate.
Declaration
Objective-C
@property (nonatomic, weak, nullable) id<SBSDKUIBarcodesBatchScannerViewControllerDelegate> delegate;
Swift
weak var delegate: SBSDKUIBarcodesBatchScannerViewControllerDelegate? { get set }
-
The mapper object, that conforms to the
SBSDKUIBarcodesBatchScannerMapping
protocol. Used to get additional info for barcodes. Does not hold strong reference to the object. Can be nil.Declaration
Objective-C
@property (nonatomic, weak, nullable) id<SBSDKUIBarcodesBatchScannerMapping> dataMapper;
Swift
weak var dataMapper: SBSDKUIBarcodesBatchScannerMapping? { get set }