Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 38 lines (26 sloc) 0.561 kB
cba273e @tj Initial commit
tj authored
1
2 //
3 // ms.h
4 //
5 // Copyright (c) 2012 TJ Holowaychuk <tj@vision-media.ca>
6 //
7
8 #ifndef MS
9 #define MS
10
bb699a5 @tj Added milliseconds_to_string()
tj authored
11 // max buffer length
12
13 #ifndef MS_MAX
14 #define MS_MAX 256
15 #endif
16
17 // aliases
18
cba273e @tj Initial commit
tj authored
19 #define strtous string_to_microseconds
20 #define strtoms string_to_milliseconds
bb699a5 @tj Added milliseconds_to_string()
tj authored
21 #define mstostr milliseconds_to_string
22 #define mstolstr milliseconds_to_long_string
23
24 // prototypes
cba273e @tj Initial commit
tj authored
25
26 long long
27 string_to_microseconds(const char *str);
28
29 long long
30 string_to_milliseconds(const char *str);
31
bb699a5 @tj Added milliseconds_to_string()
tj authored
32 char *
33 milliseconds_to_string(long long ms);
34
e0c0089 @tj added milliseconds_to_long_string() to ms.h
tj authored
35 char *
36 milliseconds_to_long_string(long long ms);
37
cba273e @tj Initial commit
tj authored
38 #endif
Something went wrong with that request. Please try again.