tibrvEvent_ResetTimerInterval()

Function

Declaration

tibrv_status tibrvEvent_ResetTimerInterval(
    tibrvEvent       event,
    tibrv_f64        newInterval);

Purpose

Reset the interval of a timer event object.

Remarks

The timer begins counting the new interval immediately.

Parameter

Description

event

Reset the interval of this timer.

newInterval

The timer triggers its callback function at this new repeating interval (in seconds).

Timer Granularity

Express the timer interval (in seconds) as a 64-bit floating point number. This representation allows microsecond granularity for intervals up to approximately 146 years. The actual granularity of intervals depends on hardware and operating system constraints.

Limit of Effectiveness

This function can affect a timer only before or during its interval—but not after its interval has elapsed.

This function neither examines, changes nor removes an event that is already waiting in a queue for dispatch. If the next event for the timer object is already in the queue, then that event remains in the queue, representing the old interval. The change takes effect with the subsequent interval. (To circumvent this limitation, a program can destroy the old timer object and replace it with a new one.)

See Also

tibrvEvent_CreateTimer()

tibrvEvent_GetTimerInterval()