Represents the version number
Version(major: number = 0, minor: number = 0, build: number = 0, revision: number = 0)
Construct a Version object from major, minor, build, revision number
Parameters | |
major | Value of the major component. Default: 0 |
minor | Value of the minor component. Default: 0 |
build | Value of the build component. Default: 0 |
revision | Value of the revision component. Default: 0 |
Version(versionString: string)
Construct a Version object from version string
Parameters | |
versionString | Version string. Ex: "1.2.3.4" |
number major()
Get the value of the major component
number minor()
Get the value of the minor component
number build()
Get the value of the build component
number revision()
Get the value of the revision component
number compare(version: Version | string)
Compare with another Version. < 0 is lower, 0 is equal, > 0 is higher
Parameters | |
version | The Version object or version string |
Return | |
number | < 0 is lower, 0 is equal, > 0 is higher |
© 2024 - Macrorify by KoK-CODE