VaultMobileSDK  18R3
iOS framework for Vault API
VEVVaultCrypt.h
Go to the documentation of this file.
1 
6 #import <Foundation/Foundation.h>
7 
8 NS_ASSUME_NONNULL_BEGIN
9 
16 typedef void (^VEVVaultCryptResultHandler)(NSError * _Nullable error);
17 
26 @interface VEVVaultCrypt : NSObject
27 
30 + (instancetype)sharedInstance;
31 
46 - (void)encryptFileAtPath:(NSString *)path
47  attributes:(nullable NSDictionary<NSString *,id> *)attributes
48  handler:(VEVVaultCryptResultHandler)handler;
49 
74 - (BOOL)createEncryptedFileAtPath:(NSString *)path
75  contents:(NSData *)contents
76  attributes:(nullable NSDictionary<NSString *,id> *)attributes
77  error:(NSError *_Nullable __autoreleasing *)error;
78 
90 - (nullable NSInputStream*)streamFromEncryptedFileAtPath:(NSString *)srcPath;
91 
114 - (nullable NSData*)decryptContentsAtPath:(NSString *)path
115  error:(NSError * _Nullable __autoreleasing *)error;
116 
117 @end
118 
119 NS_ASSUME_NONNULL_END
A singleton class that provides convenience methods for encrypting and decrypting locally stored file...
Definition: VEVVaultCrypt.h:26
instancetype sharedInstance()
Return the singleton instance.
void(^ VEVVaultCryptResultHandler)(NSError *_Nullable error)
The block type used to call back to the application after performing encryption or decryption...
Definition: VEVVaultCrypt.h:16