Remove enum before/after for description visitor
[libside.git] / src / visit-description.h
CommitLineData
f0619c77
MD
1// SPDX-License-Identifier: MIT
2/*
3 * Copyright 2024 Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
4 */
5
6#ifndef _VISIT_DESCRIPTION_H
7#define _VISIT_DESCRIPTION_H
8
9#include <side/trace.h>
10
f0619c77 11struct side_description_visitor {
10134383
MD
12 void (*before_event_func)(const struct side_event_description *desc, void *priv);
13 void (*after_event_func)(const struct side_event_description *desc, void *priv);
f0619c77 14
10134383
MD
15 void (*before_static_fields_func)(const struct side_event_description *desc, void *priv);
16 void (*after_static_fields_func)(const struct side_event_description *desc, void *priv);
f0619c77
MD
17
18 /* Stack-copy basic types. */
10134383
MD
19 void (*before_field_func)(const struct side_event_field *item_desc, void *priv);
20 void (*after_field_func)(const struct side_event_field *item_desc, void *priv);
21 void (*before_elem_func)(const struct side_type *type_desc, void *priv);
22 void (*after_elem_func)(const struct side_type *type_desc, void *priv);
23 void (*before_option_func)(const struct side_variant_option *option_desc, void *priv);
24 void (*after_option_func)(const struct side_variant_option *option_desc, void *priv);
f0619c77
MD
25
26 void (*null_type_func)(const struct side_type *type_desc, void *priv);
27 void (*bool_type_func)(const struct side_type *type_desc, void *priv);
28 void (*integer_type_func)(const struct side_type *type_desc, void *priv);
29 void (*byte_type_func)(const struct side_type *type_desc, void *priv);
30 void (*pointer_type_func)(const struct side_type *type_desc, void *priv);
31 void (*float_type_func)(const struct side_type *type_desc, void *priv);
32 void (*string_type_func)(const struct side_type *type_desc, void *priv);
33
34 /* Stack-copy compound types. */
10134383
MD
35 void (*before_struct_type_func)(const struct side_type_struct *side_struct, void *priv);
36 void (*after_struct_type_func)(const struct side_type_struct *side_struct, void *priv);
37 void (*before_variant_type_func)(const struct side_type_variant *side_variant, void *priv);
38 void (*after_variant_type_func)(const struct side_type_variant *side_variant, void *priv);
39 void (*before_array_type_func)(const struct side_type_array *side_array, void *priv);
40 void (*after_array_type_func)(const struct side_type_array *side_array, void *priv);
41 void (*before_vla_type_func)(const struct side_type_vla *side_vla, void *priv);
42 void (*after_length_vla_type_func)(const struct side_type_vla *side_vla, void *priv);
43 void (*after_element_vla_type_func)(const struct side_type_vla *side_vla, void *priv);
44 void (*before_vla_visitor_type_func)(const struct side_type_vla_visitor *side_vla_visitor, void *priv);
45 void (*after_length_vla_visitor_type_func)(const struct side_type_vla_visitor *side_vla_visitor, void *priv);
46 void (*after_element_vla_visitor_type_func)(const struct side_type_vla_visitor *side_vla_visitor, void *priv);
f0619c77
MD
47
48 /* Stack-copy enumeration types. */
10134383
MD
49 void (*before_enum_type_func)(const struct side_type *type_desc, void *priv);
50 void (*after_enum_type_func)(const struct side_type *type_desc, void *priv);
51 void (*before_enum_bitmap_type_func)(const struct side_type *type_desc, void *priv);
52 void (*after_enum_bitmap_type_func)(const struct side_type *type_desc, void *priv);
f0619c77
MD
53
54 /* Gather basic types. */
55 void (*gather_bool_type_func)(const struct side_type_gather_bool *type, void *priv);
56 void (*gather_byte_type_func)(const struct side_type_gather_byte *type, void *priv);
57 void (*gather_integer_type_func)(const struct side_type_gather_integer *type, void *priv);
58 void (*gather_pointer_type_func)(const struct side_type_gather_integer *type, void *priv);
59 void (*gather_float_type_func)(const struct side_type_gather_float *type, void *priv);
60 void (*gather_string_type_func)(const struct side_type_gather_string *type, void *priv);
61
62 /* Gather compound types. */
10134383
MD
63 void (*before_gather_struct_type_func)(const struct side_type_gather_struct *type, void *priv);
64 void (*after_gather_struct_type_func)(const struct side_type_gather_struct *type, void *priv);
65 void (*before_gather_array_type_func)(const struct side_type_gather_array *type, void *priv);
66 void (*after_gather_array_type_func)(const struct side_type_gather_array *type, void *priv);
67 void (*before_gather_vla_type_func)(const struct side_type_gather_vla *type, void *priv);
68 void (*after_length_gather_vla_type_func)(const struct side_type_gather_vla *type, void *priv);
69 void (*after_element_gather_vla_type_func)(const struct side_type_gather_vla *type, void *priv);
f0619c77
MD
70
71 /* Gather enumeration types. */
10134383
MD
72 void (*before_gather_enum_type_func)(const struct side_type_gather_enum *type, void *priv);
73 void (*after_gather_enum_type_func)(const struct side_type_gather_enum *type, void *priv);
f0619c77
MD
74
75 /* Dynamic types. */
76 void (*dynamic_type_func)(const struct side_type *type_desc, void *priv);
77};
78
79void description_visitor_event(const struct side_description_visitor *description_visitor,
80 const struct side_event_description *desc, void *priv);
81
82#endif /* _VISIT_DESCRIPTION_H */
This page took 0.043195 seconds and 4 git commands to generate.