/** * Retrieves the version string. * * The {@link #parse(String)} method can create an instance * of {@link Version} with the returned version value string. * * @return the version value string */ @Override public String toString() { return Integer.toString(getMajor()) + "." + Integer.toString(getMinor()) + "." + Integer.toString(getRevision()) + (isSnapshot() ? SNAPSHOT_MARKER : ""); }
@Override public int hashCode() { return Objects.hash(getMajor(), getMinor(), getRevision(), isSnapshot()); }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (obj instanceof Version) { Version version = (Version) obj; return getMajor() == version.getMajor() && getMinor() == version.getMinor() && getRevision() == version.getRevision() && isSnapshot() == version.isSnapshot(); } return false; }
/** * Retrieves the version string. * * The {@link #parse(String)} method can create an instance * of {@link Version} with the returned version value string. * * @return the version value string */ @Override public String toString() { return Integer.toString(getMajor()) + "." + Integer.toString(getMinor()) + "." + Integer.toString(getRevision()) + (isSnapshot() ? SNAPSHOT_MARKER : ""); }
/** * Retrieves the version string. * * The {@link #parse(String)} method can create an instance * of {@link Version} with the returned version value string. * * @return the version value string */ @Override public String toString() { return Integer.toString(getMajor()) + "." + Integer.toString(getMinor()) + "." + Integer.toString(getRevision()) + (isSnapshot() ? SNAPSHOT_MARKER : ""); }
@Override public int hashCode() { return Objects.hash(getMajor(), getMinor(), getRevision(), isSnapshot()); }
@Override public int hashCode() { return Objects.hash(getMajor(), getMinor(), getRevision(), isSnapshot()); }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (obj instanceof Version) { Version version = (Version) obj; return getMajor() == version.getMajor() && getMinor() == version.getMinor() && getRevision() == version.getRevision() && isSnapshot() == version.isSnapshot(); } return false; }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (obj instanceof Version) { Version version = (Version) obj; return getMajor() == version.getMajor() && getMinor() == version.getMinor() && getRevision() == version.getRevision() && isSnapshot() == version.isSnapshot(); } return false; }