5 // Created by Mayur Pawashe on 8/10/16.
6 // Copyright © 2016 Sparkle Project. All rights reserved.
9 #if __has_feature(modules)
12 #import <Foundation/Foundation.h>
17 NS_ASSUME_NONNULL_BEGIN
20 * A class for containing downloaded data along with some information about it.
22 SU_EXPORT @interface SPUDownloadData
: NSObject
<NSSecureCoding
>
24 - (instancetype
)initWithData
:(NSData
*)data textEncodingName
:(NSString
* _Nullable
)textEncodingName MIMEType
:(NSString
* _Nullable
)MIMEType
;
27 * The raw data that was downloaded.
29 @
property (nonatomic
, readonly
) NSData
*data
;
32 * The IANA charset encoding name if available. Eg: "utf-8"
34 @
property (nonatomic
, readonly
, nullable
, copy
) NSString
*textEncodingName
;
37 * The MIME type if available. Eg: "text/plain"
39 @
property (nonatomic
, readonly
, nullable
, copy
) NSString
*MIMEType
;