python: Add stream event context support
authorSimon Marchi <simon.marchi@polymtl.ca>
Sun, 19 Jun 2016 02:54:51 +0000 (22:54 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Mon, 25 Jul 2016 21:36:55 +0000 (17:36 -0400)
This patch adds the possibility to get/set the event context type of a
stream class and set the stream context value of an event from Python.

From my experience, the value setter (Event.stream_context.setter) is
not so useful, since it looks like the context is already instanciated
when you create the event.  So in order to set the values in it, you
only need to get the existing instance and set its fields.  There is no
need to to re-assign the stream context instance to the event.  I still
put it there for completeness.

I added an example of the usage to the existing CTF writer Python
example.

Signed-off-by: Simon Marchi <simon.marchi@polymtl.ca>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>

No differences found
This page took 0.026451 seconds and 4 git commands to generate.