网站首页  英汉词典

请输入您要查询的英文单词:

 

单词 metaclass
释义

metaclass

英汉-汉英词典
n. 元类
词组 | 习惯用语
您要查找的是不是:
  • meticulous adj. 极仔细的; 一丝不苟的
  • cataclysm n. 大洪水;地震;(社会政治的)大变动
  • metastasis n. 转移
  • metastases n. 移位变化
metaclass n. 元类

网络短语:
metaclass programming 元类程序设计
metaclass producer 以带有元类生成器
metaclass object 元类对象
root metaclass 根元类
metaclass s 元类
英语百科

Metaclass

Diagram of the inheritance and instance relationships between classes and metaclasses in Smalltalk
Diagram of the inheritance and instance relationships between classes and metaclasses in Objective-C. Note that Objective-C has multiple root classes; each root class would have a separate hierarchy. This diagram only shows the hierarchy for an example root class   NSObject. Each other root class would have a similar hierarchy.

In object-oriented programming, a metaclass is a class whose instances are classes. Just as an ordinary class defines the behavior of certain objects, a metaclass defines the behavior of certain classes and their instances. Not all object-oriented programming languages support metaclasses. Among those that do, the extent to which metaclasses can override any given aspect of class behavior varies. Metaclasses can be implemented by having classes be first-class citizen, in which case a metaclass is simply an object that constructs classes. Each language has its own metaobject protocol, a set of rules that govern how objects, classes, and metaclasses interact.

随便看

 

英汉网英语在线翻译词典收录了3779314条英语词汇在线翻译词条,基本涵盖了全部常用英语词汇的中英文双语翻译及用法,是英语学习的有利工具。

 

Copyright © 2004-2024 encnc.com All Rights Reserved
更新时间:2025/6/19 9:24:19