@Test void testHashCode() { assertEquals(new DefaultVersion("1.1").hashCode(), new DefaultVersion("1.1").hashCode()); assertEquals(new DefaultVersion("1.1").hashCode(), new DefaultVersion("1.1.0").hashCode()); assertNotEquals(new DefaultVersion("1.1").hashCode(), new DefaultVersion("2.0").hashCode()); }
@Override public int hashCode() { if (this.hashCode == 0) { initElements(); this.hashCode = this.elements.hashCode(); } return this.hashCode; }
DefaultVersion implements Version { @Override public int hashCode() { if (this.hashCode == 0) { initElements(); this.hashCode = this.elements.hashCode(); } return this.hashCode; } }
DefaultVersion implements Version { @Override public int hashCode() { if (this.hashCode == 0) { initElements(); this.hashCode = this.elements.hashCode(); } return this.hashCode; } DefaultVersion(String rawVersion);  DefaultVersion(Version version); }
DefaultVersion implements Version { @Override public int hashCode() { if (this.hashCode == 0) { initElements(); this.hashCode = this.elements.hashCode(); } return this.hashCode; } DefaultVersion(String rawVersion);  DefaultVersion(Version version); @Override Type getType(); @Override String getValue(); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); boolean equals(DefaultVersion version); @Override int compareTo(Version version); int compareTo(String version); int compareTo(DefaultVersion version); }
DefaultVersion implements Version { @Override public int hashCode() { if (this.hashCode == 0) { initElements(); this.hashCode = this.elements.hashCode(); } return this.hashCode; } DefaultVersion(String rawVersion);  DefaultVersion(Version version); @Override Type getType(); @Override String getValue(); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); boolean equals(DefaultVersion version); @Override int compareTo(Version version); int compareTo(String version); int compareTo(DefaultVersion version);  }