Asynchronous HTTP Request, Queue Requests

I developed for the appstore before and I used ASIHTTPRequest. Is there something similar for Android?

I am looking for several HTTP requests that are queued and managed. This is what I need to do:

  • Queue setup allows you to scan 6 HTTP requests.
  • Once the queue is configured, execute it with each request giving me the result of success / failure.
  • If one request fails, I have the option to cancel / clear the entire queue.
  • If all the requests in the queue are successful, I may have another callback for the entire event of the successful queue.
  • And each request can have a retry counter; meaning; I can say that each request can be repeated n times before they can return a failure.

ASIHTTPRequestit was nice for iOS to handle this. Anyway, can I do this with Android? Most of my content is returned XML and does not contain binary data.

Any feedback is greatly appreciated.

+3
source share
1 answer

What you describe is not too difficult to build.

  • Expand java.util.Queue
  • Create a listener user interface that handles all the events that need to be tracked.
  • Custom request objects that allow you to set a "listener".
  • Your user queue will have a thread to process items in its own queue.
  • /, , .

​​ "" .

, ... ..., .

, - ASIHTTPRequest Java/Android, , iOS. 20 . , - , .

+1

All Articles