diff --git a/coreAPI/src/main/java/net/java/games/input/Version.java b/coreAPI/src/main/java/net/java/games/input/Version.java index 1aac468..76f539c 100644 --- a/coreAPI/src/main/java/net/java/games/input/Version.java +++ b/coreAPI/src/main/java/net/java/games/input/Version.java @@ -35,7 +35,7 @@ package net.java.games.input; /** * The version and build number of this implementation. - * Version numbers for a release are of the form: w.x.y[-a]-z, where: + * Version numbers for a release are of the form: w.x.y, where: * * * For example, the following are all valid version strings: * * */ @@ -86,18 +72,6 @@ public final class Version { private Version() { } - /** - * Version string of this build. - */ - private static final String apiVersion = "@API_VERSION@"; - private static final String buildNumber = "@BUILD_NUMBER@"; - - /* - * Split so that ant does not replace the token; - */ - private static final String antBuildNumberToken = "@BUILD_" + "NUMBER@"; - private static final String antAPIVersionToken = "@API_" + "VERSION@"; - /** * Returns the verison string and build number of * this implementation. See the class descritpion @@ -106,13 +80,7 @@ public final class Version { * @return The version string of this implementation. */ public static String getVersion() { - String version = "Unversioned"; - if(!antAPIVersionToken.equals(apiVersion)) { - version = apiVersion; - } - if(!antBuildNumberToken.equals(buildNumber)) { - version += "-b" + buildNumber; - } - return version; + + return getClass().getPackage().getImplementationVersion(); } } diff --git a/tests/src/main/java/net/java/games/input/ControllerReadTest.java b/tests/src/main/java/net/java/games/input/ControllerReadTest.java index a9749de..ee3b85d 100644 --- a/tests/src/main/java/net/java/games/input/ControllerReadTest.java +++ b/tests/src/main/java/net/java/games/input/ControllerReadTest.java @@ -53,7 +53,6 @@ import javax.swing.JScrollPane; import net.java.games.input.Component; import net.java.games.input.Controller; import net.java.games.input.ControllerEnvironment; -import net.java.games.input.Version; public class ControllerReadTest extends JFrame{ private abstract static class AxisPanel extends JPanel{