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