ATL VS MFC

简介:   ATL vs. MFC In a way, ATL is to COM what MFC is to the Windows API. The goal of ATL is to provide a thin but effective wrapper ...
 

ATL vs. MFC

In a way, ATL is to COM what MFC is to the Windows API. The goal of ATL is to provide a thin but effective wrapper around the most common COM interfaces without sacrificing component performance. Despite this similarity, however, the designs of MFC and ATL differ in several key ways:

MFC contains an interconnected hierarchy of classes, whereas ATL is a set of disjoint templates. This difference means that with ATL you don't pay the size/speed penalty for a given feature unless your component actually uses it.

MFC is linked to a project as a static library or a DLL, but ATL is compiled as source code. Because there are no OBJ files to link to, ATL requires no run-time DLL redistribution. 1

MFC supports a single-inheritance model, whereas the functionality of an ATL component depends entirely on the use of multiple inheritance. Specifically, a component that supports several different COM interfaces will inherit from several different associated ATL templates.

Over time, MFC has grown considerably. As the expectations placed on Windows applications have increased, so have the size and feature set of MFC. Although a similar progression is likely as the use of ATL becomes more prevalent, ATL's use of templates rather than regular inheritance will almost assuredly prevent class proliferation.
目录
相关文章
|
5月前
|
程序员 Windows
08 MFC - MFC框架中一些重要的函数
08 MFC - MFC框架中一些重要的函数
30 0
|
存储 API 数据库
【MFC】MFC基础篇(1)
【MFC】MFC基础篇(1)
【MFC】MFC基础篇(1)
|
IDE 开发工具 C语言
|
存储 索引
|
API 编译器 Linux
(七):处理MFC
版权声明:您好,转载请留下本人博客的地址,谢谢 https://blog.csdn.net/hongbochen1223/article/details/50703886 (一):简介 为了能够在一个Winelib应用中使用MFC,你需要首先使用Winelib重新编译MFC。
1219 0