Subject: Re: [boost] [chrono] v0.3.1 Support for wide characters
From: Joel Falcou (joel.falcou_at_[hidden])
Date: 2010-01-21 02:43:36
> A clock represents a bundle consisting of a native duration, a native time_point, and a function now() to get the current time_point. A clock must meet the requirements in the following Table.
> In this table C1 and C2 denote clock types. t1 and t2 are values returned from C1::now() where the call returning t1 happens before the call returning t2 and both of these calls happen before C1::time_point::max().
> Table 1. Clock Requirements
> expression return type operational semantics
> C1::rep An arithmetic type or class emulating an arithmetic type. The representation type of the native duration and time_point.
> C1::period ratio The tick period of the clock in seconds.
> C1::duration chrono::duration<C1::rep, C1::period> The native duration type of the clock.
> C1::time_point chrono::time_point<C1> or chrono::time_point<C2, C1::duration> The native time_point type of the clock. Different clocks are permitted to share a time_point definition if it is valid to compare their time_points by comparing their respective durations. C1 and C2 must refer to the same epoch.
> C1::is_monotonic const bool true if t1 <= t2 is always true, else false. Note: A clock that can be adjusted backwards is not monotonic
> C1::now() C1::time_point Returns a time_point representing the current point in time.
> You could find a better formmating on the documentation.
> As you can see, you need just to implement a static function returning this counter. The rest is pure formalism.
> Hoping this answer your questions.
Oh it does, it's even better this way :)
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk