Remove bt_ctf_stream_class_get_event_class_by_name()
[babeltrace.git] / lib / ctf-ir / stream-class.c
index f9d91aaf651323fbe40611285b90b6896bd9ddc3..97b6e6593ab964b06e381eb1a3e21c03fa34d3e1 100644 (file)
@@ -284,16 +284,6 @@ void event_class_exists(gpointer element, gpointer query)
                goto end;
        }
 
-       /*
-        * Two event classes cannot share the same name in a given
-        * stream class.
-        */
-       if (!strcmp(bt_ctf_event_class_get_name(event_class_a),
-                       bt_ctf_event_class_get_name(event_class_b))) {
-               search_query->found = 1;
-               goto end;
-       }
-
        /*
         * Two event classes cannot share the same ID in a given
         * stream class.
@@ -520,32 +510,6 @@ end:
        return event_class;
 }
 
-struct bt_ctf_event_class *bt_ctf_stream_class_get_event_class_by_name(
-               struct bt_ctf_stream_class *stream_class, const char *name)
-{
-       size_t i;
-       struct bt_ctf_event_class *event_class = NULL;
-
-       if (!stream_class || !name) {
-               goto end;
-       }
-
-       for (i = 0; i < stream_class->event_classes->len; i++) {
-               struct bt_ctf_event_class *cur_event_class =
-                       g_ptr_array_index(stream_class->event_classes, i);
-               const char *cur_event_class_name =
-                       bt_ctf_event_class_get_name(cur_event_class);
-
-               if (!strcmp(name, cur_event_class_name)) {
-                       event_class = cur_event_class;
-                       bt_get(event_class);
-                       goto end;
-               }
-       }
-end:
-       return event_class;
-}
-
 struct bt_ctf_event_class *bt_ctf_stream_class_get_event_class_by_id(
                struct bt_ctf_stream_class *stream_class, uint64_t id)
 {
This page took 0.025632 seconds and 4 git commands to generate.