Static fields and methods are supposed to represent stateless attributes of a class;
静态域和方法都应该代表一类无国籍属性;
This is unusual because it requires a developer to create an instance of an object just to access non-instance (static) methods and fields!
这种做法并不常见,因为需要开发人员创建仅用于访问非实例(静态)方法和字段的对象的实例。
Support for importing constants: This facility allows static methods and fields to be imported, avoiding the need to use fully qualified class names when accessing static members.
支持导入常量:这个特性使静态方法和字段能够被导入,这样在访问静态成员时就不必使用完全限定的类名。
应用推荐