From: "James Britt (rubydev)" Date: 2002-01-25T10:30:43+09:00 Subject: RE: OOP UI Design > > On Thu, Jan 24, 2002 at 10:44:45AM +0900, James Britt (rubydev) wrote: > > I think the issue (possbly raised by Holub) is that, regardless of how > > the getter derives the return value, the client becomes dependant on > > that value type. So, if num_monkeys really should return a complex number > > rather than an integer, client code breaks when that's changed. > > *Very* interesting. Any pointer to more information on the subject? This link (http://javaworld.org/javaworld/jw-06-2001/jw-0622-letters.html) has some discussion in the topic, based on Holub's comments. Search the page for "holub" and "evil" :) Actually, there is this statement by Mr. Holub: "On the other hand, I think that Wm. Paul's article is quite sound, though as you point out, I'd take it a step further and eliminate the get/set methods -- you don't actually need them." He is refering to the article found here: http://javaworld.org/javaworld/jw-05-2001/jw-0518-encapsulation.html And *that* article is subtitled: "The principles of information hiding go beyond the Java language facility for encapsulation " So, to try to keep this about Ruby: What are the risks in using Java applications as a design base when attempting to build something in Ruby? There have been a few discussions here where someone advocates building the Ruby version of [SomeJavaApp]. Given that a language guides you into certain design decisions that you might not have made in another language, at what point does copying a Java application become counter-productive when using Ruby? Put another way, what (if anything) do Java developers do that a Ruby developer wouldn't, because Java prevents or hinders a design path that is available in Ruby? James > > Massimiliano > >