...
首页> 外文期刊>C - C++ Users Journal >C++/CLI Interfaces & Generic Types
【24h】

C++/CLI Interfaces & Generic Types

机译:C ++ / CLI接口和通用类型

获取原文
获取原文并翻译 | 示例

摘要

This month, I examine how you define C++/CLI implementation contracts, called "interfaces." Sometimes it is useful to have unrelated classes behave in similar ways by having them share a common set of public members. One way you can achieve this is to define them with a common base class; however, this approach is limiting because it requires that these classes be related via inheritance, yet they might each already have a base class of their own, and CLI types support single-class inheritance only.
机译:本月,我将研究如何定义称为“接口”的C ++ / CLI实现合同。有时,让不相关的类通过共享一组公共成员来以相似的方式表现是有用的。实现此目的的一种方法是使用通用的基类定义它们。但是,这种方法是有局限性的,因为它要求通过继承将这些类关联起来,但是它们可能已经各自具有自己的基类,并且CLI类型仅支持单类继承。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号