期刊文献+

MISRA C++:2008讲座(3) 类的封装与继承 被引量:1

Encapsulation and Inheritance of Class
在线阅读 下载PDF
导出
摘要 面向对象的程序设计语言,如C++,引入了"类"的概念。相似的对象通过归入某一"类"而联系起来。"类"使数据与程序的封装成为可能,让代码更加安全。由此引发的继承等概念,更是大大提高了语言的灵活性。然而使用类的时候,需要十分小心,以免带来潜在的安全隐患。MISRA C++指出了避免这些陷阱的方法。 The concept of class is brought to us by object oriented programming (OOP) language such as C++. Similar objects are connected through a certain class. The adoption of class enhances project safety by means of encapsulation. Furthermore, the inheritance relationship between derived class and base class gives extra flexibility to C++ language. However, in order to keep safety-related problems away, great care needs to be exercised when using class. MISRA C++ shows us how to avoid these traps.
作者 林轶 邵贝贝
机构地区 清华大学
出处 《单片机与嵌入式系统应用》 2009年第11期78-81,共4页 Microcontrollers & Embedded Systems
关键词 封装 继承 MISRA C++ class encapsulation inheritance MISRA C++
  • 相关文献

参考文献4

  • 1Motor Industry Research Association. MISRA-C+ +: 2008 Guidelines for the use of the C++ language in critical systerns[M]. Nuneaton.. MIRA Limted, 2008.
  • 2ISO/IEC. ISO/IEC 14882:2003[S]. New York: American National Standards Institute, 2003.
  • 3Motor Industry Research Association. MISRA Development Guidelines for Vehicle Based Software [M]. Nuneaton: MIRA Limted, 1994.
  • 4DeitelHM,DeitelPJ.C++程序设计教程[M].薛万鹏,等译.北京:机械工业出版社,2000.

同被引文献5

引证文献1

二级引证文献3

相关作者

内容加载中请稍等...

相关机构

内容加载中请稍等...

相关主题

内容加载中请稍等...

浏览历史

内容加载中请稍等...
;
使用帮助 返回顶部