![]() |
KVIrc 5.2.0
Developer APIs
|
Time management. More...
Go to the source code of this file.
Classes | |
class | KviMSecTimeInterval |
A class to retrieve the time interval This works for time intervals a bit longer than 24 days. More... | |
Namespaces | |
namespace | KviTimeUtils |
Time utilities. | |
Macros | |
#define | kvi_secondsSince(_that_time_t) kvi_timeSpan(kvi_unixTime(), _that_time_t) |
#define | kvi_time_t time_t |
#define | kvi_timeSpan(_time_now, _time_before) ((_time_now) - (_time_before)) |
#define | kvi_unixTime() time(0) |
Enumerations | |
enum | KviTimeUtils::FormatTimeSpanFlags { KviTimeUtils::NoLeadingEmptyIntervals = 1 , KviTimeUtils::NoLeadingZeroes = 2 , KviTimeUtils::FillWithHypens = 4 } |
Functions | |
QString | KviTimeUtils::formatTimeInterval (unsigned int uSeconds, int iFlags=0) |
Returns a string formatted like x d x h xx m xx s. | |
long long | KviTimeUtils::getCurrentTimeMills () |
Returns the current time mills. | |
void | kvi_gettimeofday (struct timeval *tmv) |
Gets the time of the day. | |
void | KviTimeUtils::secondsToDaysHoursMinsSecs (unsigned int uSecs, unsigned int *uD, unsigned int *uH, unsigned int *uM, unsigned int *uS) |
Splits the time span uSecs in days, hours, minutes and seconds. | |
Time management.
#define kvi_secondsSince | ( | _that_time_t | ) | kvi_timeSpan(kvi_unixTime(), _that_time_t) |
#define kvi_time_t time_t |
#define kvi_timeSpan | ( | _time_now, | |
_time_before | |||
) | ((_time_now) - (_time_before)) |
#define kvi_unixTime | ( | ) | time(0) |
|
inline |
Gets the time of the day.
tmv | The time value |
tmz | The timezone |
Referenced by KviIrcSocket::flushSendQueue(), KviIrcServer::generateUniqueId(), KviTimeUtils::getCurrentTimeMills(), KviApplication::getTmpFileName(), KviKvsCoreFunctions::KVSCF(), KviKvsCoreSimpleCommands::KVSCSC(), KviLagMeter::lagCheckComplete(), KviLagMeter::lagCheckRegister(), KviMSecTimeInterval::mark(), KviIrcServerParser::parseCtcpReplyPing(), KviLagMeter::secondsSinceLastCompleted(), and KviLagMeter::timerEvent().