public class NodeVersion extends Object implements Comparable<NodeVersion>
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(@NotNull NodeVersion nodeVersion) |
boolean |
equals(Object o) |
int |
getMajorVersion()
Returns major version number.
|
int |
getMinorVersion()
Returns minor version number.
|
int |
getRevisionVersion()
Returns revision version number.
|
int |
hashCode() |
static NodeVersion |
of(int major,
int minor,
int revision)
Creates
NodeVersion from the given versions. |
static Optional<NodeVersion> |
parse(String version)
Returns an
Optional with a NodeVersion representing the version of Node.js parsed from the given
value or an empty Optional in case the given value cannot be parsed. |
String |
toString() |
public int getMajorVersion()
public int getMinorVersion()
public int getRevisionVersion()
public static Optional<NodeVersion> parse(String version)
Optional with a NodeVersion representing the version of Node.js parsed from the given
value or an empty Optional in case the given value cannot be parsed.public static NodeVersion of(int major, int minor, int revision)
NodeVersion from the given versions.public int compareTo(@NotNull
@NotNull NodeVersion nodeVersion)
compareTo in interface Comparable<NodeVersion>Copyright © 2022. All rights reserved.