Click to See Complete Forum and Search --> : Is it mandatory Componet should inherit from COM Interface it supports?


rangacodeguru
February 17th, 2005, 07:33 AM
Hi,

I have the component CA
supporting interface is IA

Acc. to COM specification, it is not must CA should inherit IA
Actually when we quering the Interface (Query Interface) it returns IA pointer , through that we can call Components methods,
Acc. to this CA must inherit IA.

with out inhering how can it posible to work with CA.

can any body explain this..
In my view Component must inherit Interface.......

NMTop40
April 13th, 2005, 04:17 PM
Yes, because inheritance defines an "is-a" relationship.

So your component "is-a" type of the interface it is implementing thus inherits from it.