@Override
  public boolean equals(final Object o) {
    if (o instanceof Node) {
      Node that = (Node) o;
      if (this == that) {
        return true;
      }
      if (that == null) {
        return false;
      }
      if (index == that.index) {
        return true;
      }
    }
    return false;
  }