I read article(s) about COM, and one of those article(s) was here within CodeProject. I need to emphasize on certain points which are not mentioned in each of those article(s) even the one posted here and they causing me big confusion in understanding COM.
1- I know that an interface is simply an abstract type (i.e., includes no implementation to its members just declaration) is the same concept applicable to COM interface(s)?.
2- When I create a COM object I need those two parameters among others: the CLSID and the IID. I knew in advance that you cannot create an object of an abstract type, interface or class, for that reason I need the CLSID which is the GUID for the class that contains the concrete implementation for the member(s) within a given interface which is specified through the IID?
3- What does it mean using the QueryInterface() to get any additional interface pointer? Does that mean if the COM class from which I am instantiating an object, the COM object, is implementing more than one interface and I need those implementation too? if true, that mean if I am having a class C implementing and interface IA and another IB if I create my COM object using only the IID for the interface IA that I will be able to call only methods declared within the interface IA and will not be able to call the methods declared within the interface IB, however, the class itself has the implementation for both interfaces' methods?
4- What does it mean that every other COM interface must be derived from IUnknown? Is that mean if I am going to define a COM interface I need to make it inherit from the IUnknown interface?
5- What are COM identity, lifetime, and binary layout rules?
What I have tried:
I read articles for the Component Object Model, IUnknown, a brief about Application binary interface, Proprietary format, COM Interop.