actions: introduce lttng_action_init
[lttng-tools.git] / src / common / actions / action.c
index 982ca45ff27619f3c52d1ba6a15e937ae4b2b647..6894036cb779d09ced9c5acee4dacf9a2e99d876 100644 (file)
@@ -22,6 +22,20 @@ enum lttng_action_type lttng_action_get_type_const(
        return action->type;
 }
 
+LTTNG_HIDDEN
+void lttng_action_init(
+               struct lttng_action *action,
+               enum lttng_action_type type,
+               action_validate_cb validate,
+               action_serialize_cb serialize,
+               action_destroy_cb destroy)
+{
+       action->type = type;
+       action->validate = validate;
+       action->serialize = serialize;
+       action->destroy = destroy;
+}
+
 void lttng_action_destroy(struct lttng_action *action)
 {
        if (!action) {
This page took 0.023733 seconds and 5 git commands to generate.