简体   繁体   English

在哪个版本的Java中引入了匿名类?

[英]In which version of Java were anonymous classes introduced?

The purpose of anonymous classes is clear and understandable. 匿名类的目的是清楚易懂的。 But I'm unable to find the minimum version of Java which supports anonymous classes. 但我无法找到支持匿名类的Java的最低版本。 Can anyone tell me the exact Java version which supports it? 谁能告诉我支持它的确切Java版本?

Java 1.1 Java 1.1

Source: https://www.cs.cornell.edu/andru/javaspec/1.1Update.html 资料来源: https//www.cs.cornell.edu/andru/javaspec/1.1Update.html

Details: Added along with inner classes. 细节:与内部类一起添加。 Anonymous classes are a type of Inner Class ( https://en.wikipedia.org/wiki/Inner_class ). 匿名类是一种内部类( https://en.wikipedia.org/wiki/Inner_class )。 Inner classes were introduced in Java 1.1 ( https://en.wikipedia.org/wiki/Java_version_history ). 内部类在Java 1.1中引入( https://en.wikipedia.org/wiki/Java_version_history )。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM