classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: rmi vs cajo


From: Stuart Ballard
Subject: Re: rmi vs cajo
Date: Wed, 14 Sep 2005 11:27:22 -0400

I've seen various blog posts and things that give the general advice
that calling a virtual method from a constructor is pretty much always
a bad idea. "Considered harmful", that kind of thing.

That's difficult advice to follow in Java since almost everything's
virtual and there's no definite cue as to whether it's *intended* to
be overridden or not, but at the very least it's safe to say that
hashCode is intended to be overridden, since that's the whole point of
its existence.

Even ignoring the fact that this seems to be required for Sun
compatibility (which is sufficient by itself to make the decision), I
think we ought to change this code.

Stuart.
-- 
http://sab39.dev.netreach.com/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]