您好,欢迎来到中国测试科技资讯平台!

首页> 《中国测试》期刊 >本期导读>用ATL开发异步调用组件

用ATL开发异步调用组件

2553    2016-01-19

免费

全文售价

作者:古云波

作者单位:上海宝山钢铁股份公司, 上海 201900


关键词:组件对象模型; 异步; ATL组件; 多线程


摘要:

异步与分布式应用软件系统在工程领域有着广泛的应用,有必要寻找一种快速高效地构筑异步系统的方法,微软的组件对象模型COM可以很好地满足这方面的需要。首先概述开发异步调用组件的意义和工具,以及所涉及到的COM基本概念,包括接口、事件、连接点、线程模型等,并结合一个具体工程实例详述了在Visual C++6.0编程环境下用ATL开发异步调用组件的方法,最后对组件进行了测试并顺利通过,证明了COM开发此类异步应用系统的高效性。


Developing asynchronous component with ATL

GU Yun-bo

Baoshan Iron and Steel Co. Ltd., Shanghai 201900, China

Abstract: Asynchronous and distributed application programs are widely used in engineering, and it is necessary to develop an effective way to construct such systems. The component object model (COM) can meet this demand perfectly. In this article, the mechanism and developing tool of asynchronous COM programming were introduced, along with some essential concepts such as interface, event, connection point, threading mode and so on. Then a factory implementation instance was put forward to illustrate the method of asynchronous component programming by using ATL under Visual C++6.0 environment. Finally, it proves that COM is a highly effective tool for developing such asynchronous application program through the test results.

Keywords: COM; asynchrony; ATL; multithreading

2011, 37(6): 87-90  收稿日期: 2010-11-18;收到修改稿日期: 2011-2-23

基金项目: 

作者简介: 古云波(1972-),男,山东五莲县人,工程师,硕士,主要从事计算机与工业过程控制研究工作。

参考文献

[1] 胡喜玲. 组件对象模型-COM的研究[J]. 计算机与网络, 2008,34(17):62-64.
[2] Rector B, Sells C. 深入解析ATL[M]. 北京:中国电力出版社,2001.
[3] Microsoft. MSDN library visual studio 6.0[Z]. Microsoft,2005.
[4] Box D, Ewald T, Brown K, et al. COM高手心经[M]. 北京:科学出版社,2003.
[5] 刘辉,智明,柳先辉. COM+组件执行环境和线程同步的研究[J]. 计算机应用研究,2004(3):136-138.
[6] 杜树杰,林舰,张亚梅. 基于COM/DCOM组件的分布式系统开发模式分析[J]. 现代计算机,2007(10):116-117.
[7] 黄晓宇. 基于COM组件/服务器模式的控制系统仿真设计[J]. 中国电力教育,2005(Z2):20-23.
[8] 管建和,王绍燕. 基于ATL实现通用报表工具COM控件[J].计算机工程与设计,2007,28(17):4241-4242.
[9] 王志飞. 基于COM的数据访问组件的实现[J]. 计算机应用与软件,2005,22(9):70-72.
[10] 王影. VC++中访问COM组件的五种方法[J]. 计算机时代,2005(12):24-26.