Version comparison class based on Semantic Versioning 2.0.0 http://semver.org/ Compares versions and converts versions from string. More...
#include <SemanticVersion.hh>
Public Member Functions | |
SemanticVersion () | |
Default constructor. | |
SemanticVersion (const SemanticVersion &_copy) | |
Copy constructor. | |
SemanticVersion (const std::string &_v) | |
Constructor. | |
SemanticVersion (const unsigned int _major, const unsigned int _minor=0, const unsigned int _patch=0, const std::string &_prerelease="", const std::string &_build="") | |
Constructor. | |
~SemanticVersion () | |
Destructor. | |
std::string | Build () const |
Get the build metadata string. | |
unsigned int | Major () const |
Get the major number. | |
unsigned int | Minor () const |
Get the minor number. | |
bool | operator!= (const SemanticVersion &_other) const |
Inequality comparison operator. | |
bool | operator< (const SemanticVersion &_other) const |
Less than comparison operator. | |
bool | operator<= (const SemanticVersion &_other) const |
Less than or equal comparison operator. | |
SemanticVersion & | operator= (const SemanticVersion &_other) |
Assignment operator. | |
bool | operator== (const SemanticVersion &_other) const |
Equality comparison operator. | |
bool | operator> (const SemanticVersion &_other) const |
Greater than comparison operator. | |
bool | operator>= (const SemanticVersion &_other) const |
Greater than or equal comparison operator. | |
bool | Parse (const std::string &_versionStr) |
Parse a version string and set the major, minor, patch numbers, and prerelease and build strings. | |
unsigned int | Patch () const |
Get the patch number. | |
std::string | Prerelease () const |
Get the prerelease string. | |
std::string | Version () const |
Returns the version as a string. | |
Version comparison class based on Semantic Versioning 2.0.0 http://semver.org/ Compares versions and converts versions from string.