-
Notifications
You must be signed in to change notification settings - Fork 777
Get state and info
Jacksgong edited this page Apr 4, 2018
·
1 revision
Normally you can get state and info on DownloadListener
.
Status status = StatusUtil.getStatus(task)
status = StatusUtil.getStatus(url, parentPath, null);
status = StatusUtil.getStatus(url, parentPath, filename);
boolean isCompleted = StatusUtil.isCompleted(task);
isCompleted = StatusUtil.isCompleted(url, parentPath, null);
isCompleted = StatusUtil.isCompleted(url, parentPath, filename);
Status completedOrUnknown = StatusUtil.isCompletedOrUnknown(task);
// If you set tag, so just get tag
task.getTag();
task.getTag(xxx);
BreakpointInfo info = OkDownload.with().breakpointStore().get(it);
info = StatusUtil.getCurrentInfo(url, parentPath, null);
info = StatusUtil.getCurrentInfo(url, parentPath, filename);