MCPcopy Create free account
hub / github.com/NetSys/bess / MODULE_INIT_FUNC

Function MODULE_INIT_FUNC

core/module.h:91–99  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89
90template <typename T, typename M>
91static inline module_init_func_t MODULE_INIT_FUNC(
92 CommandResponse (M::*fn)(const T &)) {
93 return [fn](Module *m, const google::protobuf::Any &arg) {
94 T arg_;
95 arg.UnpackTo(&arg_);
96 auto base_fn = std::mem_fn(fn);
97 return base_fn(static_cast<M *>(m), arg_);
98 };
99}
100
101class Module;
102

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected