Skip to content

Pylon::VersionInfo#

Holds a four-part version number consisting of major.minor.subminor.build. More…

#include <pylon/PylonVersionInfo.h>

Public Functions#

Name
VersionInfo(bool checkBuild =false)
VersionInfo(unsigned int major, unsigned int minor, unsigned int subminor)
Constructs a version info object using the version number parts passed.
VersionInfo(unsigned int major, unsigned int minor, unsigned int subminor, unsigned int build)
Constructs a version info object using the version number parts passed.
~VersionInfo(void )
The VersionInfo destructor.
unsigned int getMajor() const
unsigned int getMinor() const
unsigned int getSubminor() const
unsigned int getBuild() const
bool operator>(const VersionInfo & rhs) const
Compares two version info objects.
bool operator==(const VersionInfo & rhs) const
Compares two version info objects.
bool operator>=(const VersionInfo & rhs) const
Compares two version info objects.
bool operator<(const VersionInfo & rhs) const
Compares two version info objects.
bool operator!=(const VersionInfo & rhs) const
Compares two version info objects.
bool operator<=(const VersionInfo & rhs) const
compares two version info objects.
const char * getVersionString()
Returns the complete version number as a string.

Protected Attributes#

Name
unsigned int m_major
unsigned int m_minor
unsigned int m_subminor
unsigned int m_build
bool m_checkBuild

Detailed Description#

class Pylon::VersionInfo;

Holds a four-part version number consisting of major.minor.subminor.build.

This class stores a four-part version number and provides comparison operators. If you use the constructor with one parameter, the version info object will be initialized with pylon base version numbers.

You can also call the static getVersionString() method to retrieve a string containing the complete version separated by dots.

Public Functions Documentation#

VersionInfo#

inline explicit VersionInfo(
    bool checkBuild =false
)

Constructs a version info object using pylon base version numbers. If checkBuild is set to false, the build number will not be used in comparison operators.

VersionInfo#

inline VersionInfo(
    unsigned int major,
    unsigned int minor,
    unsigned int subminor
)

Constructs a version info object using the version number parts passed.

VersionInfo#

inline VersionInfo(
    unsigned int major,
    unsigned int minor,
    unsigned int subminor,
    unsigned int build
)

Constructs a version info object using the version number parts passed.

~VersionInfo#

inline ~VersionInfo(
    void 
)

The VersionInfo destructor.

getMajor#

inline unsigned int getMajor() const

Returns the major version number. For version 2.1.3.1234 the value 2 would be returned.

getMinor#

inline unsigned int getMinor() const

Returns the minor version number. For version 2.1.3.1234 the value 1 would be returned.

getSubminor#

inline unsigned int getSubminor() const

Returns the subminor version number. For version 2.1.3.1234 the value 3 would be returned.

getBuild#

inline unsigned int getBuild() const

Returns the build number. For version 2.1.3.1234 the value 1234 would be returned.

operator>#

inline bool operator>(
    const VersionInfo & rhs
) const

Compares two version info objects.

operator==#

inline bool operator==(
    const VersionInfo & rhs
) const

Compares two version info objects.

operator>=#

inline bool operator>=(
    const VersionInfo & rhs
) const

Compares two version info objects.

operator<#

inline bool operator<(
    const VersionInfo & rhs
) const

Compares two version info objects.

operator!=#

inline bool operator!=(
    const VersionInfo & rhs
) const

Compares two version info objects.

operator<=#

inline bool operator<=(
    const VersionInfo & rhs
) const

compares two version info objects.

getVersionString#

static inline const char * getVersionString()

Returns the complete version number as a string.

Protected Attributes Documentation#

m_major#

unsigned int m_major;

m_minor#

unsigned int m_minor;

m_subminor#

unsigned int m_subminor;

m_build#

unsigned int m_build;

m_checkBuild#

bool m_checkBuild;

Updated on 5 July 2022 at 15:30:00