What is a component of C + + COM programming? _c language

Source: Internet
Author: User
Tags object model

What is a component?

A component is similar to a micro application, which is already compiled, linked, and ready to use, and the application is packaged with multiple such components. Custom components can be connected to other components at run time to form an application. When you need to modify or improve an application, simply replace one of the components that make up this application with a new version.

COM components

COM, the Component Object model, is a specification that demonstrates how to build a dynamic, interactive component that provides some of the standards that customers and components should follow to ensure interoperability.

COM components are executable code published in the form of a WIN32 dynamic-link library (DLLs) or executable (exes). COM components must meet the following conditions:

1.COM components are completely language-independent;
2.COM components can be published in binary form;
3.COM components can be upgraded without interfering with old customers;

A COM component can be transparently reassigned to a location on the network.

Advantages of using Components

1. Application Customization

Component architectures are inherently customizable, as users can replace a component with components that are more responsive to their needs;

2. Component Library

One of the most compelling advantages of component architecture is rapid application development. This advantage allows the developer to remove the required components from a component library and assemble them quickly into a piece to construct the required application, like building blocks;

3. Distributed components

Component architectures can simplify the process of developing such distributed applications. In fact, a client/server application is the first step to a component architecture. Where the entire application is divided into two parts: the client part and the server part.

Summarize

COM provides a standard way to write components. Components that follow COM standards can be grouped together to form applications. It doesn't matter who wrote the components and how they were implemented. Each COM component can be used in conjunction with other components. The key issue in implementing this dynamically changing component is the encapsulation of information. For encapsulation, COM is implemented through a connection or interface between the component and the customer. For the interface, I'll summarize the next blog post.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.