• 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: creating multiple NSTimers
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: creating multiple NSTimers


  • Subject: Re: creating multiple NSTimers
  • From: Gordon Apple <email@hidden>
  • Date: Thu, 29 Sep 2011 20:28:09 -0500
  • Thread-topic: Re: creating multiple NSTimers

Whoops, didn¹t reset the title.  Sorry.

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

> 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

References: 
 >Re: Cocoa-dev Digest, Vol 8, Issue 783 (From: Gordon Apple <email@hidden>)

  • Prev by Date: Re: Cocoa-dev Digest, Vol 8, Issue 783
  • Next by Date: Re: Cocoa-dev Digest, Vol 8, Issue 783
  • Previous by thread: Re: Cocoa-dev Digest, Vol 8, Issue 783
  • Next by thread: Re: Cocoa-dev Digest, Vol 8, Issue 783
  • Index(es):
    • Date
    • Thread