X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=src%2Fcommon%2Fmi-lttng.h;h=76455c25ca4161f644e7928538e742e1407dcd54;hb=b7238f7cfdcc67f4c254c03004989156c13c4c15;hp=a5c448023618a8a789e7e50c9ec04a4a11da305f;hpb=ab5be9fa2eb5ba9600a82cd18fd3cfcbac69169a;p=lttng-tools.git diff --git a/src/common/mi-lttng.h b/src/common/mi-lttng.h index a5c448023..76455c25c 100644 --- a/src/common/mi-lttng.h +++ b/src/common/mi-lttng.h @@ -1,9 +1,8 @@ /* - * Copyright (C) 2014 Jonathan Rajotte - * Copyright (C) 2014 Olivier Cotte + * Copyright (C) 2014 EfficiOS Inc. * Copyright (C) 2016 Jérémie Galarneau * - * SPDX-License-Identifier: GPL-2.0-only + * SPDX-License-Identifier: LGPL-2.1-only * */ @@ -596,7 +595,7 @@ int mi_lttng_event_fields_open(struct mi_writer *writer); int mi_lttng_trackers_open(struct mi_writer *writer); /* - * Machine interface: open a id tracker element. + * Machine interface: open a process attribute tracker element. * * writer An instance of a machine interface writer. * @@ -605,8 +604,8 @@ int mi_lttng_trackers_open(struct mi_writer *writer); * * Note: A targets element is also opened for each tracker definition */ -int mi_lttng_id_tracker_open( - struct mi_writer *writer, enum lttng_tracker_type tracker_type); +int mi_lttng_process_attribute_tracker_open( + struct mi_writer *writer, enum lttng_process_attr process_attr); /* * Machine interface: open a PIDs element. @@ -664,28 +663,54 @@ int mi_lttng_process(struct mi_writer *writer, pid_t pid , const char *name, */ int mi_lttng_pid(struct mi_writer *writer, pid_t pid , const char *name, int is_open); + /* - * Machine interface: open a targets element. + * Machine interface: open a process attribute values element. * * writer An instance of a machine interface writer. * * Returns zero if the element's value could be written. * Negative values indicate an error. */ -int mi_lttng_targets_open(struct mi_writer *writer); +int mi_lttng_process_attr_values_open(struct mi_writer *writer); /* - * Machine interface for track/untrack an id_target + * Machine interface for track/untrack of all process attribute values. * * writer An instance of a machine interface writer. * * Returns zero if the element's value could be written. * Negative values indicate an error. */ -int mi_lttng_id_target(struct mi_writer *writer, - enum lttng_tracker_type tracker_type, - const struct lttng_tracker_id *id, - int is_open); +int mi_lttng_all_process_attribute_value(struct mi_writer *writer, + enum lttng_process_attr process_attr, + bool is_open); + +/* + * Machine interface for track/untrack of an integral process attribute value. + * + * writer An instance of a machine interface writer. + * + * Returns zero if the element's value could be written. + * Negative values indicate an error. + */ +int mi_lttng_integral_process_attribute_value(struct mi_writer *writer, + enum lttng_process_attr process_attr, + int64_t value, + bool is_open); + +/* + * Machine interface for track/untrack of a string process attribute value. + * + * writer An instance of a machine interface writer. + * + * Returns zero if the element's value could be written. + * Negative values indicate an error. + */ +int mi_lttng_string_process_attribute_value(struct mi_writer *writer, + enum lttng_process_attr process_attr, + const char *value, + bool is_open); /* * Machine interface of a context.