TUM CCSM Commons

edu.tum.cs.commons.version
Class VersionUtils

java.lang.Object
  extended by edu.tum.cs.commons.version.VersionUtils

public class VersionUtils
extends java.lang.Object

Utility code for dealing with versions.

Version:
$Rev: 26283 $
Author:
hummelb, $Author: juergens $
Rating:
GREEN Hash: 38C0D10E9CCCD8B82949F4612A48AB1B

Constructor Summary
VersionUtils()
           
 
Method Summary
static void checkForNewVersion(java.lang.String appName, java.lang.String versionFileUrl, Version runningVersion)
          Checks whether a new version of an application is available.
static Version getMostRecentVersion(java.lang.String versionFileUrl)
          Get the most recent version from a file available via an URL.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VersionUtils

public VersionUtils()
Method Detail

checkForNewVersion

public static void checkForNewVersion(java.lang.String appName,
                                      java.lang.String versionFileUrl,
                                      Version runningVersion)
Checks whether a new version of an application is available. This retrieves the most recent version from an URL using getMostRecentVersion(String). If the version could be retrieved and is more recent than the running version, an informative message box appears (Swing).


getMostRecentVersion

public static Version getMostRecentVersion(java.lang.String versionFileUrl)
                                    throws java.io.IOException,
                                           FormatException
Get the most recent version from a file available via an URL.

Throws:
java.io.IOException
FormatException

TUM CCSM Commons

TUM CCSM Commons - 2.7