public class GrouperVersion extends Object
Constructor and Description |
---|
GrouperVersion(String versionString)
private constructor
|
Modifier and Type | Method and Description |
---|---|
static boolean |
_grouperVersionGreaterOrEqualHelper(String grouperVersion,
String anotherVersion)
helper method for unit testing
|
static GrouperVersion |
currentVersion()
current grouper version
|
boolean |
equals(Object obj) |
boolean |
greaterOrEqualToArg(GrouperVersion version)
see if the grouper version is greater than or equal to a certain version
|
boolean |
greaterOrEqualToArg(String version)
see if the grouper version is greater than or equal to a certain version
|
static String |
grouperVersion()
get the version from jar e.g.
|
static boolean |
grouperVersionGreaterOrEqual(String version)
see if the grouper version is greater than or equal to a certain version
|
int |
hashCode() |
boolean |
lessThanArg(GrouperVersion other)
see if this version is less than the argument one
|
boolean |
lessThanArg(GrouperVersion other,
boolean orEqual)
see if this version is less than the argument one
|
boolean |
lessThanMajorMinorArg(GrouperVersion other,
boolean orEqual)
see if this version is less than the argument one, only considering major and minor version
|
boolean |
sameMajorMinorArg(GrouperVersion other)
see if this version is same argument one, only considering major and minor version
|
static String |
stringValueOrNull(String versionString)
return the parsed and tostring version of this version string (consistent),
or null if nothing passed in
|
String |
toString() |
static GrouperVersion |
valueOfIgnoreCase(String string)
convert string to version like an enum would
|
static GrouperVersion |
valueOfIgnoreCase(String string,
boolean exceptionOnNull)
convert string to version like an enum would
|
public GrouperVersion(String versionString)
versionString
- public static String stringValueOrNull(String versionString)
versionString
- public boolean equals(Object obj)
equals
in class Object
Object.equals(Object)
public int hashCode()
hashCode
in class Object
Object.hashCode()
public String toString()
toString
in class Object
Object.toString()
public static String grouperVersion()
public static GrouperVersion currentVersion()
public static GrouperVersion valueOfIgnoreCase(String string)
string
- cannot be blankpublic static GrouperVersion valueOfIgnoreCase(String string, boolean exceptionOnNull)
string
- exceptionOnNull
- will not allow null or blank entriespublic static boolean grouperVersionGreaterOrEqual(String version)
version
- public boolean greaterOrEqualToArg(String version)
version
- public boolean lessThanArg(GrouperVersion other, boolean orEqual)
other
- orEqual
- public boolean lessThanMajorMinorArg(GrouperVersion other, boolean orEqual)
other
- orEqual
- public boolean sameMajorMinorArg(GrouperVersion other)
other
- orEqual
- public boolean lessThanArg(GrouperVersion other)
other
- public boolean greaterOrEqualToArg(GrouperVersion version)
version
- Copyright © 2016 Internet2. All rights reserved.