Main Page   Compound List   File List   Compound Members   File Members  

TclXPCOMComponent.cpp File Reference

#include "TclXPCOMPrivate.h"

Go to the source code of this file.


void InterpDeletedCallback (ClientData clientData, Tcl_Interp *interp)
TclXPCOMComponentNewTclXPCOMComponent (Tcl_Interp *interp, Tcl_ThreadId thread, ClassInfo *cinfo)
void UnsetDestructorBinding (TclXPCOMComponent *component)
void SetDestructorBinding (TclXPCOMComponent *component, Tcl_Obj *script)
void FreeTclXPCOMComponent (TclXPCOMComponent *component)
int BindScript (Tcl_Interp *interp, TclXPCOMComponent *component, Tcl_Obj *identifier, Tcl_Obj *script, int flags)

Detailed Description

Contains functions for manipulating Tcl components.

Definition in file TclXPCOMComponent.cpp.

Function Documentation

void InterpDeletedCallback ClientData    clientData,
Tcl_Interp *    interp

Callback that is executed when a Tcl component's interpreter is prematurely deleted. Once a component's interpreter is killed, any attempts to invoke methods on it will return 'NS_ERROR_FAILURE'.

clientData  (in) holds the Tcl component whose interp was killed
interp  (in) interpreter

Definition at line 49 of file TclXPCOMComponent.cpp.

Referenced by FreeTclXPCOMComponent, and NewTclXPCOMComponent.

TclXPCOMComponent* NewTclXPCOMComponent Tcl_Interp *    interp,
Tcl_ThreadId    thread,
ClassInfo   cinfo

Creates a new Tcl component.

a new Tcl component
interp  (in) interpreter to execute component's bindings
thread  (in) thread associated with 'interp'
cinfo  (in) classinfo for this component

Definition at line 71 of file TclXPCOMComponent.cpp.

References TclXPCOMComponent::cinfo, TclXPCOMStub::component, TclXPCOMComponent::destructor, ClassInfoSignature::infocount, ClassInfoSignature::infolist, TclXPCOMComponent::interp, InterpDeletedCallback, TclXPCOMComponent::nesting, TclXPCOMComponent::refcount, ClassInfo_::signature, TclXPCOMComponent::stubs, and TclXPCOMComponent::thread.

void UnsetDestructorBinding TclXPCOMComponent   component

Unsets a component's destructor.

component  (in) component to unset destructor

Definition at line 115 of file TclXPCOMComponent.cpp.

References TclXPCOMComponent::destructor.

Referenced by FreeTclXPCOMComponent, and SetDestructorBinding.

void SetDestructorBinding TclXPCOMComponent   component,
Tcl_Obj *    script

Sets a component's destructor. This will be executed just before the component is freed.

component  (in) component to set destructor
script  (in) binding

Definition at line 134 of file TclXPCOMComponent.cpp.

References TclXPCOMComponent::destructor, and UnsetDestructorBinding.

Referenced by BindScript.

void FreeTclXPCOMComponent TclXPCOMComponent   component

Frees a Tcl component.

component  (in) component to free

Definition at line 156 of file TclXPCOMComponent.cpp.

References TclXPCOMComponent::cinfo, ClassInfoSignature::infocount, TclXPCOMComponent::interp, InterpDeletedCallback, ClassInfo_::signature, TclXPCOMComponent::stubs, and UnsetDestructorBinding.

int BindScript Tcl_Interp *    interp,
TclXPCOMComponent   component,
Tcl_Obj *    identifier,
Tcl_Obj *    script,
int    flags

Binds a Tcl script to an attribute or method for a Tcl component. If a non-reflectable interface or method is attempted to be bound, an error will be generated. 'flags' can be used to force the binding of a non-reflectable interface or method.

Return values:
TCL_OK  - if the script was successfully bound
TCL_ERROR  - if an error occured
interp  (in) interpreter to store error message
component  (in) component to set binding for
identifier  (in) name of method or attribute to bind
script  (in) binding
flags  (in) override flags

Definition at line 190 of file TclXPCOMComponent.cpp.

References ClassInfo_::attributecount, ClassInfo_::attributes, TclXPCOMComponent::cinfo, TclXPCOMComponent::destructor, FORCE_HIDDEN, FORCE_NOTSCRIPTABLE, FORCE_NOTXPCOM, ClassIdentifierInfo::idinfo, IdentifierInfo_::indices, ClassIdentifierInfo::info, ClassInfoSignature::infocount, ClassInfoSignature::infolist, INTERFACEINFO_GETTER, INTERFACEINFO_METHOD, INTERFACEINFO_SETTER, IsInInterface, ClassInfo_::methodcount, ClassInfo_::methods, IdentifierInfo_::name, TclXPCOMStub::SetBinding, SetDestructorBinding, ClassInfo_::signature, TclXPCOMComponent::stubs, TclXPCOM_CheckInterfaceIsReflectable, TclXPCOM_CheckMethodIsReflectable, and IdentifierInfo_::type.

Generated on Fri Jun 14 23:25:51 2002 for TclXPCOM by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002