C++ vTable binding
C, C++ and C# language use vtable addresses to call COM/DCOM functions.
Additional COM functions are placed after IUnknown/IDispatch vtable entries.
Each function takes size of pointer and function can be called adding the offset in the vtable.
This is the mechanism of C++ compiler to support inheritance and pure virtual functions.
VB, JAVA, scripting ID binding
VB, JAVA, scripting language does not work on vtable entries to call interface functions.
Java and Scripting languages are run time compilable and thus vtable mechanism cannot be fit.
IDispatch interface can fill this gap. It provides four additional functions to know the interface functions and types at runtime.
Programming languages other that C/C++/C# can call GetIDsOfNames with the function name and get the DISP ID number.
This DISP ID number can be passed to Invoke routine to call the same function.
GetTypeInfoCount and GetTypeInfo function can be called to get type information of the interface.
Thus IDispatch interface can support both C/C++/C# as well as other languages like JAVA,VB,JAVA scripts.
This is why IDispatch is known as dual interface.
You have viewed 1 page out of 66. Your COM/DCOM learning is 0.00% complete. Login to check your learning progress.
Similar topics related to this section
COM DCOM Interview Questions and Answers :: ALL Interview .com
COM DCOM - COM DCOM Interview Questions
COM interview questions | TechInterviews
COM Interview Questions - CodeProject
Com Dcom Interview Questions - Com and Dcom in Asp Net
ATL Interview Questions and Answers :: ALL Interview .com
ActiveX Interview Questions and Answers :: ALL Interview .com
| #1 webmaster Fri 02 May/2014 14:34:27(GMT) || 0 || 0|
We are pleased to inform you that a forum/blog has been incorporated with www.mybestnotes.co.in. You are welcomed to add your comments, requests, codes, solutions and feedback to it. Please login(if already a member) or signup(for free) to avail to this facility.
Your message goes here: