X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=include%2Fbabeltrace%2Fctf-ir%2Fclock-value.h;h=5f30242793cde1b42879657916d9b8f56be4b455;hp=19b9aec6f3a381ba01b85c6222caa85795641c7f;hb=44c440bc5fe8219cc17d1b786d91fd83c4c9860a;hpb=c800eb3790218d2f33df01e77ec38cbd43cc02a1 diff --git a/include/babeltrace/ctf-ir/clock-value.h b/include/babeltrace/ctf-ir/clock-value.h index 19b9aec6..5f302427 100644 --- a/include/babeltrace/ctf-ir/clock-value.h +++ b/include/babeltrace/ctf-ir/clock-value.h @@ -31,9 +31,6 @@ * http://www.efficios.com/ctf */ -/* For bt_get() */ -#include - #include #ifdef __cplusplus @@ -43,20 +40,19 @@ extern "C" { struct bt_clock_class; struct bt_clock_value; -extern struct bt_clock_class *bt_clock_value_borrow_class( +enum bt_clock_value_status { + BT_CLOCK_VALUE_STATUS_KNOWN, + BT_CLOCK_VALUE_STATUS_UNKNOWN, +}; + +extern struct bt_clock_class *bt_clock_value_borrow_clock_class( struct bt_clock_value *clock_value); -static inline -struct bt_clock_class *bt_clock_value_get_class( - struct bt_clock_value *clock_value) -{ - return bt_get(bt_clock_value_borrow_class(clock_value)); -} +extern uint64_t bt_clock_value_get_value( + struct bt_clock_value *clock_value); -extern int bt_clock_value_get_value( - struct bt_clock_value *clock_value, uint64_t *raw_value); -extern int bt_clock_value_get_value_ns_from_epoch( - struct bt_clock_value *clock_value, int64_t *value_ns); +extern int bt_clock_value_get_ns_from_origin( + struct bt_clock_value *clock_value, int64_t *ns_from_origin); #ifdef __cplusplus }