RCDownloadItemDelegate Protocol Reference
Conforms to | NSObject |
---|---|
Declared in | RCDownloadItem.h |
– downloadItem:state:
required method
下载任务状态变化时调用
- (void)downloadItem:(RCDownloadItem *)item state:(RCDownloadItemState)state
Parameters
item |
下载任务对象 |
---|---|
state |
状态 |
Discussion
下载任务状态变化时调用
Declared In
RCDownloadItem.h
– downloadItem:progress:
required method
下载进度上报时调用
- (void)downloadItem:(RCDownloadItem *)item progress:(float)progress
Parameters
item |
下载任务 |
---|---|
progress |
下载进度 |
Discussion
下载进度上报时调用
Declared In
RCDownloadItem.h
– downloadItem:didCompleteWithError:filePath:
required method
任务结束时调用
- (void)downloadItem:(RCDownloadItem *)item didCompleteWithError:(NSError *)error filePath:(nullable NSString *)path
Parameters
item |
下载任务 |
---|---|
error |
错误信息对象,成功时为 nil |
path |
下载完成后文件的路径,此路径为相对路径,相对于沙盒根目录 NSHomeDirectory |
Discussion
任务结束时调用
Declared In
RCDownloadItem.h