FAQ 34.19 Is COM object oriented?

graphics/new_icon.gif

Yes, COM delivers all the major benefits of object technology (although some purists disagree).

Each COM class has a unique class identifier and implements one or more interfaces. An interface is a group of functions that provide a set of related services. A COM object is an instance of a COM class. A COM class can be used to create many separate COM objects. These definitions are similar to C++ where classes have unique identifiers and objects are instances of classes.

Most developers using COM could not care less about whether or not COM is "truly" object oriented. As far as they are concerned, it gives them the benefits of object orientation and that is all that counts:

  • You can define classes.

  • You can use the classes to create objects.

  • The classes have well-defined interfaces and the implementations of the classes are fully encapsulated.

  • Interfaces can be defined using inheritance and interface pointers are polymorphic.



C++ FAQs
C Programming FAQs: Frequently Asked Questions
ISBN: 0201845199
EAN: 2147483647
Year: 2005
Pages: 566
Authors: Steve Summit

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net