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
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
def get_client_returned_record_f3(cself): try: with CPyString.fromPyOpt(CPyRecord.toPy(None, cself).misc) as py_obj: return py_obj.release_djinni_string() except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def on_changes_int_optional_returned(cself, i, f, s, binar, b, d): try: with CPyBoxedI32.fromPyOpt(FooListenerHelper.selfToPy(cself).on_changes_int_optional_returned(CPyBoxedI32.toPyOpt(i), CPyPrimitive.toPy(f), CPyString.toPyOpt(s), CPyBinary.toPy(binar), CPyPrimitive.toPy(b), CPyDate.toPy(d))) as py_obj: return py_obj.release_djinni_boxed() except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def on_string_change(self, private_string): with CPyString.fromPy(private_string) as pys_private_string: _ret_c = lib.cw__foo_listener_bf_on_string_change(self._cpp_impl, pys_private_string.release_djinni_string()) CPyException.toPyCheckAndRaise(_ret_c) _ret = CPyString.toPy(_ret_c) assert _ret is not None return _ret
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
def get_assorted_primitives_f9(cself): try: with CPyBoxedI8.fromPyOpt(CPyRecord.toPy(None, cself).o_eight) as py_obj: return py_obj.release_djinni_boxed() except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def id_binary(b): with CPyBinary.fromPy(b) as pybin_b: _ret_c = lib.cw__test_helpers_id_binary(pybin_b.release_djinni_binary()) CPyException.toPyCheckAndRaise(_ret_c) _ret = CPyBinary.toPy(_ret_c) assert _ret is not None return _ret
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
def update_static_messg_to(static_string): with CPyString.fromPy(static_string) as pys_static_string: _ret_c = lib.cw__foo_static_update_static_messg_to(pys_static_string.release_djinni_string()) CPyException.toPyCheckAndRaise(_ret_c) _ret = CPyString.toPy(_ret_c) assert _ret is not None return _ret
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
def __python_next(cself): try: with CPyString.fromPyOpt(next(CPyObjectProxy.toPyIter(cself))) as py_obj: return py_obj.release_djinni_string() except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
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
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
def __get_elem(cself, index): try: with CPyBinary.fromPyOpt(CPyObject.toPy(None, cself)[index]) as py_obj: return py_obj.release_djinni_binary() except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
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
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
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
def get_foo_client_returned_record_f3(cself): try: _ret = CPyRecord.fromPy(FooSomeOtherRecord.c_data_set, CPyRecord.toPy(None, cself).some_record) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def __python_next(cself): try: _ret= CPyEnum.fromPy(next(CPyObjectProxy.toPyIter(cself))) assert _ret.value != -1 return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def __get_elem(cself, index): try: _ret = CPyObjectProxy.fromPy(MapStringInt64THelper.c_data_set, MapStringInt64TProxy(CPyObject.toPy(None, cself)[index])) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f5(cself): try: _ret = CPyObject.fromPy(ListListStringHelper.c_data_set, CPyRecord.toPy(None, cself).list_list_string) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f6(cself): try: _ret = CPyObject.fromPy(ListRecordFooSomeOtherRecordHelper.c_data_set, CPyRecord.toPy(None, cself).list_record) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f16(cself): try: _ret = CPyObjectProxy.fromPy(MapBoxedInt32TSetStringHelper.c_data_set, MapBoxedInt32TSetStringProxy(CPyRecord.toPy(None, cself).map_optional_int_set_string)) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f4(cself): try: _ret = CPyObject.fromPy(ListOptionalBinaryHelper.c_data_set, CPyRecord.toPy(None, cself).list_optional_binary) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f14(cself): try: _ret = CPyObjectProxy.fromPy(SetOptionalStringHelper.c_data_set, SetOptionalStringProxy(CPyRecord.toPy(None, cself).set_optional_string)) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f11(cself): try: _ret = CPyObjectProxy.fromPy(MapInt8TListDateHelper.c_data_set, MapInt8TListDateProxy(CPyRecord.toPy(None, cself).map_int_list_date)) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def __get_elem(cself, index): try: _ret = CPyRecord.fromPy(FooSomeOtherRecord.c_data_set, CPyObject.toPy(None, cself)[index]) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_nested_collection_f1(cself): try: _ret = CPyObject.fromPy(ListSetStringHelper.c_data_set, CPyRecord.toPy(None, cself).set_list) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def on_changes_record_returned(cself, n1, n2): try: _ret = CPyRecord.fromPy(FooSomeOtherRecord.c_data_set, FooListenerHelper.selfToPy(cself).on_changes_record_returned(CPyPrimitive.toPy(n1), CPyPrimitive.toPy(n2))) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f16(cself): try: _ret = CPyObjectProxy.fromPy( MapBoxedInt32TSetStringHelper.c_data_set, MapBoxedInt32TSetStringProxy( CPyRecord.toPy(None, cself).map_optional_int_set_string)) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def __get_value(cself, key): pyKey = CPyBoxedI32.toPyOptWithoutTakingOwnership(key) try: _ret = CPyObjectProxy.fromPy( SetStringHelper.c_data_set, SetStringProxy(CPyObjectProxy.toPyObj(None, cself)[pyKey])) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def __get_value(cself, key): pyKey = CPyEnum.toPy(Color, key) assert pyKey is not None try: with CPyString.fromPy(CPyObjectProxy.toPyObj(None, cself)[pyKey]) as py_obj: _ret = py_obj.release_djinni_string() assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f11(cself): try: _ret = CPyObjectProxy.fromPy( MapInt8TListDateHelper.c_data_set, MapInt8TListDateProxy( CPyRecord.toPy(None, cself).map_int_list_date)) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_foo_containers_record_f14(cself): try: _ret = CPyObjectProxy.fromPy( SetOptionalStringHelper.c_data_set, SetOptionalStringProxy( CPyRecord.toPy(None, cself).set_optional_string)) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def meth_taking_interface(cself, i): try: with CPyString.fromPy( ClientInterfaceHelper.selfToPy( cself).meth_taking_interface( ClientInterfaceHelper.toPy(i))) as py_obj: _ret = py_obj.release_djinni_string() assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def __get_value(cself, key): pyKey = CPyPrimitive.toPy(key) assert pyKey is not None try: _ret = CPyObjectProxy.fromPy( SetStringHelper.c_data_set, SetStringProxy(CPyObjectProxy.toPyObj(None, cself)[pyKey])) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def get_record(cself, record_id, utf8string, misc): try: _ret = CPyRecord.fromPy( ClientReturnedRecord.c_data_set, ClientInterfaceHelper.selfToPy(cself).get_record( CPyPrimitive.toPy(record_id), CPyString.toPy(utf8string), CPyString.toPyOpt(misc))) assert _ret != ffi.NULL return _ret except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
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
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
def create(): _ret_c = lib.cw__foo_interface_create() CPyException.toPyCheckAndRaise(_ret_c) _ret = FooInterfaceHelper.toPy(_ret_c) assert _ret is not None return _ret
def set_bool(self, private_bool): lib.cw__foo_primitives_set_bool(self._cpp_impl, CPyPrimitive.fromPy(private_bool)) CPyException.toPyCheckAndRaise(ffi.NULL)
def get_my_record_f16(cself): try: return CPyEnum.fromPyOpt(CPyRecord.toPy(None, cself).test13) except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def set_binary(self, private_binary): with CPyBinary.fromPy(private_binary) as pybin_private_binary: lib.cw__foo_primitives_set_binary(self._cpp_impl, pybin_private_binary.release_djinni_binary()) CPyException.toPyCheckAndRaise(ffi.NULL)
def get_enum_usage_record_f2(cself): try: return CPyEnum.fromPyOpt(CPyRecord.toPy(None, cself).o) except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e) return ffi.NULL
def set_private_string(self, private_string): with CPyString.fromPy(private_string) as pys_private_string: lib.cw__foo_interface_set_private_string( self._cpp_impl, pys_private_string.release_djinni_string()) CPyException.toPyCheckAndRaise(ffi.NULL)
def create(): _ret_c = lib.cw__foo_primitives_create() CPyException.toPyCheckAndRaise(_ret_c) _ret = FooPrimitivesHelper.toPy(_ret_c) assert _ret is not None return _ret
def set_list_binary(self, lb): lib.cw__foo_containers_interface_set_list_binary( self._cpp_impl, CPyObject.fromPy(ListBinaryHelper.c_data_set, lb)) CPyException.toPyCheckAndRaise(ffi.NULL)
def set_containers_record(self, rec): lib.cw__foo_containers_interface_set_containers_record( self._cpp_impl, CPyRecord.fromPy(FooContainersRecord.c_data_set, rec)) CPyException.toPyCheckAndRaise(ffi.NULL)
def get_optional_list_int(self): _ret_c = lib.cw__foo_containers_interface_get_optional_list_int( self._cpp_impl) CPyException.toPyCheckAndRaise(_ret_c) _ret = CPyObject.toPyOpt(ListInt32THelper.c_data_set, _ret_c) return _ret
def set_list_record(self, lr): lib.cw__foo_containers_interface_set_list_record( self._cpp_impl, CPyObject.fromPy(ListRecordFooSomeOtherRecordHelper.c_data_set, lr)) CPyException.toPyCheckAndRaise(ffi.NULL)
def set_optional_list_int(self, m): lib.cw__foo_containers_interface_set_optional_list_int( self._cpp_impl, CPyObject.fromPyOpt(ListInt32THelper.c_data_set, m)) CPyException.toPyCheckAndRaise(ffi.NULL)
def set_optional_map_string_int(self, m): lib.cw__foo_containers_interface_set_optional_map_string_int( self._cpp_impl, CPyObjectProxy.fromPyOpt(MapStringInt32THelper.c_data_set, MapStringInt32TProxy(m))) CPyException.toPyCheckAndRaise(ffi.NULL)
def get_optional_containers_record(self): _ret_c = lib.cw__foo_containers_interface_get_optional_containers_record( self._cpp_impl) CPyException.toPyCheckAndRaise(_ret_c) _ret = CPyRecord.toPyOpt(FooContainersRecord.c_data_set, _ret_c) return _ret
def get_foo_primitives(self): _ret_c = lib.cw__foo_interface_get_foo_primitives(self._cpp_impl) CPyException.toPyCheckAndRaise(_ret_c) _ret = FooPrimitivesHelper.toPy(_ret_c) assert _ret is not None return _ret
def second(cself): try: SecondListenerHelper.selfToPy(cself).second() except Exception as _djinni_py_e: CPyException.setExceptionFromPy(_djinni_py_e)
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)
def set_date(self, private_date): lib.cw__foo_primitives_set_date(self._cpp_impl, CPyDate.fromPy(private_date)) CPyException.toPyCheckAndRaise(ffi.NULL)
def get_private_string(self): _ret_c = lib.cw__foo_interface_get_private_string(self._cpp_impl) CPyException.toPyCheckAndRaise(_ret_c) _ret = CPyString.toPy(_ret_c) assert _ret is not None return _ret
def get_date(self): _ret_c = lib.cw__foo_primitives_get_date(self._cpp_impl) CPyException.toPyCheckAndRaise(_ret_c) _ret = CPyDate.toPy(_ret_c) assert _ret is not None return _ret