All Projects → serejahh → Unboxedalamofire

serejahh / Unboxedalamofire

Licence: mit
[Deprecated] Alamofire + Unbox: the easiest way to download and decode JSON into swift objects.

Programming Languages

swift
15916 projects

Projects that are alternatives of or similar to Unboxedalamofire

Serpent
A protocol to serialize Swift structs and classes for encoding and decoding.
Stars: ✭ 281 (+332.31%)
Mutual labels:  json, alamofire, cocoapods, carthage
Alamofire
Elegant HTTP Networking in Swift
Stars: ✭ 36,896 (+56663.08%)
Mutual labels:  alamofire, cocoapods, carthage
Sync
JSON to Core Data and back. Swift Core Data Sync.
Stars: ✭ 2,538 (+3804.62%)
Mutual labels:  json, cocoapods, carthage
Networking
Easy HTTP Networking in Swift a NSURLSession wrapper with image caching support
Stars: ✭ 1,269 (+1852.31%)
Mutual labels:  alamofire, cocoapods, carthage
Restofire
Restofire is a protocol oriented networking client for Alamofire
Stars: ✭ 377 (+480%)
Mutual labels:  alamofire, cocoapods, carthage
Localize
Localize is a framework writed in swift to localize your projects easier improves i18n, including storyboards and strings.
Stars: ✭ 253 (+289.23%)
Mutual labels:  json, cocoapods, carthage
Netfox
A lightweight, one line setup, iOS / OSX network debugging library! 🦊
Stars: ✭ 3,188 (+4804.62%)
Mutual labels:  alamofire, cocoapods, carthage
Swiftyjson
The better way to deal with JSON data in Swift.
Stars: ✭ 21,042 (+32272.31%)
Mutual labels:  json, cocoapods, carthage
Wstagsfield
An iOS text field that represents tags, hashtags, tokens in general.
Stars: ✭ 1,013 (+1458.46%)
Mutual labels:  cocoapods, carthage
Lgalertview
Customizable implementation of UIAlertViewController, UIAlertView and UIActionSheet. All in one. You can customize every detail. Make AlertView of your dream! :)
Stars: ✭ 1,027 (+1480%)
Mutual labels:  cocoapods, carthage
Pinpointkit
Send better feedback
Stars: ✭ 1,115 (+1615.38%)
Mutual labels:  cocoapods, carthage
Css3colorsswift
A UIColor extension with CSS3 Color names.
Stars: ✭ 62 (-4.62%)
Mutual labels:  cocoapods, carthage
Istimeline
Simple timeline view written in Swift 3
Stars: ✭ 1,005 (+1446.15%)
Mutual labels:  cocoapods, carthage
Cameramanager
Simple Swift class to provide all the configurations you need to create custom camera view in your app
Stars: ✭ 1,130 (+1638.46%)
Mutual labels:  cocoapods, carthage
Sketchkit
A lightweight auto-layout DSL library for iOS & tvOS.
Stars: ✭ 40 (-38.46%)
Mutual labels:  cocoapods, carthage
Cdalertview
Highly customizable alertview and alert/notification/success/error/alarm popup written in Swift
Stars: ✭ 1,056 (+1524.62%)
Mutual labels:  cocoapods, carthage
Stravakit
Strava API Client built with Swift
Stars: ✭ 50 (-23.08%)
Mutual labels:  cocoapods, carthage
Fontblaster
Programmatically load custom fonts into your iOS and tvOS app.
Stars: ✭ 1,000 (+1438.46%)
Mutual labels:  cocoapods, carthage
Swiftymessenger
Swift toolkit for passing messages between iOS apps and extensions.
Stars: ✭ 48 (-26.15%)
Mutual labels:  cocoapods, carthage
Transitionbutton
UIButton sublass for loading and transition animation.
Stars: ✭ 1,124 (+1629.23%)
Mutual labels:  cocoapods, carthage

UnboxedAlamofire

⚠️ DEPRECATED

UnboxedAlamofire is deprecated as well as Unbox is deprecated in favor of Swift’s built-in Codable API.


Build Status CocoaPods Compatible Carthage Compatible Platform

Alamofire + Unbox: the easiest way to download and decode JSON into swift objects.

Features

  • [x] Unit tested
  • [x] Fully documented
  • [x] Mapping response to objects
  • [x] Mapping response to array of objects
  • [x] Keypaths
  • [x] Nested keypaths
  • [x] For Swift 2.x use v. 1.x and swift2 branch
  • [x] For Swift 3.x use v. 2.x

Usage

Objects you request have to conform Unboxable protocol.

Get an object

Alamofire.request(url, method: .get).responseObject { (response: DataResponse<Candy>) in
    // handle response
    let candy = response.result.value
    
    // handle error
    if let error = response.result.error as? UnboxedAlamofireError {
        print("error: \(error.description)")
    }
}

Get an array

Alamofire.request(url, method: .get).responseArray { (response: DataResponse<[Candy]>) in
    // handle response
    let candies = response.result.value
    
    // handle error
    if let error = response.result.error as? UnboxedAlamofireError {
        print("error: \(error.description)")
    }
}

KeyPath

Also you can specify a keypath in both requests:

Alamofire.request(url, method: .get).responseObject(keyPath: "response") { (response: DataResponse<Candy>) in
    // handle response
    let candy = response.result.value
    
    // handle error
    if let error = response.result.error as? UnboxedAlamofireError {
        print("error: \(error.description)")
    }
}

Installation

CocoaPods

pod 'UnboxedAlamofire', '~> 2.0'

Carthage

github "serejahh/UnboxedAlamofire" ~> 2.0
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].