Define KTIntervalTimer instance.
More...
#import "KTType.h"
#import <Coconut/Coconut.h>
Go to the source code of this file.
Detailed Description
Define KTIntervalTimer instance.
- Copyright
- Copyright (C) 2012 Steel Wheels Project
- Reference
- o Concurrency Programming Guide See "Dispatch Queues/Creating Timer".
Function Documentation
Add consumer functions of interval timer.
- Parameters:
-
dst | Interval timer |
func | Trigger function |
inst | Parameter for the trigger function call |
struct KTIntervalTimer* KTAllocateIntervalTimer |
( |
dispatch_queue_t |
queue, |
|
|
double |
interval, |
|
|
struct CNResource * |
resource |
|
) |
| [read] |
Allocate trigger timer instance.
- Returns:
- Allocated instance
- Parameters:
-
queue | Queue to execute the timer task |
interval | Timer interval [sec] |
resource | Resouce to allocate this instance |
static struct CNInstance* KTInstanceOfIntervalTimer |
( |
struct KTIntervalTimer * |
src | ) |
[static, read] |
Get instance of CNIntervalTimer.
- Returns:
- Instance of source
- Parameters:
-
Start the timer.
- Parameters:
-
Get state of interval timer.
- Returns:
- State of timer
- Parameters:
-
Stop the timer.
- Parameters:
-
Variable Documentation
Shared methods for CNIntervalTimer