コード例 #1
0
 def get_record_with_derivings_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).key1)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #2
0
 def get_some_const_record_f2(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).number2)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #3
0
 def get_constant_record_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).some_integer)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #4
0
 def get_assorted_primitives_f7(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).fsixtyfour)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #5
0
ファイル: dh__set_int32_t.py プロジェクト: trafi/djinni
 def __python_next(cself):
     try:
         _ret = CPyPrimitive.fromPy(next(CPyObjectProxy.toPyIter(cself)))
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #6
0
 def get_foo_client_returned_record_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).record_id)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #7
0
ファイル: dh__set_bool.py プロジェクト: a4z/djinni-generator
 def __python_next(cself):
     try:
         _ret = CPyPrimitive.fromPy(next(CPyObjectProxy.toPyIter(cself)))
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #8
0
ファイル: foo_listener.py プロジェクト: trafi/djinni
 def on_changes_int_returned(cself, i, f, s, binar, b, d):
     try:
         _ret = CPyPrimitive.fromPy(FooListenerHelper.selfToPy(cself).on_changes_int_returned(CPyPrimitive.toPy(i), CPyPrimitive.toPy(f), CPyString.toPy(s), CPyBinary.toPy(binar), CPyPrimitive.toPy(b), CPyDate.toPy(d)))
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #9
0
 def get_foo_client_returned_record_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).record_id)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #10
0
ファイル: foo_listener.py プロジェクト: trafi/djinni
 def get_private_int(cself):
     try:
         _ret = CPyPrimitive.fromPy(FooListenerHelper.selfToPy(cself).get_private_int())
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #11
0
 def __get_elem(cself, index):
     try:
         _ret = CPyPrimitive.fromPy(CPyObject.toPy(None, cself)[index])
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #12
0
 def get_foo_extensible_record_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).number1)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #13
0
 def get_my_record_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).test)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #14
0
 def get_all_datatypes_f7(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).float64Data)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #15
0
 def get_some_const_record_f2(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).number2)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #16
0
ファイル: foo_constants_helper.py プロジェクト: trafi/djinni
 def get_foo_constants_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).some_integer)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #17
0
 def get_record_with_nested_derivings_f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself).key)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #18
0
ファイル: dh__list_int32_t.py プロジェクト: trafi/djinni
 def __get_elem(cself, index):
     try:
         _ret = CPyPrimitive.fromPy(CPyObject.toPy(None, cself)[index])
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #19
0
 def get__varname_record__f1(cself):
     try:
         _ret = CPyPrimitive.fromPy(CPyRecord.toPy(None, cself)._field_)
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #20
0
ファイル: foo_receiver.py プロジェクト: trafi/djinni
 def cause_changes_int_returned(self, i, f, s, binar, b, d):
     with CPyString.fromPy(s) as pys_s,\
             CPyBinary.fromPy(binar) as pybin_binar:
         _ret_c = lib.cw__foo_receiver_cause_changes_int_returned(self._cpp_impl, CPyPrimitive.fromPy(i), CPyPrimitive.fromPy(f), pys_s.release_djinni_string(), pybin_binar.release_djinni_binary(), CPyPrimitive.fromPy(b), CPyDate.fromPy(d))
         CPyException.toPyCheckAndRaise(_ret_c)
         _ret = CPyPrimitive.toPy(_ret_c)
         assert _ret is not None
         return _ret
