iterator documentation
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 19 May 2015 15:38:06 +0000 (11:38 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Sat, 27 May 2017 16:54:30 +0000 (12:54 -0400)
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
include/babeltrace/plugin/notification/iterator.h
include/babeltrace/plugin/plugin-system.h

index 51247d182ce50810d15a08ce84f4b7d4afbd8d8e..9c968f52f9fdf37428072f3492c67dcefbbdb22f 100644 (file)
@@ -57,15 +57,18 @@ enum bt_notification_iterator_status {
        BT_NOTIFICATION_ITERATOR_STATUS_OK = 0,
 };
 
+/**
+ * Notification iterator seek reference.
+ */
 enum bt_notification_iterator_seek_type {
        /** Seek at a time relative to the beginning of the trace. */
        BT_NOTIFICATION_ITERATOR_SEEK_TYPE_BEGIN = 0,
 
-       /** Seek at a time relative to the current position */
+       /** Seek at a time relative to the current position. */
        BT_NOTIFICATION_ITERATOR_SEEK_TYPE_CURRENT = 1,
 
-       /** Seek at a absolute time */
-       BT_NOTIFICATION_ITERATOR_SEEK_TYPE_SET = 2,
+       /** Seek at a time relative to the end of the trace. */
+       BT_NOTIFICATION_ITERATOR_SEEK_TYPE_END = 1,
 };
 
 /**
index 02c1f6f384410908fd7d22bfb2d1f32033852f7e..67406353b6133382ec8c1f4a75b6c959c9a658b2 100644 (file)
@@ -97,6 +97,7 @@ extern struct bt_plugin *bt_plugin_sink_create(const char *name,
                void *private_data, bt_plugin_destroy_func destroy_func,
                bt_plugin_sink_handle_notification_cb notification_cb);
 
+/* Notification iterator functions */
 /**
  * Allocate an notification iterator.
  *
@@ -110,6 +111,16 @@ extern struct bt_notification_iterator *bt_notification_iterator_create(
                bt_notification_iterator_next_cb next_cb,
                bt_notification_iterator_get_notification_cb notification_cb);
 
+/**
+ * Set an iterator's private data.
+ *
+ * @param plugin               Plug-in instance on which to iterate
+ * @param data                 Iterator private data
+ * @returns                    One of #bt_notification_iterator_status values
+ */
+extern enum bt_notification_iterator_status *bt_notification_iterator_create(
+               struct bt_plugin *plugin, void *data);
+
 #ifdef __cplusplus
 }
 #endif
This page took 0.025762 seconds and 4 git commands to generate.