CallOperation
public protocol CallOperation : NetworkOperation
A network operation that knows how to execute a pCloud API call.
-
The result from executing the API call. Exists only when
state
isNetworkOperationState.completed
.Declaration
Swift
var response: Call.Response? { get }
-
Adds a block to be called on a specific queue when the operation receives its response.
Declaration
Swift
@discardableResult func addCompletionBlock(with queue: DispatchQueue?, _ block: @escaping (Call.Response) -> Void) -> Self
Parameters
queue
A queue to call
block
on. Ifnil
, the queue on whichblock
will be called is undefined.block
Called as soon as the operation receives its response. Referenced strongly by the operation.