Task
public final class Task<Response>
Response execution context. Will be created by the library and could be used for obtaining
EventLoopFuture<Response>
of the execution or cancellation of the execution.
-
The
EventLoop
the delegate will be executed on.Declaration
Swift
public let eventLoop: EventLoop
-
EventLoopFuture
for the response returned by this request.Declaration
Swift
public var futureResult: EventLoopFuture<Response> { get }
-
Waits for execution of this request to complete.
Throws
The error value of theEventLoopFuture
if it errors.Declaration
Swift
public func wait() throws -> Response
Return Value
The value of the
EventLoopFuture
when it completes. -
Cancels the request execution.
Declaration
Swift
public func cancel()