org.codehaus.jackson.util
Class VersionUtil

java.lang.Object
  extended by org.codehaus.jackson.util.VersionUtil

public class VersionUtil
extends Object

Functionality for supporting exposing of component Versions.

Since:
1.6

Field Summary
static String VERSION_FILE
           
 
Constructor Summary
VersionUtil()
           
 
Method Summary
static Version parseVersion(String versionStr)
           
protected static int parseVersionPart(String partStr)
           
static Version versionFor(Class<?> cls)
          Helper method that will try to load version information for specified class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

VERSION_FILE

public static final String VERSION_FILE
See Also:
Constant Field Values
Constructor Detail

VersionUtil

public VersionUtil()
Method Detail

versionFor

public static Version versionFor(Class<?> cls)
Helper method that will try to load version information for specified class. Implementation is simple: class loader that loaded specified class is asked to load resource with name "VERSION" from same location (package) as class itself had. If no version information is found, Version.unknownVersion() is returned.


parseVersion

public static Version parseVersion(String versionStr)

parseVersionPart

protected static int parseVersionPart(String partStr)