GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  TCL_DELETETIMERHANDLER (3)

NAME

Tcl_CreateTimerHandler, Tcl_DeleteTimerHandler - call a procedure at a given time

CONTENTS

Synopsis
Arguments
Description
Keywords

SYNOPSIS

#include <tcl.h>

Tcl_TimerToken Tcl_CreateTimerHandler(milliseconds, proc, clientData)

Tcl_DeleteTimerHandler(token)

ARGUMENTS


.TP 15 int milliseconds (in)
int       milliseconds int How many milliseconds to wait before invoking proc.
.TP 15 Tcl_TimerProc *proc (in)
Tcl_TimerProc*proc Tcl_TimerProc Procedure to invoke after milliseconds have elapsed.
.TP 15 ClientData clientData (in)
ClientDataclientData ClientData Arbitrary one-word value to pass to proc.
.TP 15 Tcl_TimerToken token (in)
Tcl_TimerTokentoken Tcl_TimerToken Token for previously created timer handler (the return value from some previous call to Tcl_CreateTimerHandler).

   








\L’|0u-1v’\l’75u+3n_’\L’0u+1v-0u’\l’|0u-1.5n_’



\L’|0u-1v’\L’0u+1v-0u’\l’|0u-1.5n_’





DESCRIPTION

Tcl_CreateTimerHandler arranges for proc to be invoked at a time milliseconds milliseconds in the future. The callback to proc will be made by Tcl_DoOneEvent, so Tcl_CreateTimerHandler is only useful in programs that dispatch events through Tcl_DoOneEvent or through Tcl commands such as vwait. The call to proc may not be made at the exact time given by milliseconds: it will be made at the next opportunity after that time. For example, if Tcl_DoOneEvent is not called until long after the time has elapsed, or if there are other pending events to process before the call to proc, then the call to proc will be delayed.

Proc should have arguments and return value that match the type Tcl_TimerProc:


typedef void Tcl_TimerProc(ClientData clientData);


The clientData parameter to proc is a copy of the clientData argument given to Tcl_CreateTimerHandler when the callback was created. Typically, clientData points to a data structure containing application-specific information about what to do in proc.

Tcl_DeleteTimerHandler may be called to delete a previously created timer handler. It deletes the handler indicated by token so that no call to proc will be made; if that handler no longer exists (e.g. because the time period has already elapsed and proc has been invoked then Tcl_DeleteTimerHandler does nothing. The tokens returned by Tcl_CreateTimerHandler never have a value of NULL, so if NULL is passed to Tcl_DeleteTimerHandler then the procedure does nothing.

KEYWORDS

callback, clock, handler, timer
Search for    or go to Top of page |  Section 3 |  Main Index


Tcl TCL_CREATETIMERHANDLER (3) 7.5

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.