Haka
|
Go to the source code of this file.
Data Structures | |
struct | time |
Macros | |
#define | TIME_BUFSIZE 27 |
#define | INVALID_TIME { 0, 0 } |
Functions | |
void | time_build (struct time *t, double secs) |
bool | time_gettimestamp (struct time *t) |
void | time_add (struct time *res, const struct time *t1, const struct time *t2) |
int | time_diff (struct time *res, const struct time *t1, const struct time *t2) |
uint64 | time_divide (const struct time *t1, const struct time *t2) |
void | time_mult (struct time *res, const struct time *t1, const int mult) |
int | time_cmp (const struct time *t1, const struct time *t2) |
double | time_sec (const struct time *t) |
bool | time_tostring (const struct time *t, char *buffer, size_t len) |
bool | time_format (const struct time *t, const char *format, char *buffer, size_t len) |
bool | time_isvalid (const struct time *t) |
Time representation.
#define INVALID_TIME { 0, 0 } |
Static initializer for the struct time.
#define TIME_BUFSIZE 27 |
String buffer minimum size.
Add two time object.
void time_build | ( | struct time * | t, |
double | secs | ||
) |
Build a new time structure from a number of seconds.
Compare two time object. It returns -1, 1 or 0 respectivelly if t1 is smaller than t2, t1 is larger than t2 or t1 is equal to t2.
Compute the difference between two time object. It returns the result of time_cmp(t1, t2).
Convert time to a formated string.
double time_sec | ( | const struct time * | t | ) |
Convert time to a number of seconds.
Convert time to a string.