(Object other)
| 70 | } |
| 71 | |
| 72 | @Override |
| 73 | public boolean equals(Object other) { |
| 74 | boolean result = (other instanceof UniqueId); |
| 75 | if (result) { |
| 76 | UniqueId uid = (UniqueId) other; |
| 77 | if (this.id == null && uid.id == null) { |
| 78 | // Nothing to do |
| 79 | } else if (this.id == null) { |
| 80 | result = false; |
| 81 | } else if (uid.id == null) { |
| 82 | result = false; |
| 83 | } else { |
| 84 | result = Arrays.equals(this.id, uid.id); |
| 85 | } |
| 86 | } |
| 87 | return result; |
| 88 | } |
| 89 | |
| 90 | /** |
| 91 | * Returns the raw bytes of this unique identifier. |