20 explicit NetworkFacade(std::function<
void(
const T &)> recv_fct)
22 [
this](
auto &&message) { processMessage(std::forward<
decltype(message)>(message)); }),
23 recv_fct_(std::move(recv_fct)) {}
26 network_.
send({net_info.ip, net_info.port, solanet::serializer::serialize<T>(message)});
29 NetworkInfoIPv4 getNetworkInfo()
const {
return {network_.getIP(), network_.getPort()}; }
33 recv_fct_(solanet::serializer::deserialize<T>(msg.
getMessage()));
36 std::function<void(
const T &)> recv_fct_;