public class SemanticVersion extends Object
Constructor and Description |
---|
SemanticVersion() |
Modifier and Type | Method and Description |
---|---|
static int |
compose(int major,
int minor,
int patch)
Compose a 4-byte integer with major, minor, and patch version stored in the least significant 3 bytes.
|
static int |
major(int version)
Get the major version from a composite value.
|
static int |
minor(int version)
Get the minor version from a composite value.
|
static int |
patch(int version)
Get the patch version from a composite value.
|
static String |
toString(int version)
Generate a
String representation of the semantic version in the format major.minor.patch . |
public static int compose(int major, int minor, int patch)
major
- version in the range 0-255.minor
- version in the range 0-255patch
- version in the range 0-255.IllegalArgumentException
- if the values are outside acceptable range.public static int major(int version)
version
- as a composite from which to extract the major version.public static int minor(int version)
version
- as a composite from which to extract the minor version.public static int patch(int version)
version
- as a composite from which to extract the patch version.Copyright © 2014-2019 Real Logic Ltd. All Rights Reserved.