]> git.saurik.com Git - apple/security.git/blob - OSX/sec/securityd/SecDbKeychainV7-protobufs/generated_source/SecDbKeychainSerializedItemV7.h
Security-59306.11.20.tar.gz
[apple/security.git] / OSX / sec / securityd / SecDbKeychainV7-protobufs / generated_source / SecDbKeychainSerializedItemV7.h
1 // This file was automatically generated by protocompiler
2 // DO NOT EDIT!
3 // Compiled from SecDbKeychainSerializedItemV7.proto
4
5 #import <Foundation/Foundation.h>
6 #import <ProtocolBuffer/PBCodable.h>
7
8 typedef NS_ENUM(int32_t, SecDbKeychainSerializedItemV7_Keyclass) {
9 SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AK = 6,
10 SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_CK = 7,
11 SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_DK = 8,
12 SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AKU = 9,
13 SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_CKU = 10,
14 SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_DKU = 11,
15 SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AKPU = 12,
16 };
17 #ifdef __OBJC__
18 NS_INLINE NSString *SecDbKeychainSerializedItemV7_KeyclassAsString(SecDbKeychainSerializedItemV7_Keyclass value)
19 {
20 switch (value)
21 {
22 case SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AK: return @"KEYCLASS_AK";
23 case SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_CK: return @"KEYCLASS_CK";
24 case SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_DK: return @"KEYCLASS_DK";
25 case SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AKU: return @"KEYCLASS_AKU";
26 case SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_CKU: return @"KEYCLASS_CKU";
27 case SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_DKU: return @"KEYCLASS_DKU";
28 case SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AKPU: return @"KEYCLASS_AKPU";
29 default: return [NSString stringWithFormat:@"(unknown: %i)", value];
30 }
31 }
32 #endif /* __OBJC__ */
33 #ifdef __OBJC__
34 NS_INLINE SecDbKeychainSerializedItemV7_Keyclass StringAsSecDbKeychainSerializedItemV7_Keyclass(NSString *value)
35 {
36 if ([value isEqualToString:@"KEYCLASS_AK"]) return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AK;
37 if ([value isEqualToString:@"KEYCLASS_CK"]) return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_CK;
38 if ([value isEqualToString:@"KEYCLASS_DK"]) return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_DK;
39 if ([value isEqualToString:@"KEYCLASS_AKU"]) return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AKU;
40 if ([value isEqualToString:@"KEYCLASS_CKU"]) return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_CKU;
41 if ([value isEqualToString:@"KEYCLASS_DKU"]) return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_DKU;
42 if ([value isEqualToString:@"KEYCLASS_AKPU"]) return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AKPU;
43 return SecDbKeychainSerializedItemV7_Keyclass_KEYCLASS_AK;
44 }
45 #endif /* __OBJC__ */
46
47 #ifdef __cplusplus
48 #define SECDBKEYCHAINSERIALIZEDITEMV7_FUNCTION extern "C"
49 #else
50 #define SECDBKEYCHAINSERIALIZEDITEMV7_FUNCTION extern
51 #endif
52
53 @interface SecDbKeychainSerializedItemV7 : PBCodable <NSCopying>
54 {
55 NSData *_encryptedMetadata;
56 NSData *_encryptedSecretData;
57 SecDbKeychainSerializedItemV7_Keyclass _keyclass;
58 }
59
60
61 @property (nonatomic, retain) NSData *encryptedSecretData;
62
63 @property (nonatomic, retain) NSData *encryptedMetadata;
64
65 @property (nonatomic) SecDbKeychainSerializedItemV7_Keyclass keyclass;
66 - (NSString *)keyclassAsString:(SecDbKeychainSerializedItemV7_Keyclass)value;
67 - (SecDbKeychainSerializedItemV7_Keyclass)StringAsKeyclass:(NSString *)str;
68
69 // Performs a shallow copy into other
70 - (void)copyTo:(SecDbKeychainSerializedItemV7 *)other;
71
72 // Performs a deep merge from other into self
73 // If set in other, singular values in self are replaced in self
74 // Singular composite values are recursively merged
75 // Repeated values from other are appended to repeated values in self
76 - (void)mergeFrom:(SecDbKeychainSerializedItemV7 *)other;
77
78 SECDBKEYCHAINSERIALIZEDITEMV7_FUNCTION BOOL SecDbKeychainSerializedItemV7ReadFrom(__unsafe_unretained SecDbKeychainSerializedItemV7 *self, __unsafe_unretained PBDataReader *reader);
79
80 @end
81