123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153 |
- #import <Foundation/Foundation.h>
- #import "SDWebImageDownloader.h"
- #import "SDWebImageOperation.h"
- @protocol SDWebImageDownloaderOperation <NSURLSessionTaskDelegate, NSURLSessionDataDelegate>
- @required
- - (nonnull instancetype)initWithRequest:(nullable NSURLRequest *)request
- inSession:(nullable NSURLSession *)session
- options:(SDWebImageDownloaderOptions)options;
- - (nonnull instancetype)initWithRequest:(nullable NSURLRequest *)request
- inSession:(nullable NSURLSession *)session
- options:(SDWebImageDownloaderOptions)options
- context:(nullable SDWebImageContext *)context;
- - (nullable id)addHandlersForProgress:(nullable SDWebImageDownloaderProgressBlock)progressBlock
- completed:(nullable SDWebImageDownloaderCompletedBlock)completedBlock;
- - (BOOL)cancel:(nullable id)token;
- @property (strong, nonatomic, readonly, nullable) NSURLRequest *request;
- @property (strong, nonatomic, readonly, nullable) NSURLResponse *response;
- @optional
- @property (strong, nonatomic, readonly, nullable) NSURLSessionTask *dataTask;
- @property (strong, nonatomic, readonly, nullable) NSURLSessionTaskMetrics *metrics API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
- @property (strong, nonatomic, nullable) NSURLCredential *credential;
- @property (assign, nonatomic) double minimumProgressInterval;
- @end
- @interface SDWebImageDownloaderOperation : NSOperation <SDWebImageDownloaderOperation>
- @property (strong, nonatomic, readonly, nullable) NSURLRequest *request;
- @property (strong, nonatomic, readonly, nullable) NSURLResponse *response;
- @property (strong, nonatomic, readonly, nullable) NSURLSessionTask *dataTask;
- @property (strong, nonatomic, readonly, nullable) NSURLSessionTaskMetrics *metrics API_AVAILABLE(macosx(10.12), ios(10.0), watchos(3.0), tvos(10.0));
- @property (strong, nonatomic, nullable) NSURLCredential *credential;
- @property (assign, nonatomic) double minimumProgressInterval;
- @property (assign, nonatomic, readonly) SDWebImageDownloaderOptions options;
- @property (copy, nonatomic, readonly, nullable) SDWebImageContext *context;
- - (nonnull instancetype)initWithRequest:(nullable NSURLRequest *)request
- inSession:(nullable NSURLSession *)session
- options:(SDWebImageDownloaderOptions)options;
- - (nonnull instancetype)initWithRequest:(nullable NSURLRequest *)request
- inSession:(nullable NSURLSession *)session
- options:(SDWebImageDownloaderOptions)options
- context:(nullable SDWebImageContext *)context NS_DESIGNATED_INITIALIZER;
- - (nullable id)addHandlersForProgress:(nullable SDWebImageDownloaderProgressBlock)progressBlock
- completed:(nullable SDWebImageDownloaderCompletedBlock)completedBlock;
- - (BOOL)cancel:(nullable id)token;
- @end
|