DelayTask
public class DelayTask
Cancelable delayed task
-
Whether this task is canceled.
Declaration
Swift
public var isCanceled: Bool -
Whether this task has been executed.
Declaration
Swift
public private(set) var isExecuted: Bool -
Queue the task will run
Declaration
Swift
public let queue: DispatchQueue -
Start the task.
Declaration
Swift
public func start() -
Chaining a new task.
Declaration
Swift
@discardableResult public func delay(_ delayedSeconds: TimeInterval, queue: DispatchQueue = .global(), task: @escaping () -> Void) -> DelayTaskParameters
delayedSecondsThe delayed seconds.
queueThe dispatch queue to run on.
taskThe closure to run.
DelayTask Class Reference