*
* Return 0 on success else a negative LTTng error code.
*/
-int lttng_disable_event_ext(struct lttng_handle *handle,
+extern int lttng_disable_event_ext(struct lttng_handle *handle,
struct lttng_event *ev, const char *channel_name,
const char *filter_expression);
*
* Return a newly allocated health object, or NULL on error.
*/
-struct lttng_health *lttng_health_create_sessiond(void);
+extern struct lttng_health *lttng_health_create_sessiond(void);
/**
* lttng_health_create_consumerd - Create consumerd health object
*
* Return a newly allocated health object, or NULL on error.
*/
-struct lttng_health *
+extern struct lttng_health *
lttng_health_create_consumerd(enum lttng_health_consumerd consumerd);
/**
*
* Return a newly allocated health object, or NULL on error.
*/
-struct lttng_health *lttng_health_create_relayd(const char *path);
+extern struct lttng_health *lttng_health_create_relayd(const char *path);
/**
* lttng_health_destroy - Destroy health object
* @health: health object to destroy
*/
-void lttng_health_destroy(struct lttng_health *health);
+extern void lttng_health_destroy(struct lttng_health *health);
/**
* lttng_health_query - Query component health
* reports if the query has been successfully performed, *NOT* the
* actual state. lttng_health_state() should be used for the latter.
*/
-int lttng_health_query(struct lttng_health *health);
+extern int lttng_health_query(struct lttng_health *health);
/**
* lttng_health_state - Inspect the state of a health structure
* thread in error. It also returns a negative return value if
* lttng_health_query() has not yet successfully completed on @health.
*/
-int lttng_health_state(const struct lttng_health *health);
+extern int lttng_health_state(const struct lttng_health *health);
/**
* lttng_health_get_nr_threads - Get number of threads in health component
* Return the number of threads (>= 0) on success, else negative value
* on error.
*/
-int lttng_health_get_nr_threads(const struct lttng_health *health);
+extern int lttng_health_get_nr_threads(const struct lttng_health *health);
/**
* lttng_health_get_thread - Get thread health
* pointer should not be freed by the caller, and can be used until
* lttng_health_destroy() is called on @health.
*/
-const struct lttng_health_thread *
+extern const struct lttng_health_thread *
lttng_health_get_thread(const struct lttng_health *health,
unsigned int nth_thread);
*
* Return 0 if thread is OK, else negative error value.
*/
-int lttng_health_thread_state(const struct lttng_health_thread *thread);
+extern int lttng_health_thread_state(const struct lttng_health_thread *thread);
/**
* lttng_health_thread_name - Get thread name
*
* Return thread name, NULL on error.
*/
-const char *lttng_health_thread_name(const struct lttng_health_thread *thread);
+extern const char *lttng_health_thread_name(const struct lttng_health_thread *thread);
#ifdef __cplusplus
}
/*
* Return a newly allocated load session attribute object or NULL on error.
*/
-struct lttng_load_session_attr *lttng_load_session_attr_create(void);
+extern struct lttng_load_session_attr *lttng_load_session_attr_create(void);
/*
* Free a given load session attribute object.
*/
-void lttng_load_session_attr_destroy(struct lttng_load_session_attr *attr);
+extern void lttng_load_session_attr_destroy(struct lttng_load_session_attr *attr);
/*
*/
/* Return session name. NULL indicates all sessions must be loaded. */
-const char *lttng_load_session_attr_get_session_name(
+extern const char *lttng_load_session_attr_get_session_name(
struct lttng_load_session_attr *attr);
/*
* Return input URL. A NULL value indicates the default session
* configuration location. The URL format used is documented in lttng-create(1).
* NULL indicates that the default session configuration path is used.
*/
-const char *lttng_load_session_attr_get_input_url(
+extern const char *lttng_load_session_attr_get_input_url(
struct lttng_load_session_attr *attr);
/*
* same name already exists. If such a session exists, it is destroyed before
* the replacement is loaded.
*/
-int lttng_load_session_attr_get_overwrite(
+extern int lttng_load_session_attr_get_overwrite(
struct lttng_load_session_attr *attr);
/*
*
* NULL indicates no override will be applied on configuration load.
*/
-const char *lttng_load_session_attr_get_override_url(
+extern const char *lttng_load_session_attr_get_override_url(
struct lttng_load_session_attr *attr);
/*
*
* NULL indicates no control URL override will be applied on configuration load.
*/
-const char *lttng_load_session_attr_get_override_ctrl_url(
+extern const char *lttng_load_session_attr_get_override_ctrl_url(
struct lttng_load_session_attr *attr);
/*
*
* NULL indicates no data URL override will be applied on configuration load.
*/
-const char *lttng_load_session_attr_get_override_data_url(
+extern const char *lttng_load_session_attr_get_override_data_url(
struct lttng_load_session_attr *attr);
/*
* NULL indicates no session name override will be applied on configuration
* load.
*/
-const char *lttng_load_session_attr_get_override_session_name(
+extern const char *lttng_load_session_attr_get_override_session_name(
struct lttng_load_session_attr *attr);
/*
* Set the name of the session to load. A NULL name means all sessions
* found at the input URL will be loaded.
*/
-int lttng_load_session_attr_set_session_name(
+extern int lttng_load_session_attr_set_session_name(
struct lttng_load_session_attr *attr, const char *session_name);
/*
*
* Note that file:// is the only supported URL format.
*/
-int lttng_load_session_attr_set_input_url(
+extern int lttng_load_session_attr_set_input_url(
struct lttng_load_session_attr *attr, const char *url);
/*
* loaded sessions will be destroyed and be replaced by the session(s) being
* loaded.
*/
-int lttng_load_session_attr_set_overwrite(
+extern int lttng_load_session_attr_set_overwrite(
struct lttng_load_session_attr *attr, int overwrite);
/*
*
* See lttng-create(1) for more detail.
*/
-int lttng_load_session_attr_set_override_url(
+extern int lttng_load_session_attr_set_override_url(
struct lttng_load_session_attr *attr, const char *url);
/*
*
* See lttng-create(1) for more detail.
*/
-int lttng_load_session_attr_set_override_ctrl_url(
+extern int lttng_load_session_attr_set_override_ctrl_url(
struct lttng_load_session_attr *attr, const char *url);
/*
*
* See lttng-create(1) for more detail.
*/
-int lttng_load_session_attr_set_override_data_url(
+extern int lttng_load_session_attr_set_override_data_url(
struct lttng_load_session_attr *attr, const char *url);
/*
* Loading a configuration file defining multiple sessions will fail if a
* session name is provided.
*/
-int lttng_load_session_attr_set_override_session_name(
+extern int lttng_load_session_attr_set_override_session_name(
struct lttng_load_session_attr *attr, const char *session_name);
/*
*
* Returns 0 on success or a negative LTTNG_ERR value on error.
*/
-int lttng_load_session(struct lttng_load_session_attr *attr);
+extern int lttng_load_session(struct lttng_load_session_attr *attr);
#ifdef __cplusplus
}
*
* Returns an lttng_trigger object on success, NULL on error.
*/
-const struct lttng_trigger *lttng_notification_get_trigger(
+extern const struct lttng_trigger *lttng_notification_get_trigger(
struct lttng_notification *notification);
/*
/*
* Return a newly allocated save session attribute object or NULL on error.
*/
-struct lttng_save_session_attr *lttng_save_session_attr_create(void);
+extern struct lttng_save_session_attr *lttng_save_session_attr_create(void);
/*
* Free a given save session attribute object.
*/
-void lttng_save_session_attr_destroy(struct lttng_save_session_attr *output);
+extern void lttng_save_session_attr_destroy(struct lttng_save_session_attr *output);
/*
*/
/* Return session name. NULL indicated all sessions must be saved. */
-const char *lttng_save_session_attr_get_session_name(
+extern const char *lttng_save_session_attr_get_session_name(
struct lttng_save_session_attr *attr);
/*
* Return destination URL. A NULL value indicates the default session
* configuration location. The URL format used is documented in lttng(1).
* NULL indicates that the default session configuration path is used.
*/
-const char *lttng_save_session_attr_get_output_url(
+extern const char *lttng_save_session_attr_get_output_url(
struct lttng_save_session_attr *attr);
/*
* Return the configuration overwrite attribute. This attribute indicates
* whether or not existing configuration files must be overwritten.
*/
-int lttng_save_session_attr_get_overwrite(
+extern int lttng_save_session_attr_get_overwrite(
struct lttng_save_session_attr *attr);
/*
* Return the omit name configuration attribute. This attribute indicates
* whether or not the saved sessions' names should be omitted.
*/
-int lttng_save_session_attr_get_omit_name(
+extern int lttng_save_session_attr_get_omit_name(
struct lttng_save_session_attr *attr);
/*
* Return the omit output configuration attribute. This attribute indicates
* whether or not the saved sessions' output configuration should be omitted.
*/
-int lttng_save_session_attr_get_omit_output(
+extern int lttng_save_session_attr_get_omit_output(
struct lttng_save_session_attr *attr);
/*
* Set the name of the session to save. A NULL name means all sessions
* known to the session daemon will be saved.
*/
-int lttng_save_session_attr_set_session_name(
+extern int lttng_save_session_attr_set_session_name(
struct lttng_save_session_attr *attr, const char *session_name);
/*
* Set the URL of the session configuration to save. A NULL value indicates the
* use of the default location being the session one. The URL's format is is
* documented in lttng(1).
*/
-int lttng_save_session_attr_set_output_url(
+extern int lttng_save_session_attr_set_output_url(
struct lttng_save_session_attr *attr, const char *url);
/*
* Set the overwrite attribute. If set to true, files of the same name as the
* current session configuration URL will be overwritten.
*/
-int lttng_save_session_attr_set_overwrite(
+extern int lttng_save_session_attr_set_overwrite(
struct lttng_save_session_attr *attr, int overwrite);
/*
* Set the omit name attribute. If set to true, the sessions' names are omitted
* from the resulting session configuration file.
*/
-int lttng_save_session_attr_set_omit_name(
+extern int lttng_save_session_attr_set_omit_name(
struct lttng_save_session_attr *attr, int omit_name);
/*
* Set the omit output attribute. If set to true, the sessions' output
* configurations are omitted from the resulting session configuration file.
*/
-int lttng_save_session_attr_set_omit_output(
+extern int lttng_save_session_attr_set_omit_output(
struct lttng_save_session_attr *attr, int omit_output);
/*
*
* Returns 0 on success or a negative LTTNG_ERR value on error.
*/
-int lttng_save_session(struct lttng_save_session_attr *attr);
+extern int lttng_save_session(struct lttng_save_session_attr *attr);
#ifdef __cplusplus
}
/*
* Return an newly allocated snapshot output object or NULL on error.
*/
-struct lttng_snapshot_output *lttng_snapshot_output_create(void);
+extern struct lttng_snapshot_output *lttng_snapshot_output_create(void);
/*
* Free a given snapshot output object.
*/
-void lttng_snapshot_output_destroy(struct lttng_snapshot_output *output);
+extern void lttng_snapshot_output_destroy(struct lttng_snapshot_output *output);
/*
* Snapshot output getter family functions. They all return the value present
*/
/* Return snapshot ID. */
-uint32_t lttng_snapshot_output_get_id(const struct lttng_snapshot_output *output);
+extern uint32_t lttng_snapshot_output_get_id(const struct lttng_snapshot_output *output);
/* Return maximum size of a snapshot. */
-uint64_t lttng_snapshot_output_get_maxsize(const struct lttng_snapshot_output *output);
+extern uint64_t lttng_snapshot_output_get_maxsize(const struct lttng_snapshot_output *output);
/* Return snapshot name. */
-const char *lttng_snapshot_output_get_name(const struct lttng_snapshot_output *output);
+extern const char *lttng_snapshot_output_get_name(const struct lttng_snapshot_output *output);
/* Return snapshot control URL in a text format. */
-const char *lttng_snapshot_output_get_ctrl_url(const struct lttng_snapshot_output *output);
+extern const char *lttng_snapshot_output_get_ctrl_url(const struct lttng_snapshot_output *output);
/* Return snapshot data URL in a text format. */
-const char *lttng_snapshot_output_get_data_url(const struct lttng_snapshot_output *output);
+extern const char *lttng_snapshot_output_get_data_url(const struct lttng_snapshot_output *output);
/*
* Snapshot output setter family functions.
*/
/* Set a custom ID. */
-int lttng_snapshot_output_set_id(uint32_t id,
+extern int lttng_snapshot_output_set_id(uint32_t id,
struct lttng_snapshot_output *output);
/* Set the maximum size. */
-int lttng_snapshot_output_set_size(uint64_t size,
+extern int lttng_snapshot_output_set_size(uint64_t size,
struct lttng_snapshot_output *output);
/* Set the snapshot name. */
-int lttng_snapshot_output_set_name(const char *name,
+extern int lttng_snapshot_output_set_name(const char *name,
struct lttng_snapshot_output *output);
/*
*
* Return 0 on success or else a negative LTTNG_ERR code.
*/
-int lttng_snapshot_output_set_local_path(const char *path,
+extern int lttng_snapshot_output_set_local_path(const char *path,
struct lttng_snapshot_output *output);
/*
*
* Return 0 on success or else a negative LTTNG_ERR code.
*/
-int lttng_snapshot_output_set_network_url(const char *url,
+extern int lttng_snapshot_output_set_network_url(const char *url,
struct lttng_snapshot_output *output);
/*
*
* Return 0 on success or else a negative LTTNG_ERR code.
*/
-int lttng_snapshot_output_set_network_urls(
+extern int lttng_snapshot_output_set_network_urls(
const char *ctrl_url, const char *data_url,
struct lttng_snapshot_output *output);
/* Set the control URL. Local and remote URL are supported. */
-int lttng_snapshot_output_set_ctrl_url(const char *url,
+extern int lttng_snapshot_output_set_ctrl_url(const char *url,
struct lttng_snapshot_output *output);
/* Set the data URL. Local and remote URL are supported. */
-int lttng_snapshot_output_set_data_url(const char *url,
+extern int lttng_snapshot_output_set_data_url(const char *url,
struct lttng_snapshot_output *output);
/*
*
* Return 0 on success or else a negative LTTNG_ERR code.
*/
-int lttng_snapshot_add_output(const char *session_name,
+extern int lttng_snapshot_add_output(const char *session_name,
struct lttng_snapshot_output *output);
/*
*
* Return 0 on success or else a negative LTTNG_ERR code.
*/
-int lttng_snapshot_del_output(const char *session_name,
+extern int lttng_snapshot_del_output(const char *session_name,
struct lttng_snapshot_output *output);
/*
* Return 0 on success or else a negative LTTNG_ERR code and the list pointer
* is untouched.
*/
-int lttng_snapshot_list_output(const char *session_name,
+extern int lttng_snapshot_list_output(const char *session_name,
struct lttng_snapshot_output_list **list);
/*
* Return the next object on success or else NULL indicating the end of the
* list.
*/
-struct lttng_snapshot_output *lttng_snapshot_output_list_get_next(
+extern struct lttng_snapshot_output *lttng_snapshot_output_list_get_next(
struct lttng_snapshot_output_list *list);
/*
* Free an output list object.
*/
-void lttng_snapshot_output_list_destroy(struct lttng_snapshot_output_list *list);
+extern void lttng_snapshot_output_list_destroy(struct lttng_snapshot_output_list *list);
/*
* Snapshot a trace for the given session.
*
* Return 0 on success or else a negative LTTNG_ERR value.
*/
-int lttng_snapshot_record(const char *session_name,
+extern int lttng_snapshot_record(const char *session_name,
struct lttng_snapshot_output *output, int wait);
#ifdef __cplusplus
extern struct lttng_condition *lttng_trigger_get_condition(
struct lttng_trigger *trigger);
-const struct lttng_condition *lttng_trigger_get_const_condition(
+extern const struct lttng_condition *lttng_trigger_get_const_condition(
const struct lttng_trigger *trigger);
/*
extern struct lttng_action *lttng_trigger_get_action(
struct lttng_trigger *trigger);
-const struct lttng_action *lttng_trigger_get_const_action(
+extern const struct lttng_action *lttng_trigger_get_const_action(
const struct lttng_trigger *trigger);
/*