@Test public void testEqualsNull() { final ArchiveIdentifierVersion ai1 = new ArchiveIdentifierVersion(ArchiveType.JAVA, "abc", "1.0"); final ArchiveIdentifierVersion ai2 = null; Assert.assertFalse("equals()", ai1.equals(ai2)); }
@Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof ArchiveIdentifierVersion)) { return false; } if (!super.equals(o)) { return false; } ArchiveIdentifierVersion that = (ArchiveIdentifierVersion) o; return Objects.equals(getVersion(), that.getVersion()); }
ArchiveIdentifierVersion extends ArchiveIdentifier { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof ArchiveIdentifierVersion)) { return false; } if (!super.equals(o)) { return false; } ArchiveIdentifierVersion that = (ArchiveIdentifierVersion) o; return Objects.equals(getVersion(), that.getVersion()); } }
ArchiveIdentifierVersion extends ArchiveIdentifier { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof ArchiveIdentifierVersion)) { return false; } if (!super.equals(o)) { return false; } ArchiveIdentifierVersion that = (ArchiveIdentifierVersion) o; return Objects.equals(getVersion(), that.getVersion()); } ArchiveIdentifierVersion(final ArchiveType archiveType, final String name, final String version); }
ArchiveIdentifierVersion extends ArchiveIdentifier { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof ArchiveIdentifierVersion)) { return false; } if (!super.equals(o)) { return false; } ArchiveIdentifierVersion that = (ArchiveIdentifierVersion) o; return Objects.equals(getVersion(), that.getVersion()); } ArchiveIdentifierVersion(final ArchiveType archiveType, final String name, final String version); final String getVersion(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); }
ArchiveIdentifierVersion extends ArchiveIdentifier { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof ArchiveIdentifierVersion)) { return false; } if (!super.equals(o)) { return false; } ArchiveIdentifierVersion that = (ArchiveIdentifierVersion) o; return Objects.equals(getVersion(), that.getVersion()); } ArchiveIdentifierVersion(final ArchiveType archiveType, final String name, final String version); final String getVersion(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString();  }