harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Denis Kishenko" <dkishe...@gmail.com>
Subject Re: [optimization] hashCode() evolution
Date Fri, 28 Jul 2006 10:16:00 GMT
2006/7/28, Alexey Petrenko <alexey.a.petrenko@gmail.com>:
> 2006/7/27, Denis Kishenko <dkishenko@gmail.com>:
> > Unfortunately
> > 1. class can has temporary private fields (see BasicStroke.java)
> We can mark such fields as transient. As for serialization.
> > 2. class can has final fields which take part in hash code calculation
> > (see EllipticCurve.java)
> It's probably the reason to add final fields to hash code calculation.

Yep, we can do this, but as you remember Alex suggested use Eclipse
tool to make hashCode automatically - it would be easier. But before
run this tool we have to made a lot of routine work =)

Alex's suggestion
"Lastly, an easier approach is to use a tool (such as Eclipse) to
generate the implementation of hashCode() automatically based on the
non-static, non-final variables of a class. This one sounds like (a)
the easiest, and (b) all-round better performant than any of the

Terms of use : http://incubator.apache.org/harmony/mailing.html
To unsubscribe, e-mail: harmony-dev-unsubscribe@incubator.apache.org
For additional commands, e-mail: harmony-dev-help@incubator.apache.org

View raw message