import freenet.keys.FreenetURI;
+import com.google.common.base.Objects;
+
/**
* {@link Sone} implementation that only stores the ID of a Sone and returns
* {@code null}, {@code 0}, or empty collections where appropriate.
return id;
}
+ @Override
+ public int hashCode() {
+ return id.hashCode();
+ }
+
+ @Override
+ public boolean equals(Object object) {
+ return (object != null) && (object.getClass() == getClass()) && Objects.equal(id, ((IdOnlySone) object).id);
+ }
+
}