lib: rename transforming bt_X_borrow_Y() -> bt_X_as_Y()
[babeltrace.git] / include / babeltrace / trace-ir / private-event.h
CommitLineData
e5be10ef
PP
1#ifndef BABELTRACE_TRACE_IR_PRIVATE_EVENT_H
2#define BABELTRACE_TRACE_IR_PRIVATE_EVENT_H
3
4/*
5 * Copyright 2013, 2014 Jérémie Galarneau <jeremie.galarneau@efficios.com>
6 *
7 * Author: Jérémie Galarneau <jeremie.galarneau@efficios.com>
8 *
9 * Permission is hereby granted, free of charge, to any person obtaining a copy
10 * of this software and associated documentation files (the "Software"), to deal
11 * in the Software without restriction, including without limitation the rights
12 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
13 * copies of the Software, and to permit persons to whom the Software is
14 * furnished to do so, subject to the following conditions:
15 *
16 * The above copyright notice and this permission notice shall be included in
17 * all copies or substantial portions of the Software.
18 *
19 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
24 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
25 * SOFTWARE.
26 *
27 * The Common Trace Format (CTF) Specification is available at
28 * http://www.efficios.com/ctf
29 */
30
31#ifdef __cplusplus
32extern "C" {
33#endif
34
35struct bt_private_event;
36struct bt_private_event_header_field;
37struct bt_private_event_class;
38struct bt_private_field;
39struct bt_private_packet;
40
d94d92ac 41static inline
707b7d35 42struct bt_event *bt_private_event_as_event(
d94d92ac
PP
43 struct bt_private_event *priv_event)
44{
45 return (void *) priv_event;
46}
e5be10ef
PP
47
48extern struct bt_private_event_class *bt_private_event_borrow_class(
49 struct bt_private_event *event);
50
51extern struct bt_private_packet *bt_private_event_borrow_packet(
52 struct bt_private_event *event);
53
54extern struct bt_private_stream *bt_private_event_borrow_stream(
55 struct bt_private_event *event);
56
28e6ca8b 57extern struct bt_private_field *bt_private_event_borrow_header_field(
e5be10ef
PP
58 struct bt_private_event *event);
59
28e6ca8b 60extern int bt_private_event_move_header_field(
e5be10ef
PP
61 struct bt_private_event *event,
62 struct bt_private_event_header_field *header);
63
64extern struct bt_private_field *
28e6ca8b 65bt_private_event_borrow_common_context_field(
e5be10ef
PP
66 struct bt_private_event *event);
67
68extern struct bt_private_field *
28e6ca8b 69bt_private_event_borrow_specific_context_field(
e5be10ef
PP
70 struct bt_private_event *event);
71
28e6ca8b 72extern struct bt_private_field *bt_private_event_borrow_payload_field(
e5be10ef
PP
73 struct bt_private_event *event);
74
140e6d94 75extern void bt_private_event_set_default_clock_value(
e5be10ef
PP
76 struct bt_private_event *event, uint64_t value_cycles);
77
78#ifdef __cplusplus
79}
80#endif
81
82#endif /* BABELTRACE_TRACE_IR_PRIVATE_EVENT_H */
This page took 0.029135 seconds and 4 git commands to generate.