Deprecation warning

Please note that this is outdated documentation for an older release of the Scandit Barcode Scanner SDK.

We are deprecating the 5.x API on all platforms (except Linux). Release 5.19 in April 2021 will be our final. Applications running 5.x will continue to work, and we will continue to release critical bug fixes and security patches only, for one year. We encourage you to migrate to 6.x and take advantage of our latest / advanced features and improved performance.

You'll find the updated documentation at: Data Capture SDK Documentation for iOS

SBSScanCase.h
Go to the documentation of this file.
1 //
2 // SBSScanCase.h
3 // ScanditBarcodeScanner
4 //
5 // Created by Luca Torella on 17/02/16.
6 // Copyright © 2016 Scandit AG. All rights reserved.
7 //
8 
9 #import <Foundation/Foundation.h>
10 #import <UIKit/UIKit.h>
11 
12 #import "SBSCommon.h"
13 #import "SBSScanCaseState.h"
14 
15 @class SBSScanCaseSettings;
16 @protocol SBSScanCaseDelegate;
17 
43 @interface SBSScanCase : NSObject
44 
54 @property (nonatomic, weak, readwrite, nullable) id<SBSScanCaseDelegate> delegate;
55 
69 @property (nonatomic, assign, readwrite) SBSScanCaseState state;
70 
83 @property (nonatomic, assign, readwrite) BOOL volumeButtonToScanEnabled;
84 
92 @property (nonatomic, assign, readwrite) NSTimeInterval activateDurationAfterVolumeButtonRelease;
93 
113 + (nonnull instancetype)acquireWithSettings:(nullable SBSScanCaseSettings *)settings delegate:(nullable id<SBSScanCaseDelegate>)delegate;
114 
132 - (nonnull instancetype)initWithSettings:(nullable SBSScanCaseSettings *)settings
133  delegate:(nullable id<SBSScanCaseDelegate>)delegate SBS_DESIGNATED_INITIALIZER;
134 
153 - (nonnull instancetype)initWithSettings:(nullable SBSScanCaseSettings *)settings;
154 
168 - (void)applySettings:(nonnull SBSScanCaseSettings *)settings
169  completionHandler:(nullable void (^)())completionHandler;
170 
191 - (void)setTimeout:(NSTimeInterval)timeout
192  fromState:(SBSScanCaseState)fromState
193  toState:(SBSScanCaseState)toState;
194 
213 - (void)setTimeout:(NSTimeInterval)timeout
214  tolerance:(NSTimeInterval)tolerance
215  fromState:(SBSScanCaseState)fromState
216  toState:(SBSScanCaseState)toState;
217 
227 - (void)removeTimeoutFromState:(SBSScanCaseState)fromState;
228 
236 @property (nonnull, nonatomic, readonly, strong) UIViewController *cameraPreview;
237 
247 @property (nonatomic, assign) BOOL scanBeepEnabled;
248 
258 @property (nonatomic, assign) BOOL errorSoundEnabled;
259 
273 - (BOOL)setScanSoundResource:(nonnull NSString *)path ofType:(nonnull NSString *)extension;
274 
291 - (BOOL)setErrorSoundResource:(nonnull NSString *)path ofType:(nonnull NSString *)extension;
292 
293 @end
id< SBSScanCaseDelegate > delegate
The delegate for this scan case.
Definition: SBSScanCase.h:54
SBSScanCaseState
Definition: SBSScanCaseState.h:18
Start a scanner for the Scandit case.
Definition: SBSScanCase.h:43
BOOL errorSoundEnabled
Whether to play an error sound when no code was scanned.
Definition: SBSScanCase.h:258
Holds settings that affect the recognition of barcodes (e.g. enabled barcode symbologies).
Definition: SBSScanCaseSettings.h:22
BOOL scanBeepEnabled
Whether to play a beep sound upon a successful scan.
Definition: SBSScanCase.h:247
Calls the Protocol for events fired by SBSScanCase, e.g. when new codes are scanned.
Definition: SBSScanCaseDelegate.h:25
NSTimeInterval activateDurationAfterVolumeButtonRelease
The duration in seconds for which the scanner should remain in active state after the volume button h...
Definition: SBSScanCase.h:92
BOOL volumeButtonToScanEnabled
Turn on/off scanning via the volume button.
Definition: SBSScanCase.h:83
SBSScanCaseState state
The state of the scan case.
Definition: SBSScanCase.h:69
UIViewController * cameraPreview
The camera preview.
Definition: SBSScanCase.h:236