X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=include%2Fbabeltrace%2Fctf-writer%2Fclock.h;fp=include%2Fbabeltrace%2Fctf-writer%2Fclock.h;h=1bacc34e2aa14a57894b5a49f2fd3e9c566cda54;hb=64cf1d3a1cc21cdb2aff576a268dd2e6989a5510;hp=cb17ca2b0f2e0c529717aa4b4b8f5efa27e56c6d;hpb=54e27fc12f9f976b615b34fb2a48da98f0ce1dcd;p=babeltrace.git diff --git a/include/babeltrace/ctf-writer/clock.h b/include/babeltrace/ctf-writer/clock.h index cb17ca2b..1bacc34e 100644 --- a/include/babeltrace/ctf-writer/clock.h +++ b/include/babeltrace/ctf-writer/clock.h @@ -36,6 +36,24 @@ extern "C" { #endif +extern int bt_ctf_clock_get_time(struct bt_ctf_clock *clock, int64_t *time); + +/* + * bt_ctf_clock_set_time: set a clock's current time value. + * + * Set the current time in nanoseconds since the clock's origin (offset and + * offset_s attributes). Defaults to 0. + * + * Returns 0 on success, a negative value on error. + */ +extern int bt_ctf_clock_set_time(struct bt_ctf_clock *clock, + int64_t time); + +extern uint64_t bt_ctf_clock_get_value(struct bt_ctf_clock *clock); + +extern int bt_ctf_clock_set_value(struct bt_ctf_clock *clock, + uint64_t value); + /* * bt_ctf_clock_get and bt_ctf_clock_put: increment and decrement the * refcount of the clock