Carlos v0.9.1 Release Notes

Release Date: 2016-12-14 // over 3 years ago
  • Breaking changes

    • 👍 Swift 3.0 support (for Swift 2.3 use specific commit 5d354c829d766568f164c386c59de21357b5ccff instead)
    • 🆕 batchGetAll has been removed and replaced with a reified allBatch (see New features )
    • 🚚 All deprecated functions have been removed
    • 🚚 All custom operators have been removed in favor of their function counterparts
    • 🍎 macOS and tvOS support has been temporarily dropped and will be probably re-added in the future
    • set method on CacheLevel now returns a Future enabling error-handling and progress-tracking of set calls.

    🆕 New Features

    • It's now possible to lift a CacheLevel into one that operates on a sequence of keys and returns a sequence of values. You can use allBatch to create a concrete BatchAllCache. You can use get on this cache if you want to pass a list of keys and get the success callback when all of them succeed and the failure callback as soon as one of them fails (old behavior of batchGetAll), or you can compose or transform an allBatch cache just like any another CacheLevel. Consult the README.md for an example.

Previous changes from v0.8

  • Breaking changes

    • The codebase has been migrated to Swift 2.2
    • 🚚 Promise now has only an empty init. If you used one of the convenience init (with value:, with error: or with value:error:), they now moved to Future.

    🆕 New features

    • ➕ Adds value and error properties to Result
    • ➕ Added a way to initialize Futures through closures
    • It's now possible to map Futures through:
      • a simple transformation closure
      • a closure that throws
    • It's now possible to flatMap Futures through:
      • a closure that returns an Optional
      • a closure that returns another Future
      • a closure that returns a Result
    • It's now possible to filter Futures through:
      • a simple condition closure
      • a closure that returns a Future<Bool>
    • It's now possible to reduce a SequenceType of Futures into a new Future through a combine closure
    • It's now possible to zip a Future with either another Future or with a Result
    • ➕ Added merge to a SequenceType of Futures to collapse a list of Futures into a single one
    • ➕ Added traverse to SequenceType to generate a list of Futures through a given closure and merge them together
    • ➕ Added recover to Future so that it's possible to provide a default value the Future can use instead of failing
    • It's now possible to map Results through:
      • a simple transformation closure
      • a closure that throws
    • It's now possible to flatMap Results through:
      • a closure that returns an Optional
      • a closure that returns a Future
      • a closure that returns another Result
    • It's now possible to filter Results through a simple condition closure
    • ➕ Added mimic to Result