2 * Copyright (C) 2019 Simon Marchi <simon.marchi@efficios.com>
4 * SPDX-License-Identifier: LGPL-2.1-only
8 #ifndef LTTNG_ACTION_SNAPSHOT_SESSION_H
9 #define LTTNG_ACTION_SNAPSHOT_SESSION_H
16 struct lttng_snapshot_output
;
19 * Create a newly allocated snapshot-session action object.
21 * A snapshot session action object must have a session name set to be
22 * considered valid when used with a trigger object (lttng_trigger). A name can
23 * be set using `lttng_action_snapshot_session_set_session_name`.
25 * Returns a new action on success, NULL on failure. This action must be
26 * destroyed using lttng_action_destroy().
28 extern struct lttng_action
*lttng_action_snapshot_session_create(void);
31 * Set the session name of an lttng_action object of type
32 * LTTNG_ACTION_TYPE_SNAPSHOT_SESSION.
34 extern enum lttng_action_status
lttng_action_snapshot_session_set_session_name(
35 struct lttng_action
*action
, const char *session_name
);
38 * Get the session name of an lttng_action object of type
39 * LTTNG_ACTION_TYPE_SNAPSHOT_SESSION.
41 extern enum lttng_action_status
lttng_action_snapshot_session_get_session_name(
42 const struct lttng_action
*action
, const char **session_name
);
45 * Set an explicit snapshot output for this snapshot session action.
47 * The given snapshot output will be used instead of the session's
48 * default snapshot output.
50 * This function takes ownership of the given snapshot output.
52 extern enum lttng_action_status
lttng_action_snapshot_session_set_output(
53 struct lttng_action
*action
,
54 struct lttng_snapshot_output
*output
);
57 * Get the explicit snapshot output for this snapshot session action.
59 extern enum lttng_action_status
lttng_action_snapshot_session_get_output(
60 const struct lttng_action
*action
,
61 const struct lttng_snapshot_output
**output
);
67 #endif /* LTTNG_ACTION_SNAPSHOT_SESSION_H */
This page took 0.031465 seconds and 4 git commands to generate.