10 Replies - 4166 Views - Last Post: 03 December 2009 - 09:18 AM

#1 Mikhail  Icon User is offline

  • Bastard Operator From Hell
  • member icon

Reputation: 58
  • View blog
  • Posts: 1,378
  • Joined: 26-October 07

New language features in Java 7

Post icon  Posted 26 November 2009 - 12:22 AM

Quote

Iím just back from the Devoxx conference in Antwerp. An update was given on the new language changes that will be in Java 7. The JDK currently has a release date of September 2010.

Here are 7 of the new features that have been completed:

* Language support for collections
* Automatic Resource Management
* Improved Type Inference for Generic Instance Creation (diamond)
* Underscores in numeric literals
* Strings in switch
* Binary literals
* Simplified Varargs Method Invocation

There is a lot more to Java 7 then just these language changes. Iíll be exploring the rest of the release in future posts. One of the big debates is currently around Closures, which are a separate JSR.


New Features in Java 7 Complete List

Sounds interesting, however I don't think Ill have much need for those.

Post your opinions.

Is This A Good Question/Topic? 0
  • +

Replies To: New language features in Java 7

#2 KYA  Icon User is offline

  • g++ jameson.cpp -o beverage
  • member icon

Reputation: 3093
  • View blog
  • Posts: 19,139
  • Joined: 14-September 07

Re: New language features in Java 7

Posted 26 November 2009 - 03:03 PM

Out of all of that binary literals are the only interesting/possibly useful thing I see. Everything else, *yawn*.

The one that all it does is require less typing is just retarded. [diamond operator]

There wasn't anything else that could be implemented? crtl x + crtl v = profit
Was This Post Helpful? 0
  • +
  • -

#3 markhazlett9  Icon User is offline

  • Coding is a lifestyle
  • member icon

Reputation: 60
  • View blog
  • Posts: 1,666
  • Joined: 12-July 08

Re: New language features in Java 7

Posted 26 November 2009 - 03:14 PM

I have to say, personally I am going to enjoy the ability to use string's in switch statements :D

Also, the automatic resource management is going to be pretty cool if it works right :D
Was This Post Helpful? 0
  • +
  • -

#4 Dogstopper  Icon User is offline

  • The Ninjaducky
  • member icon



Reputation: 2870
  • View blog
  • Posts: 11,021
  • Joined: 15-July 08

Re: New language features in Java 7

Posted 26 November 2009 - 03:23 PM

View Postmarkhazlett9, on 26 Nov, 2009 - 04:14 PM, said:

I have to say, personally I am going to enjoy the ability to use string's in switch statements :D

Also, the automatic resource management is going to be pretty cool if it works right :D


That! Also I like the underscores in numbers...very creative idea...
Was This Post Helpful? 0
  • +
  • -

#5 macosxnerd101  Icon User is offline

  • Self-Trained Economist
  • member icon




Reputation: 10364
  • View blog
  • Posts: 38,390
  • Joined: 27-December 08

Re: New language features in Java 7

Posted 26 November 2009 - 06:58 PM

View PostKYA, on 26 Nov, 2009 - 06:03 PM, said:

Out of all of that binary literals are the only interesting/possibly useful thing I see. Everything else, *yawn*.

The one that all it does is require less typing is just retarded. [diamond operator]

There wasn't anything else that could be implemented? crtl x + crtl v = profit


I agree with KYA. The binary literals will be interesting and possibly useful, & the diamond operator is convenient, but nothing else jumps out at me.
Was This Post Helpful? 0
  • +
  • -

#6 Programmist  Icon User is offline

  • CTO
  • member icon

Reputation: 252
  • View blog
  • Posts: 1,833
  • Joined: 02-January 06

Re: New language features in Java 7

Posted 27 November 2009 - 02:25 PM

Devoxx 09 on Parleys: for anyone who wants to watch some of the talks. Lots of interesting info. Plus, the Java Posse Rickrolled their audience. :)

This post has been edited by Programmist: 27 November 2009 - 02:25 PM

Was This Post Helpful? 0
  • +
  • -

#7 chili5  Icon User is offline

  • D.I.C Lover

Reputation: 19
  • View blog
  • Posts: 1,144
  • Joined: 28-December 07

Re: New language features in Java 7

Posted 28 November 2009 - 06:42 AM

I like the strings in switch, it's a great idea. I also like the ability to do this:

map["b"] = "yay!";



that is going to make life a lot easier. =)
Was This Post Helpful? 0
  • +
  • -

#8 magedx9  Icon User is offline

  • New D.I.C Head

Reputation: 1
  • View blog
  • Posts: 39
  • Joined: 08-November 08

Re: New language features in Java 7

Posted 02 December 2009 - 04:43 AM

This update sounds cool the string switch could come in handy
Was This Post Helpful? 0
  • +
  • -

#9 SwiftStriker00  Icon User is offline

  • No idea why my code works
  • member icon

Reputation: 432
  • View blog
  • Posts: 1,596
  • Joined: 25-December 08

Re: New language features in Java 7

Posted 02 December 2009 - 08:41 AM

I'm just happy to see switch statements will support strings now. The collection support will be nice too, since I do a lot of C# and i have a tendency to to call list[0] instead of list.get(0) a lot.
Was This Post Helpful? 0
  • +
  • -

#10 Raynes  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 611
  • View blog
  • Posts: 2,815
  • Joined: 05-January 09

Re: New language features in Java 7

Posted 03 December 2009 - 08:12 AM

They're actually going to do closures as well. :D
Was This Post Helpful? 0
  • +
  • -

#11 EdwinNameless  Icon User is offline

  • D.I.C Addict
  • member icon

Reputation: 120
  • View blog
  • Posts: 710
  • Joined: 15-October 09

Re: New language features in Java 7

Posted 03 December 2009 - 09:18 AM

View PostRaynes, on 3 Dec, 2009 - 07:12 AM, said:

They're actually going to do closures as well. :D


Yeah, not so sure about that one. Keeps coming back and disappearing again... It was mentioned a few months ago, but haven't heard about it since.

The underscore idea, creative indeed: it's been nicked from Ruby (which certainly took it from somewhere else...)!

Really, for me the great news is that they've finally coped on that a bit of syntactic sugar around collections wouldn't hurt. I mean accessing maps like this:

Map<String, Integer> map = {"key" : 1};
int value = map["key"];



should have been possible *at least* from java 5... :angry:
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1