org.apache.camel.util
Class PackageHelper
java.lang.Object
org.apache.camel.util.PackageHelper
public final class PackageHelper
- extends Object
Some helper methods for working with Java packages and versioning.
- Version:
- $Revision: 767829 $
Method Summary |
static boolean |
isValidVersion(String packageName,
double minimumVersion)
Returns true if the version number of the given package name can be found and is greater than or equal to the minimum version. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
isValidVersion
public static boolean isValidVersion(String packageName,
double minimumVersion)
- Returns true if the version number of the given package name can be found and is greater than or equal to the minimum version.
For package names which include multiple dots, the dots are removed. So for example a spring version of 2.5.1 is converted to
2.51 so you can assert that its >= 2.51 (so above 2.50 and less than 2.52 etc).
- Parameters:
packageName
- the Java package name to compareminimumVersion
- the minimum version number
- Returns:
- true if the package name can be determined and if its greater than or equal to the minimum value
Apache CAMEL