0

I'm trying to migrate AFNetworking version 1.x to 2.x.

In the Migration Guide, AFHTTPClient.m is separated to AFHTTPRequestOperationManager & AFHTTPSessionManager but I can't find AFHTTPClient registerHTTPOperationClass: in either AFHTTPRequestOperationManager or AFHTTPSessionManager.

What function can substitute for registerHTTPOperationClass:?

Rob
  • 415,655
  • 72
  • 787
  • 1,044
  • I believe you would just set the appropriate `responseSerializer` for `AFHTTPRequestOperationManager`. For example, `manager.responseSerializer = [AFJSONResponseSerializer serializer]` or whatever. If that's not clear, perhaps expand your question with more details (or actual code sample) of how you're currently using `registerHTTPOperationClass` and describe precisely what you're trying to accomplish. – Rob Jul 30 '14 at 05:49
  • that you pasted link of AFN 2.0 well contain well information about it you just need to read and try to understand what is mention into documentation. Do not find Example code just try your self. – Nitin Gohel Jul 30 '14 at 05:49
  • have you asked yet the author of the `AFNetworking`, perhaps? – holex Jul 30 '14 at 08:31
  • Please include your solution in your question, so others can benefit as well. – koen Jul 30 '14 at 12:03

0 Answers0