JcrNs implements JsonObjectConvertible, Comparable<JcrNs> { @Override public boolean equals(final Object o) { if (this == o) return true; if (!(o instanceof JcrNs)) return false; JcrNs jcrNs = (JcrNs) o; return Objects.equals(getPrefix(), jcrNs.getPrefix()) && Objects.equals(getUri(), jcrNs.getUri()); }  @NotNull static JcrNs.JsonKeys keys(); String getPrefix(); void setPrefix(String prefix); String getUri(); void setUri(String uri); static @Nullable JcrNs fromJson(final @NotNull JsonObject json); static @NotNull JcrNs create(final @NotNull String prefix, final @NotNull String uri); @Override boolean equals(final Object o); @Override int hashCode(); @Override JsonObject toJson(); @Override String toString(); @Override int compareTo(final @NotNull JcrNs o);  }
@Test public void testEquals() { final JcrNs base = JcrNs.create(prefix, uri); assertEquals("should be the same for same", base, base); final JcrNs same = JcrNs.create(prefix, uri); assertEquals("should be the same for same params", base, same); final JcrNs diffUri = JcrNs.create(prefix, "http: assertNotEquals("should be diff for diff uri", base, diffUri); final JcrNs diffPrefix = JcrNs.create("foo1", uri); assertNotEquals("should be diff for diff prefix", base, diffPrefix); final JcrNs diffBoth = JcrNs.create("foo1", "http: assertNotEquals("should be diff for diff both", base, diffBoth); }