• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: AppDelegate vs Custom View Controllers for Download Task...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AppDelegate vs Custom View Controllers for Download Task...


  • Subject: Re: AppDelegate vs Custom View Controllers for Download Task...
  • From: Alex Zavatone <email@hidden>
  • Date: Tue, 16 Jun 2015 21:00:41 -0400

Why not just create a singleton to manage the processes?

Putting it in the appDelegate sounds like "I'm putting it there because I don't know where else to put it".

Declare an object that exists as long as you need it to, put the code in there, dispose of it when you don't need it anymore.

On Jun 16, 2015, at 6:37 PM, Peters, Brandon wrote:

> Hi,
>
> I have “duplicate” code for downloading a DB file in two custom view controllers that I think would be better served if the download were initiated when the App launches on the iPhone/iPad. My plan is to make the AppDelegate a delegate of NSURL session (and the various other NSURL delegate stuff it would need) Is there any “known” danger in making the AppDelegate a NSURL session delegate?
>
> Sorry for wording.
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


References: 
 >AppDelegate vs Custom View Controllers for Download Task... (From: "Peters, Brandon" <email@hidden>)

  • Prev by Date: Re: [Swift] best way to support 'keyword' args, symbolic values, show values as literals?
  • Next by Date: Trouble With NSURLSession...
  • Previous by thread: Re: AppDelegate vs Custom View Controllers for Download Task...
  • Next by thread: Trouble With NSURLSession...
  • Index(es):
    • Date
    • Thread