From: Walden H. Leverich

There's _always_ a getter and/or setter if you're accessing a property.
But I'll grant, you can't tell if you're going after a property or a
member variable. Of course, in good OO design, why would you go after a
member variable?

Ah yes, opinion. <grin> Try telling the folks in the SWT development team
about accessing member variables.

I think it's a style thing so. I can't stand the explicit get/set calls
in Java. :)

I agree it really is a style issue. And because of that, it's one of those
things that the Brand New 2008 Joe Pluta (limited edition, forward looking
statement, your mileage may vary, some restrictions apply) will avoid
debating one way or the other.

I'll tell you why I like Java's technique - because I like to be as close to
the bits and bytes as possible, and regardless of whether you should or
shouldn't be accessing member variables, I can tell just by looking whether
I'm getting the variable or calling a method that gets the variable.

Whereas I LIKE my 4GL to do everything (Ruby on Rails-ish), when I'm coding
a 3GL I prefer as little magic as possible.

But this is not a challenge, a slam, or a slight - it's just my opinion
<grin>.

Joe


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.