Beispiel #1
0
  public boolean equals(Object o) {
    if (o == this) return true;
    if (o == null) return false;

    if (o.getClass() == getClass()) {
      Set otherSet = (Set) o;

      if (getType() != otherSet.getType()) {
        return false;
      }
      return data.equals(otherSet.data);
    }

    return false;
  }