|
I went to the Sun UK Developer Update on 19 Mar 2009
and this is what Simon Ritter had to say about...
Java SE 7
Java SE 7 has been a long time coming, partly due to the distractions
of open sourcing Java and engineering efforts on Java FX, but
it is now due out beginning/early 2010.
Fewer features are better as potential features have to be weighed up
against the constraints of future expansion of the language and
compatibility with the abstract model of Java.
|
What will be in Java SE 7 (subject to change)
- JSR tbd - Small language changes (see below)
- JSR 294 - Language and VM changes to improved modularity support (see below)
- JSR 292 - Supporting Dynamically Typed Languages (can give up to 10 times speed increase for dynamic languages, but will now not include any new bytecode)
- JSR 203 - More New I/O APIs including native filesystem access
java.nio.file package - FileSystem, FileRef, Path
- JSR 296 - a simple application framework for Swing applications
- SCTP - Stream Control Transport Protocol
- SDP - Session Description Protocol
- Changes to the class loader architecture
- Unicode 5.0 support
- new Date Picker in Swing
- JSR 166y - lightweight concurrent task framework known as ForkJoin
java.util.concurrent.forkjoin package
The main two features to write home about though appear to be...
- JSR 294 - Language and VM changes to improved modularity support
The new module system will allow a way for the very old deprecated methods to go.
- JSR 277 Java Module System (JAM) - Sun will be discontinuing their input to this JSR
- JSR 294 Language extensions in support of information hiding and separate compilation - Sun looking to get this JSR going
- Simon Ritter also mentioned Project Jigsaw and OSGi, all of which is much better explained here
- JSR tbd - Small language changes
-
If a caught exception is declared final, it is safe to rethrow any caught exception.
Because the catch parameter is final, it can only hold exceptions that are thrown from the try block.
try {
...
} catch (final Throwable t) {
throw t;
}
-
Multicatch - Support catch clauses that catch multiple exception types
} catch (Exception1, Exception2 ex) {
throw ex;
}
- Null dereference operator (?.)
if (a!=null) {
a.b()
}
becomes
a?.b()
- Syntax sugar for Generics
Map<String, BigDecimal> = new HashMap<String, BigDecimal>();
becomes
Map<String, BigDecimal> = new HashMap<>();
- JSR 308 - type annotations
List<@NonNull String> strongList;
- Concurrency and collections updates
The following items are not going to be in Java SE 7
|