UploadOperation

public class UploadOperation<R: Uploadable>: AOperation<R>

An NSOperation that executes the Uploadable asynchronously.

  • Intializes an upload operation.

    Declaration

    Swift

    public init(uploadable: R, request: @escaping () -> UploadRequest, completionHandler: ((DataResponse<R.Response>) -> Void)?)

    Parameters

    uploadable

    The Uploadable.

    request

    The request closure.

    completionHandler

    The async completion handler called when the request is completed

  • Creates a copy of self

    Declaration

    Swift

    open override func copy() -> AOperation<R>