Main Page   Compound List   File List   Compound Members   File Members  

TclXPCOMStub Class Reference

#include <TclXPCOMPrivate.h>

List of all members.

Public Methods

 TclXPCOMStub (nsIInterfaceInfo *interfaceinfo)
 ~TclXPCOMStub (void)
NS_IMETHOD QueryInterface (REFNSIID aIID, void **aInstancePtr)
 NS_IMETHOD_ (nsrefcnt) AddRef(void)
 NS_IMETHOD_ (nsrefcnt) Release(void)
NS_IMETHOD GetInterfaceInfo (nsIInterfaceInfo **info)
NS_IMETHOD CallMethod (PRUint16 methodIndex, const nsXPTMethodInfo *info, nsXPTCMiniVariant *params)
void SetBinding (PRUint16 methodindex, Tcl_Obj *script)
void UnsetBinding (PRUint16 methodindex)
Tcl_Obj * GetBinding (PRUint16 methodindex)

Public Attributes

nsIInterfaceInfo * info
 pointer to the Interface information. More...

TclXPCOMComponent * component
 pointer to the component information. More...

Tcl_Obj ** bindings
 script bindings to interface method. More...


Constructor & Destructor Documentation

TclXPCOMStub::TclXPCOMStub (  nsIInterfaceInfo *    interfaceinfo ) 
 

Creates a new TclXPCOM interface stub object.

Returns:
a new stub object
Parameters:
interfaceinfo  (in) interface info for the stub

Definition at line 45 of file TclXPCOMStub.cpp.

References bindings, and info.

TclXPCOMStub::~TclXPCOMStub (  void    ) 
 

Deletes this TclXPCOM interface stub object.

Definition at line 72 of file TclXPCOMStub.cpp.

References bindings, info, and UnsetBinding.


Member Function Documentation

NS_IMETHODIMP TclXPCOMStub::QueryInterface (  REFNSIID    aIID,
void **    aInstancePtr
) 
 

Processes the QueryInterface method for this interface stub.

Returns:
an XPCOM result code
Parameters:
aIID  (in) requested interface
aInstancePtr  (out) address to store interface pointer

Definition at line 206 of file TclXPCOMStub.cpp.

References bindings, TclXPCOMComponent::cinfo, component, info, ClassInfoSignature::infocount, TclXPCOMComponent::interp, isInInterface, TclXPCOMComponent::nesting, nsisupportsweakreference_iid, ClassInfo_::signature, TclXPCOMComponent::stubs, TclXPCOM_CallMethod, and TclXPCOMComponent::thread.

TclXPCOMStub::NS_IMETHOD_ (  nsrefcnt    ) 
 

TclXPCOMStub::NS_IMETHOD_ (  nsrefcnt    ) 
 

NS_IMETHODIMP TclXPCOMStub::GetInterfaceInfo (  nsIInterfaceInfo **    interfaceinfo ) 
 

Retrieves the interface info pointer for this interface stub.

Returns:
an XPCOM result code
Parameters:
interfaceinfo  (out) address to store interface info

Definition at line 151 of file TclXPCOMStub.cpp.

References info.

NS_IMETHODIMP TclXPCOMStub::CallMethod (  PRUint16    methodIndex,
const nsXPTMethodInfo *    info,
nsXPTCMiniVariant *    params
) 
 

Executes a binding on this interface stub.

Returns:
an XPCOM result code
Parameters:
methodIndex  (in) attribute/method to execute binding for
info  (in) method info of interface method being invoked
params  (in) arguments to method

Definition at line 169 of file TclXPCOMStub.cpp.

References bindings, component, info, TclXPCOMComponent::interp, TclXPCOM_CallMethod, and TclXPCOMComponent::thread.

void TclXPCOMStub::SetBinding (  PRUint16    methodindex,
Tcl_Obj *    script
) 
 

Sets an attribute/method binding for this interface stub. If a binding already exists for the given attribute/method, then that binding will be released.

Parameters:
methodindex  (in) attribute/method to bind to
script  (in) script to execute

Definition at line 98 of file TclXPCOMStub.cpp.

References bindings, and UnsetBinding.

Referenced by BindScript.

void TclXPCOMStub::UnsetBinding (  PRUint16    methodindex ) 
 

Removes an attibute/method binding from this interface stub.

Parameters:
methodindex  (in) attribute/method to clear binding for

Definition at line 119 of file TclXPCOMStub.cpp.

References bindings.

Referenced by SetBinding, and ~TclXPCOMStub.

Tcl_Obj * TclXPCOMStub::GetBinding (  PRUint16    methodindex ) 
 

Retrieves an attribute/method binding from this interface stub.

Returns:
a Tcl object containing the script that was bound
Parameters:
methodindex  (in) attribute/method to retrieve binding for

Definition at line 137 of file TclXPCOMStub.cpp.

References bindings.


Member Data Documentation

nsIInterfaceInfo* TclXPCOMStub::info
 

pointer to the Interface information.

Definition at line 222 of file TclXPCOMPrivate.h.

Referenced by CallMethod, GetInterfaceInfo, QueryInterface, TclXPCOMStub, and ~TclXPCOMStub.

struct TclXPCOMComponent* TclXPCOMStub::component
 

pointer to the component information.

Definition at line 223 of file TclXPCOMPrivate.h.

Referenced by CallMethod, NewTclXPCOMComponent, and QueryInterface.

Tcl_Obj** TclXPCOMStub::bindings
 

script bindings to interface method.

Definition at line 224 of file TclXPCOMPrivate.h.

Referenced by CallMethod, GetBinding, QueryInterface, SetBinding, TclXPCOMStub, UnsetBinding, and ~TclXPCOMStub.


The documentation for this class was generated from the following files:
Generated on Fri Jun 14 23:25:52 2002 for TclXPCOM by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002