(Object obj)
| 44 | } |
| 45 | |
| 46 | public boolean equals(Object obj) |
| 47 | { |
| 48 | if (obj == null) |
| 49 | { |
| 50 | return false; |
| 51 | } |
| 52 | else if (obj == this) |
| 53 | { |
| 54 | return true; |
| 55 | } |
| 56 | else if (!(obj instanceof CompoundKey)) |
| 57 | { |
| 58 | return false; |
| 59 | } |
| 60 | else |
| 61 | { |
| 62 | CompoundKey compoundkey = (CompoundKey)obj; |
| 63 | Object[] aobject = compoundkey.getKeys(); |
| 64 | |
| 65 | if (aobject.length != this.keys.length) |
| 66 | { |
| 67 | return false; |
| 68 | } |
| 69 | else |
| 70 | { |
| 71 | for (int i = 0; i < this.keys.length; ++i) |
| 72 | { |
| 73 | if (!compareKeys(this.keys[i], aobject[i])) |
| 74 | { |
| 75 | return false; |
| 76 | } |
| 77 | } |
| 78 | |
| 79 | return true; |
| 80 | } |
| 81 | } |
| 82 | } |
| 83 | |
| 84 | private static boolean compareKeys(Object key1, Object key2) |
| 85 | { |
no test coverage detected