Fix (Python bindings): Return a string if a sequence's element are chars
[babeltrace.git] / bindings / python / python-complements.h
1 /*
2 * python-complements.h
3 *
4 * Babeltrace Python module complements header, required for Python bindings
5 *
6 * Copyright 2012 EfficiOS Inc.
7 *
8 * Author: Danny Serres <danny.serres@efficios.com>
9 *
10 * Permission is hereby granted, free of charge, to any person obtaining a copy
11 * of this software and associated documentation files (the "Software"), to deal
12 * in the Software without restriction, including without limitation the rights
13 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14 * copies of the Software, and to permit persons to whom the Software is
15 * furnished to do so, subject to the following conditions:
16 *
17 * The above copyright notice and this permission notice shall be included in
18 * all copies or substantial portions of the Software.
19 */
20
21 #include <stdio.h>
22 #include <glib.h>
23 #include <babeltrace/babeltrace.h>
24 #include <babeltrace/format.h>
25 #include <babeltrace/ctf-ir/metadata.h>
26 #include <babeltrace/ctf/events.h>
27 #include <babeltrace/iterator-internal.h>
28 #include <babeltrace/ctf/events-internal.h>
29 #include <babeltrace/ctf-writer/event-fields.h>
30
31 /* File */
32 FILE *_bt_file_open(char *file_path, char *mode);
33 void _bt_file_close(FILE *fp);
34
35 /* ctf-field-list */
36 struct bt_definition **_bt_python_field_listcaller(
37 const struct bt_ctf_event *ctf_event,
38 const struct bt_definition *scope,
39 unsigned int *len);
40 struct bt_definition *_bt_python_field_one_from_list(
41 struct bt_definition **list, int index);
42
43 /* event_decl_list */
44 struct bt_ctf_event_decl **_bt_python_event_decl_listcaller(
45 int handle_id,
46 struct bt_context *ctx,
47 unsigned int *len);
48 struct bt_ctf_event_decl *_bt_python_decl_one_from_list(
49 struct bt_ctf_event_decl **list, int index);
50
51 /* decl_fields */
52 struct bt_ctf_field_decl **_by_python_field_decl_listcaller(
53 struct bt_ctf_event_decl *event_decl,
54 enum bt_ctf_scope scope,
55 unsigned int *len);
56 struct bt_ctf_field_decl *_bt_python_field_decl_one_from_list(
57 struct bt_ctf_field_decl **list, int index);
58
59 /* definitions */
60 struct definition_array *_bt_python_get_array_from_def(
61 struct bt_definition *field);
62 struct definition_sequence *_bt_python_get_sequence_from_def(
63 struct bt_definition *field);
64 struct bt_declaration *_bt_python_get_array_element_declaration(
65 struct bt_declaration *field);
66 struct bt_declaration *_bt_python_get_sequence_element_declaration(
67 struct bt_declaration *field);
68 const char *_bt_python_get_array_string(struct bt_definition *field);
69 const char *_bt_python_get_sequence_string(struct bt_definition *field);
70
71 /* ctf writer */
72 int _bt_python_field_integer_get_signedness(const struct bt_ctf_field *field);
73 enum ctf_type_id _bt_python_get_field_type(const struct bt_ctf_field *field);
This page took 0.029662 seconds and 4 git commands to generate.