SoW-2020-0003: Trace Hit Counters
[lttng-tools.git] / include / lttng / action / incr-value-internal.h
1 /*
2 * Copyright (C) 2020 Francis Deslauriers <francis.deslauriers@efficios.com>
3 *
4 * SPDX-License-Identifier: LGPL-2.1-only
5 *
6 */
7
8 #ifndef LTTNG_ACTION_INCR_VALUE_INTERNAL_H
9 #define LTTNG_ACTION_INCR_VALUE_INTERNAL_H
10
11 #include <inttypes.h>
12
13 #include <common/macros.h>
14
15 struct lttng_action;
16 struct lttng_payload_view;
17 struct lttng_map_key;
18
19 /*
20 * Create a "incr-value" action from a payload view.
21 *
22 * On success, return the number of bytes consumed from `view`, and the created
23 * action in `*action`. On failure, return -1.
24 */
25 LTTNG_HIDDEN
26 extern ssize_t lttng_action_incr_value_create_from_payload(
27 struct lttng_payload_view *view,
28 struct lttng_action **action);
29
30 LTTNG_HIDDEN
31 enum lttng_action_status lttng_action_incr_value_borrow_key_mutable(
32 const struct lttng_action *action, struct lttng_map_key **key);
33
34 LTTNG_HIDDEN
35 enum lttng_action_status lttng_action_incr_value_set_tracer_token(
36 struct lttng_action *action, uint64_t token);
37
38 LTTNG_HIDDEN
39 uint64_t lttng_action_incr_value_get_tracer_token(
40 const struct lttng_action *action);
41
42 #endif /* LTTNG_ACTION_INCR_VALUE_INTERNAL_H */
This page took 0.03159 seconds and 5 git commands to generate.