in src/main/java/org/apache/sling/discovery/commons/providers/DefaultClusterView.java [52:74]
public boolean equals(final Object obj) {
if (obj == null || !(obj instanceof DefaultClusterView)) {
return false;
}
final DefaultClusterView other = (DefaultClusterView) obj;
if (!this.id.equals(other.id)) {
return false;
}
if (!this.getLeader().equals(other.getLeader())) {
return false;
}
if (this.instances.size() != other.instances.size()) {
return false;
}
for (Iterator<InstanceDescription> it = instances.iterator(); it
.hasNext();) {
InstanceDescription instance = it.next();
if (!other.instances.contains(instance)) {
return false;
}
}
return true;
}