NSData(Extensions) Category Reference
Declared in | NSData+Extensions.h |
---|
+ dataFromBase64String:
Creates an NSData
object by deserialising a base-64 string.
+ (nonnull NSData *)dataFromBase64String:(nonnull NSString *)aString
Parameters
aString |
The base-64 string to deserialise. |
---|
Return Value
The deserialised NSData
.
Discussion
Creates an NSData
object by deserialising a base-64 string.
Declared In
NSData+Extensions.h
+ dataFromBase64Data:
Creates an NSData
object by deserialising a base-64 NSData
object.
+ (nonnull NSData *)dataFromBase64Data:(nonnull NSData *)base64Data
Parameters
base64Data |
The base-64 data to deserialise. |
---|
Return Value
The deserialised NSData
.
Discussion
Creates an NSData
object by deserialising a base-64 NSData
object.
Declared In
NSData+Extensions.h
+ fromDispatchData:
Reads the data from a dispatch_data_t
into a new NSData
.
+ (nonnull NSData *)fromDispatchData:(nonnull dispatch_data_t)data
Parameters
data |
The |
---|
Return Value
The new NSData
.
Discussion
Reads the data from a dispatch_data_t
into a new NSData
.
Declared In
NSData+Extensions.h
– utf8StringValue
The UTF8 string representation of the contents of this NSData
.
- (nonnull NSString *)utf8StringValue
Discussion
The UTF8 string representation of the contents of this NSData
.
Declared In
NSData+Extensions.h
– base64StringValue
The base-64 string representation of the contents of this NSData
.
- (nonnull NSString *)base64StringValue
Discussion
The base-64 string representation of the contents of this NSData
.
Declared In
NSData+Extensions.h
– md5StringValue
An MD5 hash of the contents of this NSData
.
- (nonnull NSString *)md5StringValue
Discussion
An MD5 hash of the contents of this NSData
.
Declared In
NSData+Extensions.h
– gzipInflate
Unzips the data in this NSData
using the GZip algorithm, returning the inflated data.
- (nullable NSData *)gzipInflate
Return Value
The new NSData
containing the unzipped (inflated) data.
Discussion
Unzips the data in this NSData
using the GZip algorithm, returning the inflated data.
Declared In
NSData+Extensions.h
– gzipDeflate
Zips the data in this NSData
using the GZip algorithm, returning the zipped (deflated) data.
- (nonnull NSData *)gzipDeflate
Return Value
The new NSData
containing the zipped (deflated) data.
Discussion
Zips the data in this NSData
using the GZip algorithm, returning the zipped (deflated) data.
Declared In
NSData+Extensions.h