コード例 #21
0
 def __get_value(cself, key):
     pyKey = CPyString.toPyWithoutTakingOwnership(key)
     assert pyKey is not None
     try:
         _ret = CPyPrimitive.fromPy(CPyObjectProxy.toPyObj(None, cself)[pyKey])
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #22
0
 def __get_value(cself, key):
     pyKey = CPyString.toPyWithoutTakingOwnership(key)
     assert pyKey is not None
     try:
         _ret = CPyPrimitive.fromPy(CPyObjectProxy.toPyObj(None, cself)[pyKey])
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #23
0
 def identifier_check(cself, data, r, jret):
     try:
         _ret = CPyPrimitive.fromPy(
             ClientInterfaceHelper.selfToPy(cself).identifier_check(
                 CPyBinary.toPy(data), CPyPrimitive.toPy(r),
                 CPyPrimitive.toPy(jret)))
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #24
0
 def __get_value(cself, key):
     pyKey = CPyEnum.toPy(MyEnum, key)
     assert pyKey is not None
     try:
         _ret = CPyPrimitive.fromPy(
             CPyObjectProxy.toPyObj(None, cself)[pyKey])
         return _ret
     except Exception as _djinni_py_e:
         CPyException.setExceptionFromPy(_djinni_py_e)
         return ffi.NULL
コード例 #25
0
ファイル: foo_static.py プロジェクト: trafi/djinni
 def update_static_counter_to(init):
     _ret_c = lib.cw__foo_static_update_static_counter_to(CPyPrimitive.fromPy(init))
     CPyException.toPyCheckAndRaise(_ret_c)
     _ret = CPyPrimitive.toPy(_ret_c)
     assert _ret is not None
     return _ret
コード例 #26
0
 def set_bool(self, private_bool):
     lib.cw__foo_primitives_set_bool(self._cpp_impl, CPyPrimitive.fromPy(private_bool))
     CPyException.toPyCheckAndRaise(ffi.NULL)
コード例 #27
0
ファイル: foo_interface.py プロジェクト: trafi/djinni
 def set_private_int32(self, private_int):
     lib.cw__foo_interface_set_private_int32(self._cpp_impl, CPyPrimitive.fromPy(private_int))
     CPyException.toPyCheckAndRaise(ffi.NULL)
コード例 #28
0
 def method_returning_nothing(self, value):
     lib.cw__my_cpp_interface_method_returning_nothing(
         self._cpp_impl, CPyPrimitive.fromPy(value))
     CPyException.toPyCheckAndRaise(ffi.NULL)
コード例 #29
0
ファイル: foo_receiver.py プロジェクト: trafi/djinni
 def cause_changes_record_returned(self, n1, n2):
     _ret_c = lib.cw__foo_receiver_cause_changes_record_returned(self._cpp_impl, CPyPrimitive.fromPy(n1), CPyPrimitive.fromPy(n2))
     CPyException.toPyCheckAndRaise(_ret_c)
     _ret = CPyRecord.toPy(FooSomeOtherRecord.c_data_set, _ret_c)
     assert _ret is not None
     return _ret
コード例 #30
0
ファイル: foo_receiver.py プロジェクト: trafi/djinni
 def cause_changes_int_optional_returned(self, i, f, s, binar, b, d):
     with CPyBoxedI32.fromPyOpt(i) as pyopt_i,\
             CPyString.fromPyOpt(s) as pyopt_s,\
             CPyBinary.fromPy(binar) as pybin_binar:
         _ret_c = lib.cw__foo_receiver_cause_changes_int_optional_returned(self._cpp_impl, pyopt_i.release_djinni_boxed(), CPyPrimitive.fromPy(f), pyopt_s.release_djinni_string(), pybin_binar.release_djinni_binary(), CPyPrimitive.fromPy(b), CPyDate.fromPy(d))
         CPyException.toPyCheckAndRaise(_ret_c)
         _ret = CPyBoxedI32.toPyOpt(_ret_c)
         return _ret
コード例 #31
0
 def set_private_int32(self, private_int):
     lib.cw__foo_interface_set_private_int32(
         self._cpp_impl, CPyPrimitive.fromPy(private_int))
     CPyException.toPyCheckAndRaise(ffi.NULL)
コード例 #32
0
ファイル: foo_interface.py プロジェクト: trafi/djinni
 def int32_inverse(self, x):
     _ret_c = lib.cw__foo_interface_int32_inverse(self._cpp_impl, CPyPrimitive.fromPy(x))
     CPyException.toPyCheckAndRaise(_ret_c)
     _ret = CPyPrimitive.toPy(_ret_c)
     assert _ret is not None
     return _ret