Audio 1.0.0
Public Member Functions | List of all members
Updater Class Reference

Github releases update checker. More...

#include <updater.h>

Public Member Functions

 Updater (std::string url, struct curl_slist *headers)
 Constructor. More...
 
 ~Updater ()
 Destructor. More...
 
std::string getLatestVersion ()
 Get GitHub latest release version code. More...
 
int compareVersions (std::string v1, std::string v2)
 Compare 2 version codes. More...
 

Detailed Description

Github releases update checker.

Author
Asiern
Since
Fri Aug 27 2021

Constructor & Destructor Documentation

◆ Updater()

Updater::Updater ( std::string  url,
struct curl_slist *  headers 
)

Constructor.

Parameters
urlGithub repo url
curl_slistRequest header list

◆ ~Updater()

Updater::~Updater ( )

Destructor.

Member Function Documentation

◆ compareVersions()

int Updater::compareVersions ( std::string  v1,
std::string  v2 
)

Compare 2 version codes.

Parameters
v1version code
v2version code
Returns
1 if v1>v2 | 0 if v1<= v2 | -1

◆ getLatestVersion()

std::string Updater::getLatestVersion ( )

Get GitHub latest release version code.

Returns
latest version code

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