Skip to content

Instantly share code, notes, and snippets.

@calebd
calebd / AsynchronousOperation.swift
Last active February 27, 2025 09:17
Concurrent NSOperation in Swift
import Foundation
/// An abstract class that makes building simple asynchronous operations easy.
/// Subclasses must implement `execute()` to perform any work and call
/// `finish()` when they are done. All `NSOperation` work will be handled
/// automatically.
open class AsynchronousOperation: Operation {
// MARK: - Properties