rogue::Version

For version-checking workflows and deployment guidance, see Rogue Version Helper.

Migration notes for version-to-version behavior changes are collected in Migration Notes.

class Version
[header]

Rogue version query and comparison helpers.

Provides access to the runtime Rogue version string/components and utilities to compare against a requested version expression. Comparison helpers parse the passed version string into major/minor/maintenance components.

Public Functions

inline Version()
[header]

Default constructor.

Public Static Functions

static std::string current()
[header] [impl]

Returns current Rogue version string.

Returns:

Version string.

static bool greaterThanEqual(const std::string &compare)
[header] [impl]

Returns whether current version is greater than or equal to compare.

Parameters:

compareVersion string to compare against.

Returns:

true when current version is >= compare.

static bool greaterThan(const std::string &compare)
[header] [impl]

Returns whether current version is greater than compare.

Parameters:

compareVersion string to compare against.

Returns:

true when current version is > compare.

static bool lessThanEqual(const std::string &compare)
[header] [impl]

Returns whether current version is less than or equal to compare.

Parameters:

compareVersion string to compare against.

Returns:

true when current version is <= compare.

static bool lessThan(const std::string &compare)
[header] [impl]

Returns whether current version is less than compare.

Parameters:

compareVersion string to compare against.

Returns:

true when current version is < compare.

static void minVersion(const std::string &compare)
[header] [impl]

Throws if current version is below required minimum.

Parameters:

compare – Minimum required version string.

static void maxVersion(const std::string &compare)
[header] [impl]

Throws if current version is above allowed maximum.

Parameters:

compare – Maximum allowed version string.

static void exactVersion(const std::string &compare)
[header] [impl]

Throws unless current version exactly matches compare.

Parameters:

compare – Required exact version string.

static void setup_python()
[header] [impl]

Registers Python bindings for version helpers.

static uint32_t getMajor()
[header] [impl]

Returns major version component.

static uint32_t getMinor()
[header] [impl]

Returns minor version component.

static uint32_t getMaint()
[header] [impl]

Returns maintenance/patch version component.

static uint32_t getDevel()
[header] [impl]

Returns development/build component.

static void sleep(uint32_t seconds)
[header] [impl]

Sleep helper for testing/debug timing.

static void usleep(uint32_t useconds)
[header] [impl]

Microsecond sleep helper for testing/debug timing.

static std::string pythonVersion()
[header] [impl]

Returns Python runtime version string.