博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
.NET终结了COM? (转)
阅读量:2513 次
发布时间:2019-05-11

本文共 4167 字,大约阅读时间需要 13 分钟。

.NET终结了COM? (转)[@more@]

Is the end of COM?:namespace prefix = o ns = "urn:schemas--com::office" />

 

By David Chappell

 

 

With the exception of NT, is the most important developer technology introduced by Microsoft in the past decade. COM has become ubiquitous, and it is applied today in a large majority of software written for Windows systems.

 

Microsoft now tells us that .NET is the next big thing. The .NET initiative includes a number of technologies, but the most important of these looks to be the .NET . Including a new approach to components based on a Common Language Runtime (CLR), a unified class library and a next-generation development environment called +, the .NET Framework will eventually have an impact on every Windows developer. Microsoft is placing an enormous bet here, and .NET really does look like the next big thing in the Windows world.

 

But what does this mean for COM? While the component technology in the CLR grew out of COM, it isn't COM as we know it today. The CLR does not just h IUnknown and all the rest of COM's mechanics, it completely dispenses with them. Building native applications using the .NET Framework doesn't rely at all on conventional COM technology.

 

So COM must be dead then, right? Not exactly—the truth is a bit more complicated.

 

First, one wholly valid way to think about COM is as a programming model for creating components. To a programmer, this is exactly how COM looks. IUnknown and other COM details have always been hidden from Visual Basic people (who are the largest group of COM developers by far). For this audience, the switch to the CLR-based components in the .NET world should not be traumatic. Viewed as a programming model rather than as a detailed implementation, components in the .NET Framework are literally an ev-olution of COM rather than a replacement for it.

 

Second, Microsoft realizes that lots of COM code exists in the world. Accordingly, interoperability between components built using the .NET Framework and COM is built into the CLR. A .NET Framework component can look like a COM to COM clients, while a COM object can look like a .NET Framework component to a client built using the CLR. Neither of these things requires any significant work for developers, and I expect interoperation to be both easy and common.

 

Third, even applications de-veloped using the .NET Framework will exploit some parts of COM. In particular, the CLR does not attempt to replicate any of the functionality of COM+. .NET Framework applications that need transactions, object pooling and other COM+ services will be deployed wrapped in COM components. Understanding how COM+ works will still be important in a .NET world.

 

Finally, purely COM-based development is not dead. The .NET Framework is not scheduled to shfor some time yet, and so Windows development will continue in its current COM-oriented vein for quite a while. And even after the .NET Framework is available, some projects will likely still use COM rather than .NET. The execution model imposed by the CLR represents real progress for many kinds of applications, but it is not the right answer for everything. Some software, especially system-level code, will still be developed using COM.

 

So does the arrival of .NET mean the end of COM? In some ways, the answer is yes. Building brand-new apps from scratch using the .NET Framework won't require any knowledge of today's COM technology. That technology simply isn't present in the .NET Framework. (Find me the developers, though, who will cry big tears at the thought of never having to deal with COM's details again.)

 

In other important ways, however, COM will go on. As a programming model, as a way to interoperate with existing code, as a technology for transactions and other services, and even as an explicit development foundation, it will definitely get used. COM is not dead.

David Chappell is principal at Chappell & Associates, an education and consulting fifocused on enterprise software technologies. He can be reached via E- at .

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/10748419/viewspace-1000225/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/10748419/viewspace-1000225/

你可能感兴趣的文章
python3 中的try 异常调试与 raise 异常抛出
查看>>
关于md5加密
查看>>
python爬虫小实例
查看>>
查看日志
查看>>
静态文件---访问图片
查看>>
费用流模板
查看>>
Xcode And iOS9新特性
查看>>
问题 C: 质因数的个数
查看>>
Linux iptables开放端口
查看>>
传输层(最重要)
查看>>
20159302《网络攻击与防范》第十周学习总结
查看>>
4. 控制脚本执行顺序
查看>>
SPOJ 3643 /BNUOJ 21860 Traffic Network
查看>>
极速狂飙8 战记
查看>>
20155313 实验一《Java开发环境的熟悉》实验报告
查看>>
rpc简介、原理、实例
查看>>
php函数ob_start()、ob_end_clean()、ob_get_contents()
查看>>
Web Service 和WCF的比较
查看>>
sublime-text3打造markdown编辑器
查看>>
KMP——华丽丽的字符串
查看>>