[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: dlsym() and C++





Magnus Norddahl wrote:

> > what I've read about OLE, the COM model is a pretty
> > neat way around this.  It works by putting the functions
> I dislike the way COM works. When you upgrade your COM interface, you have
> to do a QueryInterface to get the new one. Not very nice. I hate it when
> using DirectX...

I'm not following here.  If you upgrade the *interface* you're
adding new members, right, so you'll have to know the new
interface to use it, wether you access it directly or through
the Query...  Replacing the COM object to have a different
implementation of the same interface is not really an
upgrade from the client's point of view, it's rather
maintenance; if you really want to use new functions you'll
have to know them, the only difference between native C++
and COM is that COM allows you to (truly) upgrade
client and object independetly, typically first a new object,
then the new client.
In short, if your code doesn't need changes if the interface
changes, it's by definition an implementation only change;
if something really does change, you always need code
changes, both with .h or Query...

Bert
--

-=<Short Controlled Bursts>=-