Find JSRs
Submit this Search

Ad Banner

Summary  |  Proposal  |  Detail (Summary & Proposal)
JSRs: Java Specification Requests
JSR 201: Extending the JavaTM Programming Language with Enumerations, Autoboxing, Enhanced for loops and Static Import

Stage Access Start Finish
Final Release Download page 30 Sep, 2004  
Final Approval Ballot View results 31 Aug, 2004 13 Sep, 2004
Proposed Final Draft 2 Download page 18 Aug, 2004  
Proposed Final Draft Download page 23 Jul, 2004  
Public Review Download page 22 Jan, 2004 21 Feb, 2004
Community Draft Ballot View results 02 Sep, 2003 08 Sep, 2003
Community Review Login page 07 Aug, 2003 08 Sep, 2003
Expert Group Formation   17 Dec, 2002 11 Apr, 2003
JSR Review Ballot View results 03 Dec, 2002 16 Dec, 2002
Status: Final
JCP version in use: 2.6
Java Specification Participation Agreement version in use: 2.0

This JSR proposes four new JavaTM programming language features: enumerations, autoboxing, enhanced for loops and static import.

Please direct comments on this JSR to the Spec Lead(s)

Specification Leads
  Alex Buckley Oracle
Expert Group
  BEA Systems Borland Software Corporation Cartwright, Robert
  Flanagan, David IBM Lea, Doug
  Oracle Peierls, Tim SAS Institute Inc.
  Sun Microsystems, Inc. TmaxSoft, Inc.

Updates to Original JSR

Note that the following information has been updated from the original.


Maintenance Lead: Alex Buckley
E-Mail Address:
Telephone Number: +1 408 276 3065


Maintenance Lead: Danny Coward

E-Mail Address:

Telephone Number: +1 408 276 7049

Fax Number: +1 408 276 7700

Original Java Specification Request (JSR)

Identification | Request | Contributions

Section 1. Identification

Submitting Member: Sun Microsystems

Name of Contact Person: Gilad Bracha, Joshua Bloch

E-Mail Address:,

Telephone Number: +1 408 276 7025, +1 408 276 7022

Fax Number: +1 408 276 7700

Specification Lead: Gilad Bracha, Joshua Bloch

E-Mail Address:,

Telephone Number: +1 408 276 7025, +1 408 276 7022

Fax Number: +1 408 276 7700

Note that this information has been updated from this original proposal.

Initial Expert Group Membership:

Doug Lea
Tim Peierls
Sun Microsystems

Supporting this JSR:

Doug Lea

Section 2: Request

2.1 Please describe the proposed Specification:

The proposal extends the Java programming language in four specific ways:

  1. A syntax for defining enumerated types. This syntax provides linguistic support for the Typesafe Enumeration pattern.

  2. An automatic conversion from primitive types to their corresponding reference type wrappers. This conversion facilitates the integration of generics into the language, and reduces inessential clutter.

  3. Enhanced for loops allow convenient iteration over collections, without the need for an explicitly defined iterator. This reduces the need for boilerplate iteration code and the corresponding opportunities for errors.

  4. Static import. A mechanism to allow the use of unqualified constants.
This JSR will cover at most these four specific language changes. If other language change proposals should arise from the work of the expert group, these will be pursued in new JSRs.

2.2 What is the target Java platform? (i.e., desktop, server, personal, embedded, card, etc.)

All versions of the Java platform

2.3 What need of the Java community will be addressed by the proposed specification?

One of the themes of the Java 2 Standard Edition (J2SETM) "Tiger" release is "Ease of Development". To this end, the Java programming language design team at Sun has been evaluating a wide variety of language proposals.

The Java programming language has been of great benefit to developers in simplifying the construction of large, robust, maintainable programs. It has achieved this by a careful balancing of simplicity and power. Programs are both easy to write and (more importantly) they are easy to read. We have therefore approached the task of updating the Java programming language with considerable trepidation. The existing spirit and features of the language are used by a very large developer community and we wish to avoid disrupting or annoying existing users.

However after careful study, we believe that certain language updates will be non-disruptive and will be widely useful to developers, by improving the overall "Ease of Development" of the Java platform. Three of these changes are already being reviewed through other JSRs:

  • JSR-014 "Add Generic Types To The JavaTM Programming Language"
  • JSR-133 "JavaTM Memory Model and Thread Specification Revision"
  • JSR-181 "A Metadata Facility for the JavaTM Programming Language"

This JSR proposes four smaller language changes that we believe are appropriate for "Tiger". To avoid an excess of small JSRs, it seems appropriate to group these changes into a single JSR.

2.4 Why isn't this need met by existing specifications?

These are language extensions

2.5 Please give a short description of the underlying technology or technologies:

The proposed extensions are all easily implemented by modifications to the source-to-bytecode compiler. No changes to the Java Virtual Machine Specification are required.

2.6 Is there a proposed package name for the API Specification? (i.e., javapi.something, org.something, etc.)


2.7 Does the proposed specification have any dependencies on specific operating systems, CPUs, or I/O devices that you know of?


2.8 Are there any security issues that cannot be addressed by the current security model?


2.9 Are there any internationalization or localization issues?


2.10 Are there any existing specifications that might be rendered obsolete, deprecated, or in need of revision as a result of this work?

The Java Language Specification will require revision

2.11 Please describe the anticipated schedule for the development of this specification.

The JSRs should be concluded by September 1, 2003.

2.12 Please describe the anticipated working model for the Expert Group working on developing this specification.

Experts representing programmers, compiler/IDE vendors and programming language specialists will participate. The specific proposals attached to this JSR will form the starting point for the design. The expert group shall endeavor to work out the exact details of the proposals for inclusion in the 3rd edition of the Java Language Specification. E-mail will be the primary form of communication.

2.13 Please describe how the RI and TCK will de delivered, i.e. as part of a profile or platform edition, or stand-alone, or both. Include version information for the profile or platform in your answer.

This JSR will be delivered as part of the Java Language Specification and J2SE Release 1.5 ("Tiger").

2.14 Please state the rationale if previous versions are available stand-alone and you are now proposing in 2.13 to only deliver RI and TCK as part of a profile or platform edition (See sections 1.1.5 and 1.1.6 of the JCP 2 document).


2.15 Please provide a description of the business terms for the Specification, RI and TCK that will apply when this JSR is final.

This JSR will be delivered as part of J2SE 1.5 "Tiger". The proposed J2SE 1.5 licensing terms are available at J2SE 1.5 licensing terms.

Section 3: Contributions

3.1 Please list any existing documents, specifications, or implementations that describe the technology. Please include links to the documents if they are publicly available.

Draft specs for enumerations, autoboxing, enhanced for loop, static import are being made available concurrently with the release of this JSR.

3.2 Explanation of how these items might be used as a starting point for the work.

The proposals provide an initial specification of the desired features. They need to be refined into
JLS level specifications.