21 lines
609 B
C++
21 lines
609 B
C++
#ifndef TIME_HPP_INCLUDED
|
|
#define TIME_HPP_INCLUDED
|
|
|
|
#include <cstdint>
|
|
#include <functional>
|
|
|
|
/** @addtogroup Time
|
|
* @{ */
|
|
|
|
void Wait(std::int64_t Duration);
|
|
std::uint64_t CurrentTimeMillis();
|
|
std::uint64_t CurrentTimeNanos();
|
|
bool WaitFunc(std::uint32_t Duration, std::uint32_t Step, std::function<bool()> Func);
|
|
bool WaitFunc(std::uint32_t Duration, std::uint32_t Step, std::function<bool()> Func, bool Result);
|
|
std::string MillisToHumanShort(std::int64_t Millseconds); // HH:MM:SS
|
|
std::string MillisToHumanLong(std::int64_t Millseconds); // Hours, Minutes, Seconds
|
|
|
|
/** @} */
|
|
|
|
#endif // TIME_HPP_INCLUDED
|