-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 9/29/11 10:50 PM, Greg Guerin wrote:
Gordon Apple 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
On 30 Sep 2011, at 08:19, Conrad Shultz wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 9/29/11 10:50 PM, Greg Guerin wrote:
Gordon Apple wrote:
There must already be an array for the table, so just iterate
the
array every
minute or whatever (single repeating timer), compare
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 9/30/11 12:29 AM, Thomas Davie wrote:
When the user updates a timer, one is forced to re-sort the
array and reposition the index (under the above implementation).
Why would you need to resort? Just remove, and reinsert.
OK, I'll grant you
Thanks for the discussion. What I implemented last night was what Graham had
suggested. I simply bind my table column values to an NSArrayController
controller and observed by KVO in my set box object. It works great. I think
this is also what Conrad had meant as well. Simply changing the
For the life of me I cannot figure this one out. I need to create an
indeterminate amount of timers for an app I am working on. The app is petty
simple. For example, provide a list of ip enabled devices with times to shut
off and the app executes the device's shutdown at the specified time.
Can't you use a loop and then stuff the timers into an NSMutableArray or
NSMutableDictionary to access?
On Thu, Sep 29, 2011 at 5:47 PM, Tom Hohensee tom.hohen...@gmail.comwrote:
For the life of me I cannot figure this one out. I need to create an
indeterminate amount of timers for an app I
On Sep 29, 2011, at 2:47 PM, Tom Hohensee wrote:
However, I do not know wether the user will have 1 device or 100 devices. Do
I have to setup a finite amount of timers (ultimately having a limit on the
number of devices that can be added) or is there a better way? I have
googled for a
Yes. What I have worked on is using an array of timers fired sequentially.
Each firing of the timer sets up the next one in the array. Each new addition
to the array requires invalidating of the active timer and reordering of the
array according to times. But i have run into problems when
I think you need to backup and explain exactly what your requirements are. If
you really do need to track these timers, you will probably need an array or
dictionary, but if these timers are all one-shot and they configure the next
timer to execute, there seems little reason to maintain your
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 9/29/11 3:06 PM, Tom Hohensee wrote:
Yes. What I have worked on is using an array of timers fired
sequentially. Each firing of the timer sets up the next one in the
array. Each new addition to the array requires invalidating of the
active
On Sep 29, 2011, at 3:06 PM, Tom Hohensee wrote:
Yes. What I have worked on is using an array of timers fired sequentially.
Each firing of the timer sets up the next one in the array. Each new
addition to the array requires invalidating of the active timer and
reordering of the array
Hi Tom-
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?
Array {
Timing Item 1 {
currentTime: 24.2
Sorry, I started this out wrong. I am probably over thinking this to the
point of confusion. Here is where I am.
I have an application for a facility that uses a number of ip enabled set top
boxes to drive TV's throughout the place. Each box is to be shutdown at
certain times of the day
Forgot to send to list:
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
Timers are objects, and can be retained like any other independently of whether
they are scheduled on a run loop or not. The run loop will additionally retain
the timer, but that's its business.
In the object that represents the set-top box, just add a 'timer' property
(retained), so that you
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 9/29/11 4:48 PM, Tom Hohensee wrote:
Sorry, I started this out wrong. I am probably over thinking
this to the point of confusion. Here is where I am. I have an
application for a facility that uses a number of ip enabled set top
boxes to
Bingo! Thanks. This is where I was going wrong. I saw John and Jamie's
responses earlier and got me thinking in objects again. But still wasn't
putting it together. I had a mental block and was not thinking of the timers
as properties of the boxes. Just kept getting stuck on the NSTimer
Whoops, didnĀ¹t reset the title. Sorry.
On 9/29/11 8:25 PM, Gordon Apple g...@ed4u.com 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
Gordon Apple 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
19 matches
Mail list logo