| CODENOTIFIER | HelpYou are not signed inSign in |
Project: ProActive
Revision: 10044
Author: cdalmass
Date: 03 Sep 2008 03:08:29
Changes:add hashCode method in addition to equals
PROACTIVE-371
| ... | ...@@ -131,6 +131,7 @@ | |
| 131 | 131 | */ |
| 132 | 132 | public abstract void setFcItfImpl(final Object impl); |
| 133 | 133 | |
| 134 | @Override | |
| 134 | 135 | public boolean equals(Object anObject) { |
| 135 | 136 | if (anObject instanceof ProActiveComponentRepresentativeImpl) { |
| 136 | 137 | return super.equals(anObject); |
| ... | ...@@ -145,6 +146,11 @@ | |
| 145 | 146 | } |
| 146 | 147 | |
| 147 | 148 | @Override |
| 149 | public int hashCode() { | |
| 150 | return name.hashCode() + owner.hashCode(); | |
| 151 | } | |
| 152 | ||
| 153 | @Override | |
| 148 | 154 | public String toString() { |
| 149 | 155 | String string = "name : " + getFcItfName() + "\n" + // "componentIdentity : " + getFcItfOwner() + "\n" + "type : " + |
| 150 | 156 | getFcItfType() + "\n" + "isInternal : " + isFcInternalItf() + "\n"; |