This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Let me choose to use apache.commons HashcodeBuiler/EqualsBuilder/ToStringBuilder Which in our project we should only use these ways to implement hashCode.... Product Version = NetBeans IDE 7.3 (Build 201302132200) Operating System = Linux version 3.8.0-26-generic running on amd64 Java; VM; Vendor = 1.7.0_25 Runtime = Java HotSpot(TM) 64-Bit Server VM 23.25-b01
I think that wouldn't be 'too' complecated to do and it would improve code readability and shortness code, to have @Override public boolean equals(Object obj) { if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } final MobileProductDetails other = (MobileProductDetails) obj; return new EqualsBuilder(). append(this.getMsisdn(), other.getMsisdn()). append(this.getImsi(), other.getImsi()).isEquals(); } instead of @Override public boolean equals(Object obj) { if (obj == null) { return false; } if (getClass() != obj.getClass()) { return false; } final MobileProductDetails other = (MobileProductDetails) obj; if (!Objects.equals(this.msisdn, other.msisdn)) { return false; } if (!Objects.equals(this.imsi, other.imsi)) { return false; } return true; } Especially if the rest of the code in the modules only uses EqualsBuilder... which NB does not suppert yet :)