Skip to content

Your GET request is in progress, better reuse it than create a new one, right?

License

Notifications You must be signed in to change notification settings

nuorder/AFHTTPSessionManager-AFUniqueGET

 
 

Repository files navigation

AFHTTPSessionManager-AFUniqueGET

CI Status Version License Platform

This category adds the uniqueGET method to AFHTTPSessionManager, which is useful if you want to avoid making multiple calls at the same resource if the operation is still in progress.

A common request between AFNetworking users (for example #499, #1460).

We achieve this by checking on-going operations before creating new ones.

Usage

Installation

AFHTTPSessionManager-AFUniqueGET is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'AFHTTPSessionManager-AFUniqueGET'

API

- (void)uniqueGET:(NSString *)URLString
       parameters:(id)parameters
             task:(void (^)(NSURLSessionDataTask *task, BOOL existing))task
          success:(void (^)(NSURLSessionDataTask *task, id responseObject))success
          failure:(void (^)(NSURLSessionDataTask *task, NSError *error))failure;

Author

Elvis Nuñez, elvisnunez@me.com

License

AFHTTPSessionManager-AFUniqueGET is available under the MIT license. See the LICENSE file for more info.

About

Your GET request is in progress, better reuse it than create a new one, right?

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Objective-C 58.0%
  • Shell 31.8%
  • Ruby 10.2%