Unit Timers

+----------------------------------------------------------------------------+ | İ İ | | İİ İ İ İ | | İİİ İ İ İ | | İİ İ İ İ | | İ İİ İ İ | | İ İ İİİ İİ İ | | İİ İ İ İİİİİİİİİİ İ | | İ İİ İİ İİİİİİİİİİİİİİİ | | İ İİİ İİİİİİ İİİ İ İİİİİİİİ | | İ İİ İİİİİİİİİİİİ İ İİİİİİİİİİ Copyright İ 1996-1997 by: | | İ İİİİİİ İİİİİİİİİİİ İ İİİİİ İİ | | İ İİİİİİİ İİİİİ İİİİ İİ İİ İ WHITE ANTS SYSTEMHOUSE BV | | İ İİİİİİİ İİİ İİİ İİ İ İİİİ Geleen 12 | | İ İİİİİİİ İ İİ İİİ İ 8032 GB Zwolle | | İİİİİİ İ İ İ Netherlands | | İİİ İİİİİ İ İİ İ İ | | İİ İ İ İİİ İ Tel. +31 38 453 86 31 | | İ İ İ Fax. +31 38 453 41 22 | | İ İ İİ | | İ İ İİ www.whiteants.com | | İİ İ İ İ support@whiteants.com | | İ | +----------------------------------------------------------------------------+ file : Timers version : 1.0 comment : date : 14-01-97 time : author : R. Post compiler : Delphi 1.0 +----------------------------------------------------------------------------+ | DISCLAIMER: | | THIS SOURCE IS FREEWARE. YOU ARE ALLOWED TO USE IT IN YOUR OWN PROJECTS | | WITHOUT ANY RESTRICTIONS. YOU ARE NOT ALLOWED TO SELL THE SOURCE CODE. | | THERE IS NO WARRANTY AT ALL - YOU USE IT ON YOUR OWN RISC. WHITE ANTS DOES | | NOT ASSUME ANY RESPONSIBILITY FOR ANY DAMAGE OR ANY LOSS OF TIME OR MONEY | | DUE THE USE OF ANY PART OF THIS SOURCE CODE. | +----------------------------------------------------------------------------+

Classes

TDelayPoolTimer -
TDelayTimer -
TIntervalPoolTimer -
TIntervalTimer -
TOneShotPoolTimer -
TOneShotTimer -
TPoolTimer -
TPoolTimerCollection -
TTimerPool -
TTimerPoolComponent -

Functions

AccurateTimeMS - The AccurateTimeMS function retrieves the number of milliseconds that have elapsed since Windows was started.
DecodeTimeMS -
ElapsedTimeMS - Calculate time elapsed (in milliseconds) between Start and Stop.
EncodeTimeMS -
Register -
ULong - Treats the value of the passed longint as an unsigned longint and returns the unsigned value as a double.
UTrunc - Truncates the value of the passed double to an unsigned longint value and returns this as a longint.

Types

TTriggerEvent

Constants

SUnableToRemoveFmt

Variables

TimerPool


Functions


function AccurateTimeMS: LongInt;

The AccurateTimeMS function retrieves the number of milliseconds that have elapsed since Windows was started. In enhanced mode it is accurate to 1 ms. If windows has been active for more then 24.5 days, the LongInt value will go negative and after 49 days,the timer will be overflow to 0.

procedure DecodeTimeMS(TimeMS: LongInt; var Hour, Min, Sec, MSec: Word);


function ElapsedTimeMS(Start, Stop : LongInt): Double;

Calculate time elapsed (in milliseconds) between Start and Stop. Start and Stop should be values retrieved with AccurateTimeMS or GetTickCount. This function can determine the elapsed time up to 49 days.

function EncodeTimeMS(Hour, Min, Sec, MSec: Word): LongInt;


procedure Register;


function ULong(L: LongInt): Double;

Treats the value of the passed longint as an unsigned longint and returns the unsigned value as a double.

function UTrunc(aDouble: Double): LongInt;

Truncates the value of the passed double to an unsigned longint value and returns this as a longint.

Types


TTriggerEvent = procedure (Sender: TObject; Handle: Integer) of object

Constants

SUnableToRemoveFmt = 'Unable to remove timer %d from TimerPool'

.$DEFINE RAISE_EXCEPTIONS

Variables

TimerPool : TTimerPool