]> git.saurik.com Git - apple/security.git/blame - keychain/ckks/CKKSProvideKeySetOperation.h
Security-59306.41.2.tar.gz
[apple/security.git] / keychain / ckks / CKKSProvideKeySetOperation.h
CommitLineData
b54c578e
A
1
2#if OCTAGON
3
4#import <Foundation/Foundation.h>
5
6#import "keychain/ckks/CKKSCurrentKeyPointer.h"
7#import "keychain/ckks/CKKSGroupOperation.h"
8
9NS_ASSUME_NONNULL_BEGIN
10
11@protocol CKKSKeySetContainerProtocol <NSObject>
12@property (readonly, nullable) CKKSCurrentKeySet* keyset;
13@end
14
15@protocol CKKSKeySetProviderOperationProtocol <NSObject, CKKSKeySetContainerProtocol>
16@property NSString* zoneName;
17- (void)provideKeySet:(CKKSCurrentKeySet*)keyset;
18@end
19
20// This is an odd operation:
21// If you call initWithZoneName:keySet: and then add the operation to a queue, it will finish immediately.
22// If you call initWithZoneName: and then add the operation to a queue, it will not start until provideKeySet runs.
23// But! -timeout: will work, and the operation will finish
24@interface CKKSProvideKeySetOperation : CKKSGroupOperation <CKKSKeySetProviderOperationProtocol>
25- (instancetype)initWithZoneName:(NSString*)zoneName;
26- (instancetype)initWithZoneName:(NSString*)zoneName keySet:(CKKSCurrentKeySet*)set;
27
28- (void)provideKeySet:(CKKSCurrentKeySet*)keyset;
29@end
30
31NS_ASSUME_NONNULL_END
32
33#endif