0.3.0
0.3.0 makes many changes from 0.2.0. Where possible, old names and types are available with deprecation attributes; these will soon be removed.
- Updated threading model:
MobiusLoopis now single-threadedMobiusControllerruns a loop on a single background queue.- Fixed several issues around hard-to-avoid assertions in loop teardown.
- New
EffectRouterandEffectHandlerreplaceEffectRouterBuilder(which is deprecated along with several helpers). - Effects in
FirstandNextare now an array rather than a set. This doesn’t imply an ordering guarantee, but does mean that effects don’t have to beHashable. - Various things renamed or changed from methods to properties to better conform to Swift API Guidelines and for internal consistency:
Initiatoris nowInitiate, and is only used withMobiusController.MobiusLoop.getMostRecentModel()becomeslatestModel.MobiusController.getModel()becomesmodel.Connectable.InputTypeandOutputTypebecomeInputandOutput;Connection.ValueTypebecomesValue.
Updateis now a struct. This isn’t leveraged by Mobius itself at the moment, but makes it easier to write transformations on updates in a fluent style.- For consistency,
MobiusControlleris created through amakeController()method onMobius.Builderinstead of being initialized with a builder argument. - All methods on
MobiusLoggernow have default do-nothing implementations. ConsoleLoggerhas been replaced withSimpleLogger, which can take a consumer function to use instead ofprint.NoEffectandBrokenConnectionare deprecated.MobiusHooks.ErrorHandlernow returnsNeverrather thanVoid.- Mobius no longer adds a public extension to
NSRecursiveLock. - There are more documentation comments than there used to be.
- Tooling updated to Swift 5.0 and Xcode 11.0.
- Swift Package Manager is explicitly supported for all Apple platforms; Carthage and CocoaPods are supported for iOS only.