CovertOps
uses the Operation
and OperationQueue
classes from Apple's Foundation framework to provide flexible, concise and easy control over robust application behaviors that are often difficult to achieve. This includes precise timing, mutual exclusivity, observation, thread safety, sequencing, throttling, asynchronous behavior and dependency management.
Apple's operation classes are simple and powerful but were designed decades ago in Objective-C. This framework adds many wrappers and convenience methods for a modern, functional-inspired Swift syntax that is much faster and easier to use. There's also a handlful of utlity operations that solve common problems and some new features added to the behavior of operations that will make your own custom subclasses much more powerful.
If you're interesting in using CoreData as well, check out CovertOpsData
, an extension of CovertOps
that provides an easy, powerful and thread-safe implementation of a CoreData stack using operations to read and write from a persistent store.
Resources
For a better unstanding of operations and the principles upon which the framework are based, see below:
- Operation Apple Docs
- OperationQueue Apple Docs
- Advanced NSOperations from WWDC 2015 by Dave Delong
Example
To run the example project, clone the repo, and run pod install
from the Example directory first.
Installation
To install using CocoaPods, add the following to your project Podfile:
pod 'CovertOps'
To install using Carthage, add the following to your project Cartfile:
github "patricklynch/CovertOps"
Author
Patrick Lynch: [email protected]
License
CovertOps
is available under the MIT license. See the LICENSE file for more info.