Hi Joe, thanks for the link. I'm not sure now whether I am confusing myself or not ;)

In CPP I could declare:

class nsMyClass : public nsInheritClass,public nsIInheritInterface

I had assumed I could achieve functionally the same in IDL to allow my Javascript Interface to inherit from an existing IDL interface.

I'll checkout the encapsulation that you mentioned.

Cheers,

Neil


Joe Jones wrote:
Remember that an interface can only inherit other interfaces. A class can
implement one or more interfaces and dress itself up as a COM component,
but it can't inherit an implementation from another COM component. If this
was what you are wanting, sorry.

You can however wrap an existing component in a new one, forwarding method
calls to it, and adding your own functionality where needed.This is called
encapsulation in COM speak, in think.

Have a look at http://books.mozdev.org/html/mozilla-chp-8-sect-2.html should
get you started.

Joe

------------------------------------------------------------------------- The difference between programming and engineering is that engineers will lie, cheat and steal, programmers will not. ------------------------------------------------------------------------- _______________________________________________ Mozilla-xpcom mailing list [EMAIL PROTECTED] http://mail.mozilla.org/listinfo/mozilla-xpcom

Reply via email to