共查询到20条相似文献,搜索用时 149 毫秒
1.
编制灵活的应用程序框架系统,反射机制是重要的实现手段。但由于C++本身没有成熟的反射技术,对此进行了深入研究并提出一种实现方法。首先论述了反射机制的作用;然后描述了ATL动态链接库实现反射机制的基本原理,完善了ATLIDL文件接口标识符定义,利用前绑定或后绑定技术实现反射机制,比较了这两种方法的不同之处,着重强调了Idispatch接口在实现反射机制中的作用,最后给出需要继续研究的问题。由于采用了动态链接库技术,方便了构件的维护和复用,有助于团队开发和分布式开发。 相似文献
2.
3.
4.
5.
当前的中间件系统缺乏灵活性和适应性,难以适应环境改变和不同用户需求。反射机制提供了系统所需灵活性和适应性的理论方法,而对元信息的表示和管理是实现反射机制的关键。首先介绍了反射机制的原理;然后重点阐述了对元信息的管理,给出了关于元信息管理的现有标准;最后给出一个服务质量(QoS)管理的构架模型,并提出了中间件领域所面临的一些挑战。 相似文献
6.
袁辉 《电脑编程技巧与维护》2009,(17):32-35
Java中的反射机制可以让用户动态地操作Java代码,在许多专业程序中都使用了反射机制。文中简要介绍了反射机制及其基本用法,并通过在表模型中使用反射机制的实例.说明如何在应用程序中使用反射机制。 相似文献
7.
构件的封装性好,标准接口易用方便,可以帮助研究人员节省大量的宝贵时间,对提高构件的质量有积极的作用。针对目前自动测试存在的缺陷,提出CAR反射机制理论,对构件的自动测试进行了深入的研究,在此基础上提出了一种基于car技术的自动测试的模型,并进行了系统实现。具体包括:CAR反射机制;测试用例模型设计与实现;自动运行测试程序。 相似文献
8.
ORM技术和反射技术已经在java语言中得到了大量的应用,但是在C++环境中这些技术由于语言本身限制尚未大量应用。该文结合一个小型财务软件的实现,讨论了在C++环境下这两种技术的应用,以及出现的问题。 相似文献
9.
10.
综合运用VMIPCI-5565反射内存卡构建反射内存实时网络技术和多组件组合技术,完成C++Builder开发环境下飞控实时仿真控制系统的研究。该系统以图形化可控界面形式显示,主要实现了系统初始化配置、系统通讯、系统实时性控制和数据管理等功能。结果表明,系统通讯稳定实时性强,数据传输高效准确,可视化效果良好,并具有较强的开放性和可拓展性。 相似文献
11.
The meaning of the term `object oriented' is examined in the context of the general-purpose programming language C++. This choice is made partly to introduce C++ and partly because C++ is one of the few languages that supports data abstraction, object-oriented programming, and traditional programming techniques. The support of programming paradigms by languages is discussed and four paradigms are examined: procedural, data hiding, data abstraction, and object-oriented programming. The support of the latter two by C++ is discussed in some detail 相似文献
12.
13.
A style of programming that uses higher-order functions has become common in C++, following the introduction of the Standard Template Library (STL) into the standard library. In addition to their utility as arguments to STL algorithms, function parameters are useful as callbacks on GUI events, defining tasks to be executed in a thread, and so forth. C++’s mechanisms for defining functions or function objects are, however, rather verbose, and they often force the function’s definition to be placed far from its use. As a result, C++ frustrates programmers in taking full advantage of its own standard libraries. The effective use of modern C++ libraries calls for a concise mechanism for defining small one-off functions in the language, a need that can be fulfilled with lambda expressions.This paper describes a design and implementation of language support for lambda expressions in C++. C++’s compilation model, where activation records are maintained in a stack, and the lack of automatic object lifetime management make safe lambda functions and closures challenging: if a closure outlives its scope of definition, references stored in a closure dangle. Our design is careful to balance between conciseness of syntax and explicit annotations to guarantee safety. The presented design is included in the draft specification of the forthcoming major revision of the ISO C++ standard, dubbed C++0x. In rewriting typical C++ programs to take advantage of lambda functions, we observed clear benefits, such as reduced code size and improved clarity. 相似文献
14.
Concurrent C/C++ is a superset of C and C++ that provides parallel programming facilities based on message passing. Upon porting Concurrent C/C++to a shared memory multiprocessor, the authors believed it would be appropriate to supplement Concurrent C/C++ with explicit facilities for synchronizing accesses to shared data structures. The capsule, which is a shared memory access mechanism designed especially for Concurrent C/C++ to match the C++data abstraction facility called the class, is discussed. Capsules are like monitors but they have significant advantages. Capsules satisfy T. Bloom's (1979) criteria for expressiveness of synchronization conditions, support inheritance, allow operations to execute in parallel, and permit them to time out. The design of capsules is reviewed. The author evaluates existing shared memory mechanisms, describes capsules, gives examples of capsules, compares capsules with monitors, and discusses how capsules are implemented by the Concurrent C compiler 相似文献
15.
Matlab具有很强的数值计算和分析等能力,而C/C++是目前最为流行的高级程序设计语言,两者互补结合的混合编程在科学研究和工程实践中具有非常重要的意义。从Matlab调用C/C++代码及C/C++调用m文件两方面,深入地研究了它们之间混合编程的原理和实现机制,并且给出了具体条件下的混合编程方法和步骤。实验表明,给出的Matlab与C/C++混合编程接口及应用方法是有效、实用的。 相似文献
16.
内存泄漏是程序设计中经常出现的问题,会降低系统性能,甚至耗尽内存空间导致系统崩溃。文章采用反射和开放编译技术,对开放编译器OpenC 进行了扩展与改进,设计并实现了一个CC 动态内存泄漏检测工具,以帮助开发和测试人员查找内存泄漏。 相似文献
17.
18.
高永丽 《数字社区&智能家居》2009,(32)
作为面向对象程序设计方法的示范性语言,C++以其高效、灵活独特的语言机制在计算机科学的教育和各个领域被广泛的应用,该文结合多年教学经验,分析一些C++初学者的问题与困惑,提出几点适合C++学习者的学习方法和技巧,对提升C++程序设计学习者的学习质量将起到积极的意义。 相似文献
19.
本文通过C++语言程序设计的实习,提出了目前存在的问题。通过分析其理论实践意义、具体解决方案和具体实施过程,论述了如何将学生工程能力的培养贯穿于C++语言程序设计的教学中。 相似文献
20.
本文讨论了Win32环境下应用程序的一般机制与特点,论述了基于Windows操作系统和x86指令集的汇编语言程序设计方法,分析了依赖于Visual C 开发环境的函数调用约定.通过对比C 和汇编程序,给出一个混合编程的实例,结果说明了两种语言函数之间的等价性. 相似文献