60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
* smaller than a single page!
*
* @param size The number of bytes of unswappable memory to preallocate
*/
+ (void)preallocateUnswappableMemoryWithSize: (size_t)size;
/**
* @brief Creates a new, autoreleased OFSecureData with count items of item
* size 1, all set to zero.
*
* @param count The number of zero items the OFSecureData should contain
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return A new, autoreleased OFSecureData
*/
+ (instancetype)dataWithCount: (size_t)count
allowsSwappableMemory: (bool)allowsSwappableMemory;
/**
* @brief Creates a new, autoreleased OFSecureData with count items of the
* specified item size, all set to zero.
*
* @param count The number of zero items the OFSecureData should contain
* @param itemSize The size of a single item in the OFSecureData in bytes
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return A new, autoreleased OFSecureData
|
|
|
|
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
* smaller than a single page!
*
* @param size The number of bytes of unswappable memory to preallocate
*/
+ (void)preallocateUnswappableMemoryWithSize: (size_t)size;
/**
* @brief Creates a new, autoreleased OFSecureData with `count` items of item
* size 1, all set to zero.
*
* @param count The number of zero items the OFSecureData should contain
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return A new, autoreleased OFSecureData
*/
+ (instancetype)dataWithCount: (size_t)count
allowsSwappableMemory: (bool)allowsSwappableMemory;
/**
* @brief Creates a new, autoreleased OFSecureData with `count` items of the
* specified item size, all set to zero.
*
* @param count The number of zero items the OFSecureData should contain
* @param itemSize The size of a single item in the OFSecureData in bytes
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return A new, autoreleased OFSecureData
|
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
|
+ (instancetype)dataWithContentsOfFile: (OFString *)path OF_UNAVAILABLE;
#endif
+ (instancetype)dataWithContentsOfURL: (OFURL *)URL OF_UNAVAILABLE;
+ (instancetype)dataWithStringRepresentation: (OFString *)string OF_UNAVAILABLE;
+ (instancetype)dataWithBase64EncodedString: (OFString *)string OF_UNAVAILABLE;
/**
* @brief Initializes an already allocated OFSecureData with count items of
* item size 1, all set to zero.
*
* @param count The number of zero items the OFSecureData should contain
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return An initialized OFSecureData
*/
- (instancetype)initWithCount: (size_t)count
allowsSwappableMemory: (bool)allowsSwappableMemory;
/**
* @brief Initializes an already allocated OFSecureData with count items of the
* specified item size, all set to zero.
*
* @param itemSize The size of a single item in the OFSecureData in bytes
* @param count The number of zero items the OFSecureData should contain
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return An initialized OFSecureData
*/
|
|
|
|
|
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
|
+ (instancetype)dataWithContentsOfFile: (OFString *)path OF_UNAVAILABLE;
#endif
+ (instancetype)dataWithContentsOfURL: (OFURL *)URL OF_UNAVAILABLE;
+ (instancetype)dataWithStringRepresentation: (OFString *)string OF_UNAVAILABLE;
+ (instancetype)dataWithBase64EncodedString: (OFString *)string OF_UNAVAILABLE;
/**
* @brief Initializes an already allocated OFSecureData with `count` items of
* item size 1, all set to zero.
*
* @param count The number of zero items the OFSecureData should contain
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return An initialized OFSecureData
*/
- (instancetype)initWithCount: (size_t)count
allowsSwappableMemory: (bool)allowsSwappableMemory;
/**
* @brief Initializes an already allocated OFSecureData with `count` items of
* the specified item size, all set to zero.
*
* @param itemSize The size of a single item in the OFSecureData in bytes
* @param count The number of zero items the OFSecureData should contain
* @param allowsSwappableMemory Whether the data may be stored in swappable
* memory
* @return An initialized OFSecureData
*/
|