ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
Version Struct Reference

Simple representation of a SemVer version. More...

#include <PythonConfig.h>

Public Member Functions

constexpr Version ()=default
 
constexpr Version (uint16_t major_, uint16_t minor_, uint16_t patch_)
 
 Version (const QtCompatStringRef &versionStr)
 
bool isCompatibleWithCompiledVersion () const
 
bool isNull () const
 
bool operator== (const Version &other) const
 

Public Attributes

uint16_t versionMajor {0}
 
uint16_t versionMinor {0}
 
uint16_t versionPatch {0}
 

Detailed Description

Simple representation of a SemVer version.

Constructor & Destructor Documentation

◆ Version() [1/3]

constexpr Version::Version ( )
constexprdefault

◆ Version() [2/3]

constexpr Version::Version ( uint16_t  major_,
uint16_t  minor_,
uint16_t  patch_ 
)
inlineconstexpr

◆ Version() [3/3]

Version::Version ( const QtCompatStringRef &  versionStr)
explicit

Member Function Documentation

◆ isCompatibleWithCompiledVersion()

bool Version::isCompatibleWithCompiledVersion ( ) const

Checks whether the Python version number described by this instance is compatible with the Python version the plugin was compiled with.

As explained in https://docs.python.org/3/c-api/stable.html#stable: CPython’s Application Binary Interface (ABI) is forward- and backwards-compatible across a minor release. So, code compiled for Python 3.10.0 will work on 3.10.8 and vice versa, but will need to be compiled separately for 3.9.x and 3.10.x.

Returns
True if the version is compatible.

References PythonVersion(), versionMajor, and versionMinor.

Referenced by PythonConfig::validateAndDisplayErrors().

◆ isNull()

bool Version::isNull ( ) const
inline

◆ operator==()

bool Version::operator== ( const Version &  other) const

Member Data Documentation

◆ versionMajor

◆ versionMinor

◆ versionPatch

uint16_t Version::versionPatch {0}

The documentation for this struct was generated from the following files: