libqi-api  2.0.6.8
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Classes | Functions
qi::version Namespace Reference

Version numbering API. More...

Classes

struct  Version
 Struct representing a version number. More...

Functions

std::vector< std::string > explode (const std::string &version)
 Explode a version string to an array of strings.
int compare (const std::string &versionA, const std::string &versionB)
 Compare version numbers.
std::string extract (const std::string &version)
 Extract version number from string.

Detailed Description

Version numbering API.


Function Documentation

qi::version::compare ( const std::string &  versionA,
const std::string &  versionB 
)

Compare version numbers.

Parameters:
versionAVersion number.
versionBVersion number.
Returns:
1 if versionA is more recent than versionB, 0 otherwise, and -1 if error.
qi::version::explode ( const std::string &  version)

Explode a version string to an array of strings.

Parameters:
versionThe string to explode.
Returns:
An array of strings (including ".").
qi::version::extract ( const std::string &  version)

Extract version number from string.

Parameters:
versionThe string containing the version number.
Returns:
The version number, if any.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines