在哪里可以阅读有关D的类访问修饰符的更多信息? [英] Where can I read more about D's class access modifiers?
本文介绍了在哪里可以阅读有关D的类访问修饰符的更多信息?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我似乎找不到 D 编程的好参考语言类访问修饰符。
I can't seem to find a good reference for the D programming language class access modifiers.
我知道 public
和 private
几乎可以保证,但是我想还有更多,我似乎找不到很好的信息来源。
I know that public
and private
are pretty much guaranteed but i'm guessing there are more, i just can't seem to find a good source of information.
有人可以指出我一个
推荐答案
您可以在 dlang.org
简而言之:
-
private
,只能在同一模块(文件)中访问
private
, is only accessible in the same module (file)
软件包
,只能在同一软件包中访问
package
, is only accessible in the same package
受保护的
,是模块+继承的类
public
(也默认值)可在
export
用于在编写库时导出函数
export
is use to export functions when you are writing libraries
这篇关于在哪里可以阅读有关D的类访问修饰符的更多信息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文