You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: SwiftTask/SwiftTask.swift
+33-1Lines changed: 33 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -127,7 +127,8 @@ public class Task<Progress, Value, Error>: _Task<Error>
127
127
128
128
///
129
129
/// Creates new task.
130
-
/// e.g. Task<P, V, E>(weakified: false) { progress, fulfill, reject, configure in ... }
130
+
///
131
+
/// - e.g. Task<P, V, E>(weakified: false) { progress, fulfill, reject, configure in ... }
131
132
///
132
133
/// :param: weakified Weakifies progress/fulfill/reject handlers to let player (inner asynchronous implementation inside initClosure) NOT CAPTURE this created new task. Normally, weakified = false should be set to gain "player -> task" retaining, so that task will be automatically deinited when player is deinited. If weakified = true, task must be manually retained somewhere else, or it will be immediately deinited.
133
134
///
@@ -364,6 +365,11 @@ public class Task<Progress, Value, Error>: _Task<Error>
364
365
return nextTask!
365
366
}
366
367
368
+
///
369
+
/// Add progress handler delivered from `initClosure`'s `progress()` argument.
370
+
///
371
+
/// - e.g. task.progress { oldProgress, newProgress in ... }
0 commit comments