gpt4 book ai didi

java - 类字面量是如何工作的?

转载 作者:行者123 更新时间:2023-11-29 07:10:33 24 4
gpt4 key购买 nike

<分区>

Possible Duplicate:
What is a class literal in Java?

我正在浏览 the Java tutorial 中的文字我在哪里遇到这句话:

Finally, there's also a special kind of literal called a class literal, formed by taking a type name and appending ".class"; for example, String.class. This refers to the object (of type Class) that represents the type itself.

这对我来说没有任何意义,尽管在此之前我已经关注了所有其他主题。任何人都可以用简单的语言用例子或引用资料解释吗?

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com