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 
70 @property (nonatomic, assign, readwrite) SBSScanCaseState state;
71 
84 @property (nonatomic, assign, readwrite) BOOL volumeButtonToScanEnabled;
85 
93 @property (nonatomic, assign, readwrite) NSTimeInterval activateDurationAfterVolumeButtonRelease;
94 
114 + (nonnull instancetype)acquireWithSettings:(nullable SBSScanCaseSettings *)settings delegate:(nullable id<SBSScanCaseDelegate>)delegate;
115 
133 - (nonnull instancetype)initWithSettings:(nullable SBSScanCaseSettings *)settings
134  delegate:(nullable id<SBSScanCaseDelegate>)delegate SBS_DESIGNATED_INITIALIZER;
135 
154 - (nonnull instancetype)initWithSettings:(nullable SBSScanCaseSettings *)settings;
155 
169 - (void)applySettings:(nonnull SBSScanCaseSettings *)settings
170  completionHandler:(nullable void (^)(void))completionHandler;
171 
192 - (void)setTimeout:(NSTimeInterval)timeout
193  fromState:(SBSScanCaseState)fromState
194  toState:(SBSScanCaseState)toState;
195 
214 - (void)setTimeout:(NSTimeInterval)timeout
215  tolerance:(NSTimeInterval)tolerance
216  fromState:(SBSScanCaseState)fromState
217  toState:(SBSScanCaseState)toState;
218 
228 - (void)removeTimeoutFromState:(SBSScanCaseState)fromState;
229 
237 @property (nonnull, nonatomic, readonly, strong) UIViewController *cameraPreview;
238 
248 @property (nonatomic, assign) BOOL scanBeepEnabled;
249 
259 @property (nonatomic, assign) BOOL errorSoundEnabled;
260 
274 - (BOOL)setScanSoundResource:(nonnull NSString *)path ofType:(nonnull NSString *)extension;
275 
292 - (BOOL)setErrorSoundResource:(nonnull NSString *)path ofType:(nonnull NSString *)extension;
293 
294 @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:259
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:248
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:93
BOOL volumeButtonToScanEnabled
Turn on/off scanning via the volume button.
Definition: SBSScanCase.h:84
SBSScanCaseState state
The state of the scan case.
Definition: SBSScanCase.h:70
UIViewController * cameraPreview
The camera preview.
Definition: SBSScanCase.h:237