blob: c35322033f99db503863fce7b91e8413bc62dae2 [file] [log] [blame]
// Copyright 2013 The Flutter Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#import <Flutter/Flutter.h>
#import <LocalAuthentication/LocalAuthentication.h>
/**
* Protocol for a source of LAContext instances. Used to allow context injection in unit tests.
*/
@protocol FLAAuthContextFactory <NSObject>
- (LAContext *)createAuthContext;
@end
@interface FLTLocalAuthPlugin ()
/**
* Returns an instance that uses the given factory to create LAContexts.
*/
- (instancetype)initWithContextFactory:(NSObject<FLAAuthContextFactory> *)factory
NS_DESIGNATED_INITIALIZER;
@end