com.h3xstream.retirejs.util
Class CompareVersionUtil
java.lang.Object
com.h3xstream.retirejs.util.CompareVersionUtil
public class CompareVersionUtil
- extends Object
Utility to compare
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CompareVersionUtil
public CompareVersionUtil()
isUnder
public static boolean isUnder(String version,
String under)
- Method that calculate if [Version 1] is under [Version 2]
1.0.1 - 1.0.2 : YES
1.0.1 - 2.0.1 : YES
1.3.2 - 1.2.5 : NO
1.2.3 - 1.2.3 : NO
===
Reimplementation of isAtOrAbove (but reverse)
https://github.com/bekk/retire.js/blob/master/node/lib/retire.js#L85
- Parameters:
version - Version to compareunder - Version serving as reference
- Returns:
- True if [version] < [under]
atOrAbove
public static boolean atOrAbove(String version,
String atOrAbove)
Copyright © 2015. All rights reserved.