VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Static Public Member Functions | Static Private Member Functions
DtInstallationFinder Class Reference

Finds installed MAK Technologies software on this machine.

On Windows, discovery first enumerates the HKEY_LOCAL_MACHINE Technologies registry key. If no registry entry with a valid install path is found, a fallback scan is performed: immediate subdirectories of the MAK install root are checked for a name matching the product (case-insensitive) and, for known products, a probe file is verified to confirm a real installation. The install root is MAK_INSTALL_DIR% when that environment variable is set, otherwise C:\MAK.

On Linux, discovery performs a bounded recursive scan (max depth 3) of the MAK install root ($MAK_INSTALL_DIR if set, otherwise $HOME/MAK). A directory is accepted only when its name matches the product substring (case-insensitive) AND a product-specific probe file exists under it (e.g. bin64/loggerDIS for MAK Data Logger, bin64/netdumpDIS for VR-Link). This handles both flat layouts ( <root>/vrlink5.10b/) and wrapper layouts ( <root>/vrLink5.10b-linux64-rhe9-20260630/vrlink5.10b/).

Classes

struct  DtSoftwareInfo
 

Static Public Member Functions

static DtSoftwareInfo findHighestMakVersionByName (const std::string &softwareNamePattern)
 
static std::string extractVersionFromName (const std::string &appName)
 

Static Private Member Functions

static int compareVersions (const std::string &version1, const std::string &version2)
 
static std::vector< int > parseVersion (const std::string &version)
 

Member Function Documentation

static DtSoftwareInfo DtInstallationFinder::findHighestMakVersionByName ( const std::string &  softwareNamePattern)
static

Finds the highest-versioned MAK product whose install name matches softwareNamePattern.

On Windows, softwareNamePattern is matched as a substring against registry subkey names under SOFTWARE Technologies (for example "MAK Data Logger", "VR-Link"). On Linux, the same input string is translated internally to the corresponding install-directory substring (for example "makLogger", "vrlink") before scanning the MAK install root.

Parameters
softwareNamePatternProduct name pattern (Windows-style; e.g. "VR-Link").
Returns
The highest-versioned install found, or an empty DtSoftwareInfo if none matched.
static std::string DtInstallationFinder::extractVersionFromName ( const std::string &  appName)
static

Extracts a numeric version (for example "5.12" or "5.10b") from an install/subkey name.

Scans for the first run of digits and dots, optionally followed by a single ASCII patch letter (e.g. the "b" in "5.10b"). A trailing letter is included only when the next character is a boundary (end-of-string or a non-alphanumeric), so build tags like "5.13TOT20260617" still yield "5.13" rather than "5.13T".

Patch letters are ordered case-insensitively: 5.10 < 5.10a < 5.10b < 5.11.

Parameters
appNameInstall directory name (Linux) or registry subkey name (Windows).
Returns
Version string (possibly with trailing patch letter), or empty when none found.
static int DtInstallationFinder::compareVersions ( const std::string &  version1,
const std::string &  version2 
)
staticprivate
static std::vector<int> DtInstallationFinder::parseVersion ( const std::string &  version)
staticprivate

The documentation for this class was generated from the following file:

Document ID: Generated on Thu Oct 15 21:27:02 EDT 2026 from SVN revision 296421
Copyright © 2005-2026 MAK Technologies. All Rights Reserved (www.mak.com)