Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What Java feature(s) historically started as a pattern and is now a language feature? [closed]

I'll be honest. I need help with a homework question that I'm stumped with.

Describe something that historically started as a pattern and is now supported with a language feature in Java.

like image 555
chuck Avatar asked Mar 14 '11 16:03

chuck


People also ask

What is the historical development of Java?

Java was originally developed by James Gosling at Sun Microsystems. It was released in May 1995 as a core component of Sun Microsystems' Java platform. The original and reference implementation Java compilers, virtual machines, and class libraries were originally released by Sun under proprietary licenses.

What was the initial name of Java when it was first developed for embedded systems?

2) Initially it was designed for small, embedded systems in electronic appliances like set-top boxes. 3) Firstly, it was called "Greentalk" by James Gosling, and the file extension was . gt. 4) After that, it was called Oak and was developed as a part of the Green project.

What was the main feature that made Java programming language so popular?

One of the biggest reasons why Java is so popular is the platform independence. Programs can run on several different types of computer; as long as the computer has a Java Runtime Environment (JRE) installed, a Java program can run on it.


1 Answers

They're probably looking for enums.

Before Java 1.5 introduced language support for enums, standard practice was to define a set of public static final ints as enum values.
This pattern can be seen all over Swing.

Many of these constants are defined in interfaces so that classes can implement the interface and use the constants without a qualifying typename; the SwingConstants interface is a great example.

like image 139
SLaks Avatar answered Oct 19 '22 12:10

SLaks