AlpacaLibrary/Include/Core/Time.hpp

21 lines
609 B
C++
Raw Normal View History

2017-12-25 23:49:48 +00:00
#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);
2018-03-09 20:10:43 +00:00
std::string MillisToHumanShort(std::int64_t Millseconds); // HH:MM:SS
std::string MillisToHumanLong(std::int64_t Millseconds); // Hours, Minutes, Seconds
2017-12-25 23:49:48 +00:00
/** @} */
#endif // TIME_HPP_INCLUDED