RFSFaceSDK
Objective-C
@interface RFSFaceSDK : NSObject
Swift
class FaceSDK : NSObject
The entry point to the Face SDK features.
-
A shared instance of
RFSFaceSDK.Declaration
Objective-C
@property (class, nonatomic, strong, readonly, nonnull) RFSFaceSDK *service;Swift
class var service: FaceSDK { get } -
Undocumented
Declaration
Objective-C
@property(readonly, nonatomic, strong, nonnull) RFSPersonDatabase* personDatabaseSwift
var personDatabase: RFSPersonDatabase { get } -
An URL of your web service instance.
Declaration
Objective-C
@property (nonatomic, copy, nullable) NSString *serviceURL;Swift
var serviceURL: String? { get set } -
Defines customer name. Defaults to
nil.Declaration
Objective-C
@property (nonatomic, copy, nullable) NSString *tenant;Swift
var tenant: String? { get set } -
Defines environment type. Defaults to
nil.Declaration
Objective-C
@property (nonatomic, copy, nullable) NSString *env;Swift
var env: String? { get set } -
The Face SDK version.
Declaration
Objective-C
@property (nonatomic, strong, readonly, nullable) RFSFaceSDKVersion *version;Swift
var version: RFSFaceSDKVersion? { get } -
A localization hook to override default localization search logic. If this block is not set or the implementation of the block returns
nilthe default localization will be used.Declaration
Objective-C
@property (nonatomic, copy, nullable) NSString *_Nullable (^) (NSString *_Nonnull) localizationHandler;Swift
var localizationHandler: ((String) -> String?)? { get set } -
Delegate that responds to request intercepting events. Use the delegate to modify
URLRequestrequests before they are send to the web service.Declaration
Objective-C
@property (nonatomic, weak, nullable) id<RFSURLRequestInterceptingDelegate> requestInterceptingDelegate; -
Delegate that notifies about the face capture process events.
Declaration
Objective-C
@property (nonatomic, weak, nullable) id<RFSFaceCaptureDelegate> faceCaptureDelegate;Swift
weak var faceCaptureDelegate: FaceCaptureDelegate? { get set } -
Delegate that notifies about the liveness process events.
Declaration
Objective-C
@property (nonatomic, weak, nullable) id<RFSLivenessDelegate> livenessDelegate;Swift
weak var livenessDelegate: LivenessDelegate? { get set } -
Delegate that informs about the successfull upload of the video.
Declaration
Objective-C
@property (nonatomic, weak, nullable) id<RFSVideoUploadingDelegate> videoUploadingDelegate;Swift
weak var videoUploadingDelegate: VideoUploadingDelegate? { get set } -
Liveness and Face Capture view controller customization and etc.
Declaration
Objective-C
@property (nonatomic, strong, nonnull) RFSCustomization *customization;Swift
var customization: RFSCustomization { get set } -
Custom language locale code of FaceSDK. If empty or doesn’t exist - app language is used. Format “en-US” or “en”.
Declaration
Objective-C
@property (nonatomic, strong, nullable) NSString *languageLocaleCode;Swift
var languageLocaleCode: String? { get set } -
Method returns state of FaceSDK core. YES when FaceSDK core was initialized successfully.
Declaration
Objective-C
@property (nonatomic, readonly, getter=isInitialized) BOOL initialized;Swift
var isInitialized: Bool { get } -
Undocumented
Declaration
Objective-C
- (void)initializeWithCompletion:(RFSInitializationCompletion _Nonnull)completion NS_SWIFT_NAME(initialize(completion:));Swift
func initialize() async throws -> Bool -
Undocumented
Declaration
Objective-C
- (void)initializeWithConfiguration:(nullable RFSInitializationConfiguration *)configuration completion:(RFSInitializationCompletion _Nonnull)completion NS_SWIFT_NAME(initialize(configuration:completion:));Swift
func initialize(configuration: RFSInitializationConfiguration?) async throws -> Bool -
Processes given
RFSMatchFacesRequestand calls back thecompletionHandlerblock when finished.Declaration
Objective-C
- (void)matchFaces:(nonnull RFSMatchFacesRequest *)request completion:(void (^_Nonnull)(RFSMatchFacesResponse *_Nonnull)) completionHandler;Swift
func matchFaces(_ request: RFSMatchFacesRequest) async -> RFSMatchFacesResponseParameters
requestProcessing request.
completionHandlerCompletion block to call when request is finished processing.
-
Processes given
RFSMatchFacesRequestand calls back thecompletionHandlerblock when finished.Declaration
Objective-C
- (void)matchFaces:(nonnull RFSMatchFacesRequest *)request configuration:(nullable RFSMatchFacesConfiguration *)configuration completion:(void (^_Nonnull)(RFSMatchFacesResponse *_Nonnull)) completionHandler;Swift
func matchFaces(_ request: RFSMatchFacesRequest, configuration: RFSMatchFacesConfiguration?) async -> RFSMatchFacesResponseParameters
requestProcessing request.
configurationConfiguration object. Falls back to the default configuration when
nil.completionHandlerCompletion block to call when request is finished processing.
-
Presents a liveness view controller.
Declaration
Objective-C
- (void)startLivenessFrom:(nonnull UIViewController *)presenting animated:(BOOL)animated configuration:(nullable RFSLivenessConfiguration *)configuration onLiveness: (nullable void (^)(RFSLivenessResponse *_Nonnull))onLiveness completion:(nullable void (^)(void))completion;Swift
func startLiveness(from presenting: UIViewController, animated: Bool, configuration: RFSLivenessConfiguration?, onLiveness: ((RFSLivenessResponse) -> Void)?) asyncParameters
presentingThe
UIViewControllerthat will present the liveness view controller.animatedPass
trueto animate the presentation otherwise, passfalse.onLivenessLiveness response.
configurationConfiguration object. Falls back to the default configuration when
nil.completionPresentation transition completion block.
-
Presents a liveness view controller
Declaration
Objective-C
- (void)startLivenessFrom:(nonnull UIViewController *)presenting animated:(BOOL)animated onLiveness: (nullable void (^)(RFSLivenessResponse *_Nonnull))onLiveness completion:(nullable void (^)(void))completion;Swift
func startLiveness(from presenting: UIViewController, animated: Bool, onLiveness: ((RFSLivenessResponse) -> Void)?) asyncParameters
presentingThe
UIViewControllerthat will present the liveness view controller.animatedPass
trueto animate the presentation otherwise, passfalse.onLivenessCompletion block to call when the liveness is finished processing.
completionPresentation transition completion block.
-
Stops the liveness processing and closes the view controller.
Declaration
Objective-C
- (void)stopLivenessProcessing;Swift
func stopLivenessProcessing() -
Processes given
requestand calls back thecompletionHandlerblock when finished. Requires network connection.Declaration
Objective-C
- (void)detectFacesByRequest:(nonnull RFSDetectFacesRequest *)request completion:(nonnull void (^)( RFSDetectFacesResponse *_Nonnull))completion;Swift
func detectFaces(by request: RFSDetectFacesRequest) async -> RFSDetectFacesResponseParameters
requestProcessing request.
completionCompletion block to call when request is finished processing.
-
Presents face capturing view controller
Declaration
Objective-C
- (void) presentFaceCaptureViewControllerFrom:(nonnull UIViewController *)presenting animated:(BOOL)animated configuration: (nullable RFSFaceCaptureConfiguration *) configuration onCapture:(nullable void (^)( RFSFaceCaptureResponse *_Nonnull)) onCapture completion:(nullable void (^)(void))completion;Swift
func presentFaceCaptureViewController(from presenting: UIViewController, animated: Bool, configuration: RFSFaceCaptureConfiguration?, onCapture: ((RFSFaceCaptureResponse) -> Void)?) asyncParameters
presentingThe
UIViewControllerthat will present face capturing view controlleranimatedPass
trueto animate the presentation otherwise, passfalse.configurationConfiguration object. Falls back to the default configuration when
nil.onCaptureCompletion block to call when the face capture is finished processing.
completionPresentation transition completion block.
-
Presents a face capturing view controller
Declaration
Objective-C
- (void) presentFaceCaptureViewControllerFrom:(nonnull UIViewController *)presenting animated:(BOOL)animated onCapture:(nullable void (^)( RFSFaceCaptureResponse *_Nonnull)) onCapture completion:(nullable void (^)(void))completion;Swift
func presentFaceCaptureViewController(from presenting: UIViewController, animated: Bool, onCapture: ((RFSFaceCaptureResponse) -> Void)?) asyncParameters
presentingThe
UIViewControllerthat will present face capturing view controlleranimatedPass
trueto animate the presentation otherwise, passfalse.onCaptureCompletion block to call when the face capture is finished processing.
completionPresentation transition completion block.
-
Stops the face capturing and closes the view controller.
Declaration
Objective-C
- (void)stopFaceCaptureViewController;Swift
func stopFaceCaptureViewController() -
FaceSDK deinitialization.
Declaration
Objective-C
- (void)deinitialize;Swift
func deinitialize()