Make API CTF-agnostic
[babeltrace.git] / include / babeltrace / lib-logging-internal.h
index 376be0bc88535e0495eb7832246c627cde17686d..e2483b29d9a472980c748526d43360dafcafa974 100644 (file)
 #include <babeltrace/babeltrace-internal.h>
 #include <stdarg.h>
 
+#ifndef BT_LOG_TAG
+# error Please define a tag with BT_LOG_TAG before including this file.
+#endif
+
 #define BT_LOG_OUTPUT_LEVEL bt_lib_log_level
 
 #include <babeltrace/logging-internal.h>
@@ -58,7 +62,7 @@ int bt_lib_log_level;
  *   `PRIi64`.
  *
  * The Babeltrace extension conversion specifier is accepted. Its syntax
- * is:
+ * is either `%!u` to format a UUID (`bt_uuid` type) or:
  *
  * 1. Introductory `%!` sequence.
  *
@@ -70,18 +74,10 @@ int bt_lib_log_level;
  * 3. Optional: `+` to print extended fields. This depends on the
  *    provided format specifier.
  *
- * 4. Objet category: `w` for CTF writer objects, `_` for common
- *    objects, or nothing for default objects (includes CTF IR).
- *
- * 5. Format specifier (see below).
+ * 4. Format specifier (see below).
  *
  * The available format specifiers are:
  *
- * Default category:
- *   `r`:
- *       Reference count information. The parameter is any Babeltrace
- *       object.
- *
  *   `F`:
  *       CTF IR field type. The parameter type is `struct bt_field_type *`.
  *
@@ -140,73 +136,27 @@ int bt_lib_log_level;
  *   `g`:
  *       Graph. The parameter type is `struct bt_graph *`.
  *
- *   `u`:
+ *   `l`:
  *       Plugin. The parameter type is `struct bt_plugin *`.
  *
- * CTF writer category:
- *   `F`:
- *       CTF writer field type. The parameter type is `struct bt_field_type *`.
- *
- *   `f`:
- *       CTF writer field. The parameter type is `struct bt_field *`.
- *
- *   `E`:
- *       CTF writer event class. The parameter type is
- *       `struct bt_event_class *`.
- *
- *   `e`:
- *       CTF writer event. The parameter type is `struct bt_event *`.
- *
- *   `S`:
- *       CTF writer stream class. The parameter type is
- *       `struct bt_stream_class *`.
- *
- *   `s`:
- *       CTF writer stream. The parameter type is `struct bt_stream *`.
- *
- *   `t`:
- *       CTF writer trace. The parameter type is `struct bt_trace *`.
- *
- *   `w`:
- *       CTF writer. The parameter type is `struct bt_ctf_writer *`.
- *
- * Common category:
- *   `F`:
- *       Common field type. The parameter type is `struct bt_field_type *`.
- *
- *   `f`:
- *       Common field. The parameter type is `struct bt_field *`.
- *
- *   `E`:
- *       Common event class. The parameter type is
- *       `struct bt_event_class *`.
+ *   `o`:
+ *       Object pool. The parameter type is `struct bt_object_pool *`.
  *
- *   `e`:
- *       Common event. The parameter type is `struct bt_event *`.
- *
- *   `S`:
- *       Common stream class. The parameter type is
- *       `struct bt_stream_class *`.
- *
- *   `s`:
- *       Common stream. The parameter type is `struct bt_stream *`.
- *
- *   `t`:
- *       Common trace. The parameter type is `struct bt_trace *`.
+ *   `O`:
+ *       Object. The parameter type is `struct bt_object *`.
  *
  * Conversion specifier examples:
  *
  *     %!f
  *     %![my-event-]+e
- *     %!_t
- *     %![ctf-writer-ec-]wE
- *     %!+_F
+ *     %!t
+ *     %!+F
  *
  * The string `, ` is printed between individual fields, but not after
  * the last one. Therefore you must put this separator in the format
  * string between two Babeltrace objects, e.g.:
  *
- *     BT_LIB_LOGW("Message: count=%u, %!E, %!+C", count, event_class,
+ *     BT_LIB_LOGW("Message: count=%u, %!E, %!+K", count, event_class,
  *                 clock_class);
  *
  * Example with a custom prefix:
This page took 0.026317 seconds and 4 git commands to generate.