• 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: Cocoa-dev Digest, Vol 8, Issue 783
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Cocoa-dev Digest, Vol 8, Issue 783


  • Subject: Re: Cocoa-dev Digest, Vol 8, Issue 783
  • From: Gordon Apple <email@hidden>
  • Date: Thu, 29 Sep 2011 20:25:22 -0500
  • Thread-topic: Cocoa-dev Digest, Vol 8, Issue 783

There must already be an array for the table, so just iterate the array
every minute or whatever (single repeating timer), compare the times to
[NSDate date} and start or shut down whatever has not been started or shut
down.  Much easier than trying to manage timers.


On 9/29/11 8:06 PM, "email@hidden"
<email@hidden> wrote:

>> > Perhaps, instead of timers, you use objects that represent one of these
>> set-top boxes and the time at which they should be shutdown.  And instead of
>> scheduling and managing timer, you manage the domain objects instead.  Then,
>> you have one timer, that checks all of your objects and sees if they should
>> be shut down.
>
>
> But when re-reading the thread I see this is exactly what John suggested:
>
>> > Could you use a single, repeating timer with sufficient resolution for your
>> purposes and an array or dictionary storing the needed timing state?  Then
>> update state appropriately at each fire of the single timer?"


_______________________________________________

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

  • Follow-Ups:
    • Re: Cocoa-dev Digest, Vol 8, Issue 783
      • From: Graham Cox <email@hidden>
    • Re: creating multiple NSTimers
      • From: Gordon Apple <email@hidden>
  • Prev by Date: Re: delegate of an NWindowController's window
  • Next by Date: Re: creating multiple NSTimers
  • Previous by thread: Re: applicationWillFinishLaunching
  • Next by thread: Re: creating multiple NSTimers
  • Index(es):
    • Date
    • Thread