+ def get_field(self, field):
+ """
+ Return the definition of fields by a name
+ Return None on error
+ """
+ eventScope = self.get_top_level_scope(ctf.scope.EVENT_FIELDS)
+ streamScope = self.get_top_level_scope(ctf.scope.STREAM_EVENT_CONTEXT)
+ fields_by_name = []
+
+ if eventScope is not None:
+ evDef = self.get_field_with_scope(eventScope, field)
+ if evDef is not None:
+ fields_by_name.append(evDef)
+
+ if streamScope is not None:
+ evDef = self.get_field_with_scope(streamScope, field)
+ if evDef is not None:
+ fields_by_name.append(evDef);
+
+ if not fields_by_name:
+ return None
+ return fields_by_name
+
+ def get_field_list_with_scope(self, scope):