1Tcl_CreateCloseHandler(3)   Tcl Library Procedures   Tcl_CreateCloseHandler(3)
2
3
4
5______________________________________________________________________________
6

NAME

8       Tcl_CreateCloseHandler,  Tcl_DeleteCloseHandler - arrange for callbacks
9       when channels are closed
10

SYNOPSIS

12       #include <tcl.h>
13
14       void
15       Tcl_CreateCloseHandler(channel, proc, clientData)
16
17       void
18       Tcl_DeleteCloseHandler(channel, proc, clientData)
19
20

ARGUMENTS

22       Tcl_Channel channel (in)               The channel for which to  create
23                                              or delete a close callback.
24
25       Tcl_CloseProc *proc (in)               The  procedure  to  call  as the
26                                              callback.
27
28       ClientData clientData (in)             Arbitrary one-word value to pass
29                                              to proc.
30______________________________________________________________________________
31

DESCRIPTION

33       Tcl_CreateCloseHandler  arranges  for proc to be called when channel is
34       closed with Tcl_Close or Tcl_UnregisterChannel, or using the Tcl  close
35       command.  Proc should match the following prototype:
36
37              typedef void Tcl_CloseProc(
38                      ClientData clientData);
39
40       The  clientData  is  the  same  as  the  value  provided in the call to
41       Tcl_CreateCloseHandler.
42
43       Tcl_DeleteCloseHandler removes a close callback for channel.  The  proc
44       and  clientData  identify  which  close callback to remove; Tcl_Deleteā€
45       CloseHandler does nothing if its proc and clientData arguments  do  not
46       match the proc and clientData for a  close handler for channel.
47

SEE ALSO

49       close(n), Tcl_Close(3), Tcl_UnregisterChannel(3)
50

KEYWORDS

52       callback, channel closing
53
54
55
56Tcl                                   7.5            Tcl_CreateCloseHandler(3)
Impressum