equal
deleted
inserted
replaced
45 """ |
45 """ |
46 _fields_ = [("s", c_long), # tv_sec |
46 _fields_ = [("s", c_long), # tv_sec |
47 ("ns", c_long)] # tv_nsec |
47 ("ns", c_long)] # tv_nsec |
48 |
48 |
49 |
49 |
50 def _t(t, u=lambda x:x.value, p=lambda t,x:t(x)): return (t, u, p) |
50 def _t(t, u=lambda x:x.value, p=lambda t,x:t(x)): return (t, u, p) |
51 |
51 |
52 |
52 |
53 def _ttime(): return (IEC_TIME, |
53 def _ttime(): return (IEC_TIME, |
54 lambda x:td(0, x.s, x.ns/1000), |
54 lambda x:td(0, x.s, x.ns/1000), |
55 lambda t,x:t(x.days * 24 * 3600 + x.seconds, x.microseconds*1000)) |
55 lambda t,x:t(x.days * 24 * 3600 + x.seconds, x.microseconds*1000)) |