RE: [GD-General] Multiple Inheritance and RTTI
Brought to you by:
vexxed72
From: Donavon K. <kei...@ea...> - 2003-02-09 04:32:30
|
This is one of those times where I wish I'd looked more carefully at what I wrote before sending it. My comments sound pretty uncharitable but this company has a lot of talented people who have done some really great stuff. I'm sure some people here know which company this is and may even be working there, so if I stepped on any toes, I regret it. --Charm School Dropout > -----Original Message----- > From: gam...@li... > [mailto:gam...@li...] On Behalf Of > Donavon Keithley > Sent: Saturday, February 08, 2003 12:28 AM > To: gam...@li... > Subject: RE: [GD-General] Multiple Inheritance and RTTI > > Instantiating a class by some means other than CoCreateInstance[Ex] is > not re-implementing COM. Many, many standard COM objects are not > co-creatable (if I remember the jargon correctly). Like... D3D, for > instance. > > COM only has a few mandatory rules, like implementing IUnknown and > adhering to certain QueryInterface semantics. It's not much of an > imposition and it leaves you open to interoperating with the rest of the > COM world. Implement a typelib and adhere to some basic type rules and > your objects will be callable from Visual Basic and .NET. Implement > IDispatch and you open your objects up to the scripting world. > > Just don't do what one company I know did, and that's redefine IUnknown. > They called it "IUnknown", it had QI, AddRef, and Release, but IIDs were > strings, not GUIDs. So their "custom" COM system looked just like COM, > but it was totally incompatible. There was no possibility of interop > and where they could have taken advantage of ATL's rich set of classes, > they instead had to redefine their own macros and template classes. > > It was an utterly pointless exercise in NIH. > > Donavon |