975e44c7 |
1 | |
2 | #include <ltt/ltt.h> |
3 | |
4 | /* All event types and data types belong to their facilities and |
5 | are released at the same time. All fields belong to their tracefile and |
6 | are released at the same time. */ |
7 | |
8 | char *ltt_eventtype_name(ltt_eventtype *et); |
9 | |
10 | char *ltt_eventtype_description(ltt_eventtype *et); |
11 | |
12 | ltt_type *ltt_eventtype_type(ltt_eventtype *et); |
13 | |
14 | |
15 | /* obtain the type name and size. The size is the number of bytes for |
16 | primitive types (INT, UINT, FLOAT, ENUM), or the size for the unsigned |
17 | integer length count for sequences. */ |
18 | |
19 | char *ltt_type_name(ltt_type *t); |
20 | |
21 | ltt_type_enum *ltt_type_class(ltt_type *t); |
22 | |
23 | unsigned ltt_type_size(ltt_type *t); |
24 | |
25 | |
26 | /* The type of nested elements for arrays and sequences. */ |
27 | |
28 | ltt_type *ltt_type_element_type(ltt_type *t); |
29 | |
30 | |
31 | /* The number of elements for arrays. */ |
32 | |
33 | unsigned ltt_type_element_number(ltt_type *t); |
34 | |
35 | |
36 | /* The number of data members for structures. */ |
37 | |
38 | unsigned ltt_type_member_number(ltt_type *t); |
39 | |
40 | |
41 | /* The type of a data member in a structure. */ |
42 | |
43 | ltt_type *ltt_type_member_type(ltt_type *t, unsigned i); |
44 | |
45 | |
46 | /* For enumerations, obtain the symbolic string associated with a value |
47 | (0 to n - 1 for an enumeration of n elements). */ |
48 | |
49 | char *ltt_enum_string_get(ltt_type *t, unsigned i); |
50 | |
51 | |
52 | /* The fields form a tree representing a depth first search of the |
53 | corresponding event type directed acyclic graph. Fields for arrays and |
54 | sequences simply point to one nested field representing the currently |
55 | selected element among all the (identically typed) elements. For structures, |
56 | a nested field exists for each data member. Each field stores the |
57 | platform/tracefile specific offset values (for efficient access) and |
58 | points back to the corresponding ltt_type for the rest. */ |
59 | |
60 | ltt_field *ltt_field_element(ltt_field *f); |
61 | |
62 | ltt_field *ltt_field_member(ltt_field *f, unsigned i); |
63 | |
64 | ltt_type *ltt_field_type(ltt_field *f); |
65 | |