projects
/
babeltrace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
python: make all _get_ref/_put_ref proper static methods
[babeltrace.git]
/
src
/
bindings
/
python
/
bt2
/
bt2
/
stream_class.py
diff --git
a/src/bindings/python/bt2/bt2/stream_class.py
b/src/bindings/python/bt2/bt2/stream_class.py
index 885ba746dae01ae37b9db9ae5a0873453fe58804..c189a6eb32cf9e6864ecc582b78039a303b83161 100644
(file)
--- a/
src/bindings/python/bt2/bt2/stream_class.py
+++ b/
src/bindings/python/bt2/bt2/stream_class.py
@@
-17,8
+17,14
@@
def _bt2_trace_class():
class _StreamClassConst(object._SharedObject, collections.abc.Mapping):
class _StreamClassConst(object._SharedObject, collections.abc.Mapping):
- _get_ref = staticmethod(native_bt.stream_class_get_ref)
- _put_ref = staticmethod(native_bt.stream_class_put_ref)
+ @staticmethod
+ def _get_ref(ptr):
+ native_bt.stream_class_get_ref(ptr)
+
+ @staticmethod
+ def _put_ref(ptr):
+ native_bt.stream_class_put_ref(ptr)
+
_borrow_event_class_ptr_by_id = staticmethod(
native_bt.stream_class_borrow_event_class_by_id_const
)
_borrow_event_class_ptr_by_id = staticmethod(
native_bt.stream_class_borrow_event_class_by_id_const
)
@@
-165,8
+171,14
@@
class _StreamClassConst(object._SharedObject, collections.abc.Mapping):
class _StreamClass(_StreamClassConst):
class _StreamClass(_StreamClassConst):
- _get_ref = staticmethod(native_bt.stream_class_get_ref)
- _put_ref = staticmethod(native_bt.stream_class_put_ref)
+ @staticmethod
+ def _get_ref(ptr):
+ native_bt.stream_class_get_ref(ptr)
+
+ @staticmethod
+ def _put_ref(ptr):
+ native_bt.stream_class_put_ref(ptr)
+
_borrow_event_class_ptr_by_id = staticmethod(
native_bt.stream_class_borrow_event_class_by_id
)
_borrow_event_class_ptr_by_id = staticmethod(
native_bt.stream_class_borrow_event_class_by_id
)
This page took
0.025283 seconds
and
4
git commands to generate.