4

I want to download a certain amount of data from a server based on Core Data local database that contains links to the content.

I then want to have a table view that would dynamically display the content being downloaded one by one in a queue list. It would resemble something you see in iTunes app on iPhone where you have a table of songs or podcasts being downloaded with a progress bar indicator.

I've checkout out many tutorials on NSOperationQueue like this one or this one and I've also decided not to use ASIHTTPRequest framework because it is outdated.

How exactly does one wrap the NSOperationQueue of items being downloaded into a UITableview with URLs taken from a Core Data database including download progress activity indicators and deletion of the element from the Table View once its done downloading?

Thanks in advance!

Sergey Grischyov
  • 11,995
  • 20
  • 81
  • 120

1 Answers1

1

During my research on that topic I've ended up with writing my own custom class for the download queue. NSOperationQueue, in my opinion, has several disadvantages connected with control of NSOperations - for example you can't move them up or down - only change their priorities from high to low.

I've also opted out using the ASIHTTPRequest framework because, as I've said earlier, it is outdated.

I've based my class on NSMutableArray to hold queue elements and NSMutableDictionary to hold some values for them.

Sergey Grischyov
  • 11,995
  • 20
  • 81
  • 120
  • @dineshprasanna Please don't get me wrong, but this is a totally custom class and in no way it will help you or anyone else to achieve your goal. I suggest you start from scratch by having an `NSMutableArray` of HTTP requests that would do your thing. Hope this helps – Sergey Grischyov Mar 16 '13 at 14:27
  • ok sir,its not a problem.Actually i have implemented but i have one problem from that (i.e) when i am trying to reload the table all progressbar are started a blinking so its make a big problem for me,In this case what i have supposed to do could you help me.if possible means could you provide your mailid i will send the code through this. – dineshprasanna Mar 18 '13 at 04:08
  • @dineshprasanna I suggest you create a new question on StackOverflow. The problem shouldn't be too hard to solve :) – Sergey Grischyov Mar 18 '13 at 12:25