MCPcopy Create free account
hub / github.com/attermann/microReticulum / client_connected

Function client_connected

examples/link_native/src/main.cpp:72–77  ·  view source on GitHub ↗

When a client establishes a link to our server destination, this function will be called with a reference to the link.

Source from the content-addressed store, hash-verified

70// destination, this function will be called with
71// a reference to the link.
72void client_connected(RNS::Link& link) {
73 RNS::log("Client connected");
74 link.set_link_closed_callback(client_disconnected);
75 link.set_packet_callback(server_packet_received);
76 latest_client_link = link;
77}
78
79void server_loop(RNS::Destination& destination) {
80 // Let the user know that everything is ready

Callers

nothing calls this directly

Calls 3

logFunction · 0.85
set_packet_callbackMethod · 0.45

Tested by

no test coverage detected