Content-type: text/html Man page of CLanguageTraceCallback

CLanguageTraceCallback

Section: NSCL Data Analysis packags (3)
Updated: 0.1
Index Return to Main Contents



 

NAME

CLanguageTraceCallback - A trace callback object that bridges to unbound functions  

SYNOPSIS


#include <CLanguageTraceCallbacks.h>

class CTCLInterpreter;


typedef char* (VariableTraceCallback)(Tcl_Interp*, char*, char*, int, void*);


class CLanguageTraceCallback : public CVariableTraceCallback
{
 public:
  CLanguageTraceCallback(VariableTraceCallback* pCallback,
                          void*                  pClientData);
};

#endif


 

DESCRIPTION

CLanguageTraceCallback provides a pre-built trace callback you can instantiate and register on a CTCLTracedVariable to create an unbound function callback. Unbound functions are C++'s terminology for functions that are not members of a class. CLanguageCallback also allows you to register a callback written in C or any other language.  

PUBLIC INTERFACE

typedef char* (VariableTraceCallback)(Tcl_Interp*, char*, char*, int, void*);
This typedef defines the call signature of the unbound callback function. The first parameter is a pointer to the Tcl interpreter. Note that this is the interpreter itself, not the object wrapping of the interpreter that the TCL++ library usually uses. The second parameter, is a pointer to tha null terminated character string that is the name of the variable that fired the trace. If the trace fired on an array element,the third parameter is a pointer to the name of the element, otherwise it is a a NULL. The fourth parameter are flags indicating why the trace fired. It will be one of the flags TCL_TRACE_READS, TCL_TRACE_WRITES, TCL_TRACE_UNSETS or.
 TCL_TRACE_DESTROYED will be set if the trace is getting removed, an finally, TCL_INTERP_DESTROYED is set if the interpreter is getting destroyed. The final parameter is a user supplied parameter which is passed without interpretation to the callback.
CLanguageTraceCallback(VariableTraceCallback* pCallback, void* pClientData);
The constructor for CLanguageTraceCallback objects allows you to specify two parameters. pCallback is a pointer to a function of type VariableTraceCallback. This designates the callback function. The second parameter is saved by the callback object and passed without interpretation to pCallback when the callback fires.
 

EXAMPLES

<none yet>  

SEE ALSO

CTracedVariable(3) CVariableTraceCallback(3), TracingIntro(3)


 

Index

NAME
SYNOPSIS
DESCRIPTION
PUBLIC INTERFACE
EXAMPLES
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 14:18:39 GMT, February 25, 2005