Retrofire 1.0.2

Retrofire 1.0.2

测试已测试
语言语言 SwiftSwift
许可 MIT
发布上次发布2017年11月
SwiftSwift 版本4
SPM支持 SPM

Rachid Calazans维护。



 
依赖
Alamofire~> 4.4.0
SwiftyJSON>= 0
 

Retrofire 1.0.2

Retrofire

Retrofire是一个用Swift编写的框架,它能够优雅地生成API请求和构建模型。我们将两个强大的库AlamofireSwiftyJSON结合起来,为您提供更优质的响应。

  • 功能
  • 安装
  • 使用
  • 目标

Retrofire将您的HTTP API转换成Swift协议。

Protocol implementation sample

Retrofire类为sample接口生成实现。

remoteBuilder implementation sample

功能

  • 执行API请求
  • 构建响应对象
  • 错误处理

安装

### CocoaPods

$ gem install cocoapods

CocoaPods是Cocoa项目的一个依赖管理器。您可以使用以下命令安装它:

sample with podfile

要使用CocoaPods将Retrofire集成到您的Xcode项目中,请在Podfile中指定它。

$ pod install

然后运行

request sample

###发送单个请求

request sample

###请求列表

building model sample

###构建模型

request sample

####响应处理说明

request sample

####响应处理程序说明

  • ###目标
  • 选择线程运行