IG: equals, hasCode, compareTo inspectios enhancement

It would be great to make these inspection a little bit smarter - by not
requiring fields used in hashCode, equals and compareTo to be final but
rather immutable by checking for
absense of mutators for the fields in question.



1 comment
Comment actions Permalink

Yup, agreed. The real issue is that fields can't be reasonably made "final" in Serializable objects, but you might reasonably want to override equals/hashCode/compareTo on them.

I'll put it on the list.

--Dave Griffith

0

Please sign in to leave a comment.