declarative getter/setter via annotation
ryenus
ryenus at gmail.com
Wed Apr 6 15:42:21 UTC 2011
Here is a trivial one, I wonder if it's ok to request for something like
declarative getter/setter to access class fields, namely via annotations
such as:
@accessor(set,is)
private boolean field1;
AND
@accessor(set,get)
private int filed2;
in case there are multiple fields declared together, all fields should have
getter/setter generated, such as:
@accessor(set,get)
private String field3, field4;
This can reduce the noises incurred by plain getter/setter's, especially for
big classes with a lot of fields.
mark.reinhold wrote:
>
> It's time to start thinking about planning JDK 8.
>
> We already know what some of the big-ticket items are likely to be.
> There'll be room for other features too, however, both large and small.
> It's therefore time to define a simple process for collecting, sorting,
> reviewing, and prioritizing proposals and plans for new features, for
> JDK 8 and for later releases.
>
> Some essential requirements (not in priority order):
>
> - As lightweight as possible.
>
> - Simple mechanics.
>
> - Version-controlled, so that changes can be tracked.
>
> - Open to all committers, with transparent decision-making.
>
> - The basic format should not be too different from (a simplified
> form of) the old Sun "one-pager" template [1], with which many
> are already familiar.
>
> - An approved proposal should be able to serve as the authoritative
> source of the summary and reference information needed for related
> documents such as the release feature list [2] and the Platform
> Umbrella JSR specification [3].
>
> One can imagine all sorts of fancy database-backed systems that would
> fulfill these requirements, but we need something sooner rather than
> later. I think a workable solution, at least for now, is to collect
> proposals as structured text files in a Mercurial repository. So that
> people don't have to write raw HTML or XML we could use the "Markdown"
> lightweight markup language [4] together with an existing convention
> for placing common metadata at the top of a file [5]. The Mercurial
> repository would be set up so that a push operation would automatically
> update the appropriate web pages on openjdk.java.net.
>
> I've adapted an existing draft proposal for JDK 8 into Markdown as an
> example [6] (thanks to Maurizio Cimadamore for the draft). The exact
> template format would, of course, be a topic of further discussion.
>
> Comments?
>
> - Mark
>
>
> [1] http://hub.opensolaris.org/bin/view/Community+Group+arc/onepager
> [2] E.g., http://openjdk.java.net/projects/jdk7/features/
> [3] E.g., http://jcp.org/aboutJava/communityprocess/edr/jsr336/index.html
> [4] http://en.wikipedia.org/wiki/Markdown
> [5] http://www.freewisdom.org/projects/python-markdown/Meta-Data
> [6] http://cr.openjdk.java.net/~mr/draft-mcimadamore-inference.md
>
>
--
View this message in context: http://old.nabble.com/Planning-JDK-8%2C-and-beyond-tp31202891p31334547.html
Sent from the OpenJDK General discussion mailing list archive at Nabble.com.
More information about the discuss
mailing list