Commit | Line | Data |
---|---|---|
a3f0c7db | 1 | /* |
0235b0db MJ |
2 | * SPDX-License-Identifier: MIT |
3 | * | |
a3f0c7db SM |
4 | * Copyright 2017-2018 Philippe Proulx <pproulx@efficios.com> |
5 | * Copyright 2015 Jérémie Galarneau <jeremie.galarneau@efficios.com> | |
a3f0c7db SM |
6 | */ |
7 | ||
ae2be88d SM |
8 | #ifndef BABELTRACE_LIB_GRAPH_MESSAGE_ITERATOR_CLASS_H |
9 | #define BABELTRACE_LIB_GRAPH_MESSAGE_ITERATOR_CLASS_H | |
0235b0db | 10 | |
a3f0c7db SM |
11 | #include <babeltrace2/graph/message-iterator-class.h> |
12 | #include <babeltrace2/types.h> | |
a3f0c7db SM |
13 | #include "lib/object.h" |
14 | #include <stdbool.h> | |
15 | #include <glib.h> | |
16 | ||
17 | struct bt_message_iterator_class { | |
18 | struct bt_object base; | |
19 | bool frozen; | |
20 | ||
21 | struct { | |
22 | bt_message_iterator_class_initialize_method initialize; | |
23 | bt_message_iterator_class_finalize_method finalize; | |
24 | bt_message_iterator_class_next_method next; | |
25 | bt_message_iterator_class_seek_ns_from_origin_method seek_ns_from_origin; | |
26 | bt_message_iterator_class_seek_beginning_method seek_beginning; | |
27 | bt_message_iterator_class_can_seek_ns_from_origin_method can_seek_ns_from_origin; | |
28 | bt_message_iterator_class_can_seek_beginning_method can_seek_beginning; | |
29 | } methods; | |
30 | }; | |
31 | ||
a3f0c7db SM |
32 | void _bt_message_iterator_class_freeze( |
33 | const struct bt_message_iterator_class *message_iterator_class); | |
34 | ||
35 | #ifdef BT_DEV_MODE | |
36 | # define bt_message_iterator_class_freeze _bt_message_iterator_class_freeze | |
37 | #else | |
38 | # define bt_message_iterator_class_freeze(_cls) | |
39 | #endif | |
40 | ||
ae2be88d | 41 | #endif /* BABELTRACE_LIB_GRAPH_MESSAGE_ITERATOR_CLASS_H */ |