A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
this week in the
Features new in Java 7
Does Java 7 introduces a better way to do 'getter/setter'
Joined: Apr 09, 2012
Jul 31, 2012 12:03:49
I feel the 'getter and setter' in current
is cumbersome, and other language already has better way to handle that, Does Java 7 has new feature for that? Thanks
Joined: Jun 24, 2003
Jul 31, 2012 12:39:07
In short no, the properties style syntax that you'll find in Groovy or C# was not accepted for Java 7 (or 8 for that matter). Not necessarily a bad thing mind you (think about how it changes default access behaviour / programming idioms) :-)
Cheers, Martijn -
The Well-Grounded Java Developer book!
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: Does Java 7 introduces a better way to do 'getter/setter'
HashMap bean with generic type parameters
Doubt in Java Beans
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015