Releases: ishkawa/APIKit
Releases · ishkawa/APIKit
0.5.1
0.5.0
- Add
cancelRequest(_:passingTest:)
for canceling.
Now, you can cancel request by passing class of Request
like this:
GitHub.cancelRequest(GitHub.Endpoint.SearchRepositories.self)
If you want to filter requests, add closure that identifies the request shoule be cancelled or not.
GitHub.cancelRequest(GitHub.Endpoint.SearchRepositories.self) { request in
return request.query == "APIKit"
}
0.4.0
- Add
responseErrorFromObject
to create detailed error using response object #16 - Add
defaultURLSession
and its delegate instead ofinstancePair
#14
Breaking changes:API
does not create singleton instances for eachAPI
subclasses.API.instance
is no longer available.API.session
is no longer available.- From 0.4.0, if an
API
subclass needs a separated session,defaultURLSession
should be overrided.
- Delegate methods for custom behaviors of
NSURLSession
implemented inAPI
should be move to custom delegate class, and its instance should be a delegate ofdefaultURLSession
.