LTAPI
API to access LiveTraffic's aircraft information
Functions
LTAPI Namespace Reference

Functions

time_t timegm (struct tm *_Tm)
 Inverse for gmtime, i.e. converts struct tm to time_t in ZULU timezone. More...
 
std::string hexStr (uint64_t n, unsigned minChars=6)
 Fairly fast conversion to hex string. More...
 

Function Documentation

◆ hexStr()

std::string LTAPI::hexStr ( uint64_t  n,
unsigned  minChars = 6 
)

Fairly fast conversion to hex string.

Parameters
nThe number to convert
minChars(optional, defaults to 6) minimum number of hex digits, pre-filled with 0 @return Upper-case hex string with at leastminDigits` characters

Idea is taken from std::to_chars implementation available with C++ 17

◆ timegm()

time_t LTAPI::timegm ( struct tm *  _Tm)

Inverse for gmtime, i.e. converts struct tm to time_t in ZULU timezone.

Parameters
_TmDate/time structure to convert
Returns
Same Date/time, converted to time_tin ZULU timezone