|
libnick 2025.10.0
A cross-platform base for native Nickvision applications.
|
A model for a version number. More...
#include <version.h>
Public Member Functions | |
| Version () noexcept | |
| Constructs a Version. | |
| Version (int major, int minor, int build) noexcept | |
| Constructs a Version. | |
| Version (int major, int minor, int build, const std::string &dev) | |
| Constructs a Version. | |
| Version (const std::string &version) | |
| Constructs a Version. | |
| int | getMajor () const noexcept |
| Gets the major number of the version. | |
| int | getMinor () const noexcept |
| Gets the minor number of the version. | |
| int | getBuild () const noexcept |
| Gets the build number of the version. | |
| const std::string & | getDev () const noexcept |
| Gets the dev string of the version. | |
| VersionType | getVersionType () const noexcept |
| Gets the type of the version. | |
| const std::string & | str () const noexcept |
| Gets a string representation of the Version. | |
| bool | empty () const noexcept |
| Gets whether or not the Version object is empty. | |
| bool | operator< (const Version &compare) const noexcept |
| Compares Version objects via < operator. | |
| bool | operator<= (const Version &compare) const noexcept |
| Compares Version objects via <= operator. | |
| bool | operator> (const Version &compare) const noexcept |
| Compares Version objects via > operator. | |
| bool | operator>= (const Version &compare) const noexcept |
| Compares Version objects via >= operator. | |
| bool | operator== (const Version &compare) const noexcept |
| Compares Version objects via == operator. | |
| bool | operator!= (const Version &compare) const noexcept |
| Compares Version objects via != operator. | |
A model for a version number.
Formatted in "major.minor.build-dev".
|
noexcept |
Constructs a Version.
|
noexcept |
Constructs a Version.
| major | The major number |
| minor | The minor number |
| build | The build number |
| Nickvision::Update::Version::Version | ( | int | major, |
| int | minor, | ||
| int | build, | ||
| const std::string & | dev ) |
Constructs a Version.
| major | The major number |
| minor | The minor number |
| build | The build number |
| dev | The dev string |
| std::invalid_argument | Thrown when the dev version does not contain a "-" or a "." as the first character |
| Nickvision::Update::Version::Version | ( | const std::string & | version | ) |
Constructs a Version.
| version | A version string to parse |
| std::invalid_argument | Thrown when the version string is not formatted correctly |
|
noexcept |
Gets whether or not the Version object is empty.
|
noexcept |
Gets the build number of the version.
|
noexcept |
Gets the dev string of the version.
|
noexcept |
Gets the major number of the version.
|
noexcept |
Gets the minor number of the version.
|
noexcept |
Gets the type of the version.
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |
|
noexcept |