Clean-up: sessiond: cmd_enable_channel_internal
[lttng-tools.git] / include / lttng / event-rule / event-rule-internal.h
index dd2d7dd18636b1560c655bf2a08eb1a7ca4d3cf7..8026748634fd0f9efa80121ee74c0d2499865ff5 100644 (file)
@@ -22,6 +22,7 @@
 
 struct lttng_payload;
 struct lttng_payload_view;
+struct mi_writer;
 
 enum lttng_event_rule_generate_exclusions_status {
        LTTNG_EVENT_RULE_GENERATE_EXCLUSIONS_STATUS_OK,
@@ -57,6 +58,9 @@ typedef unsigned long (*event_rule_hash_cb)(
                const struct lttng_event_rule *event_rule);
 typedef struct lttng_event *(*event_rule_generate_lttng_event_cb)(
                const struct lttng_event_rule *event_rule);
+typedef enum lttng_error_code (*event_rule_mi_serialize_cb)(
+               const struct lttng_event_rule *event_rule,
+               struct mi_writer *writer);
 
 struct lttng_event_rule {
        struct urcu_ref ref;
@@ -71,6 +75,7 @@ struct lttng_event_rule {
        event_rule_generate_exclusions_cb generate_exclusions;
        event_rule_hash_cb hash;
        event_rule_generate_lttng_event_cb generate_lttng_event;
+       event_rule_mi_serialize_cb mi_serialize;
 };
 
 struct lttng_event_rule_comm {
@@ -79,37 +84,28 @@ struct lttng_event_rule_comm {
        char payload[];
 };
 
-LTTNG_HIDDEN
 void lttng_event_rule_init(struct lttng_event_rule *event_rule,
                enum lttng_event_rule_type type);
 
-LTTNG_HIDDEN
 bool lttng_event_rule_validate(const struct lttng_event_rule *event_rule);
 
-LTTNG_HIDDEN
 ssize_t lttng_event_rule_create_from_payload(
                struct lttng_payload_view *payload,
                struct lttng_event_rule **event_rule);
 
-LTTNG_HIDDEN
 int lttng_event_rule_serialize(const struct lttng_event_rule *event_rule,
                struct lttng_payload *payload);
 
-LTTNG_HIDDEN
 bool lttng_event_rule_is_equal(const struct lttng_event_rule *a,
                const struct lttng_event_rule *b);
 
-LTTNG_HIDDEN
 bool lttng_event_rule_get(struct lttng_event_rule *rule);
 
-LTTNG_HIDDEN
 void lttng_event_rule_put(struct lttng_event_rule *rule);
 
-LTTNG_HIDDEN
 enum lttng_domain_type lttng_event_rule_get_domain_type(
                const struct lttng_event_rule *rule);
 
-LTTNG_HIDDEN
 enum lttng_error_code lttng_event_rule_generate_filter_bytecode(
                struct lttng_event_rule *rule,
                const struct lttng_credentials *creds);
@@ -118,14 +114,12 @@ enum lttng_error_code lttng_event_rule_generate_filter_bytecode(
  * If not present/implemented returns NULL.
  * Caller DOES NOT own the returned object.
  */
-LTTNG_HIDDEN
 const char *lttng_event_rule_get_filter(const struct lttng_event_rule *rule);
 
 /*
  * If not present/implemented returns NULL.
  * Caller DOES NOT own the returned object.
  */
-LTTNG_HIDDEN
 const struct lttng_bytecode *lttng_event_rule_get_filter_bytecode(
                const struct lttng_event_rule *rule);
 
@@ -133,15 +127,12 @@ const struct lttng_bytecode *lttng_event_rule_get_filter_bytecode(
  * If not present/implemented return NULL.
  * Caller OWNS the returned object.
  */
-LTTNG_HIDDEN
 enum lttng_event_rule_generate_exclusions_status
 lttng_event_rule_generate_exclusions(const struct lttng_event_rule *rule,
                struct lttng_event_exclusion **exclusions);
 
-LTTNG_HIDDEN
 const char *lttng_event_rule_type_str(enum lttng_event_rule_type type);
 
-LTTNG_HIDDEN
 unsigned long lttng_event_rule_hash(const struct lttng_event_rule *rule);
 
 /*
@@ -153,12 +144,13 @@ unsigned long lttng_event_rule_hash(const struct lttng_event_rule *rule);
  *
  * The caller owns the returned object.
  */
-LTTNG_HIDDEN
 struct lttng_event *lttng_event_rule_generate_lttng_event(
                const struct lttng_event_rule *rule);
 
 /* Test if an event rule targets an agent domain. */
-LTTNG_HIDDEN
 bool lttng_event_rule_targets_agent_domain(const struct lttng_event_rule *rule);
 
+enum lttng_error_code lttng_event_rule_mi_serialize(
+               const struct lttng_event_rule *rule, struct mi_writer *writer);
+
 #endif /* LTTNG_EVENT_RULE_INTERNAL_H */
This page took 0.025108 seconds and 4 git commands to generate.