AddressableNamedEntity implements AddressableEntity { @Override public int hashCode() { return Objects.hashCode(self, name); } AddressableNamedEntity(URI self, String name); @Override URI getSelf(); String getName(); @Override String toString(); @Override boolean equals(Object obj); @Override int hashCode();  }
@Test public void testHashCode() throws Exception { assertEquals(P1.hashCode(), P2.hashCode()); }