Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Is there a mechanism in Java similar to Properties in C#?

807589Nov 6 2008 — edited Nov 6 2008
A friend of mine is working on a project in C#, and periodically I've been examining his source code, and commenting on how similar the syntax and programming style seems to be to Java. Recently my friend asked me a question about 'Properties', which I wasn't familiar with. So I found a few websites that describe how Properties work in C#, and now I'm wondering if there is anything similar to Properties in Java?

In case any of you are curious, this particular website has a pretty straight forward explanation

http://www.c-sharpcorner.com/UploadFile/rajeshvs/PropertiesInCS11122005001040AM/PropertiesInCS.aspx

I'm not advocating C# or trying to start an argument about the pros and cons of Java vs. C#, I'm just wondering if there is an analog to properties in Java, or if there's been mention of doing so in future releases.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 4 2008
Added on Nov 6 2008
6 comments
268 views