MCPcopy Create free account
hub / github.com/Tencent/TAD_Sim / serve

Method serve

simcore/framework/src/api/python/txsim_module.py:56–70  ·  view source on GitHub ↗
(self, name, module, address='')

Source from the content-addressed store, hash-verified

54 os._exit(1)
55
56 def serve(self, name, module, address=''):
57 err_p = c_void_p(0)
58 self.impl = self.func_impl_new(
59 _sim_init, _sim_reset, _sim_step, _sim_stop, 0, pointer(err_p))
60 if err_p:
61 print(_cstr2pystr(self.func_err_msg(err_p)))
62 self.func_err_del(err_p)
63 os._exit(2)
64 self.func_serve(self.impl, py_object(module), _pystr2cstr(
65 name), _pystr2cstr(address), pointer(err_p))
66 if err_p:
67 print(_cstr2pystr(self.func_err_msg(err_p)))
68 self.func_err_del(err_p)
69 os._exit(3)
70 self.func_impl_del(self.impl)
71
72 def shutdown(self):
73 self.func_shutdown(self.impl)

Callers 1

my_module.pyFile · 0.80

Calls 2

_cstr2pystrFunction · 0.85
_pystr2cstrFunction · 0.85

Tested by

no test coverage detected