Commit aafeed21 authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Added #equals and #hashCode.

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/trunk@3459 b35dd754-fafc-0310-a699-88a17e54d16e
parent 01c05284
...@@ -219,6 +219,21 @@ public class Group implements Cacheable { ...@@ -219,6 +219,21 @@ public class Group implements Cacheable {
return size; return size;
} }
public int hashCode() {
return name.hashCode();
}
public boolean equals(Object object) {
if (this == object) {
return true;
}
if (object != null && object instanceof Group) {
return name.equals(((Group)object).getName());
}
else {
return false;
}
}
/** /**
* Collection implementation that notifies the GroupProvider of any * Collection implementation that notifies the GroupProvider of any
* changes to the collection. * changes to the collection.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment