MCPcopy Create free account
hub / github.com/buttplugio/buttplug / max_ping_time

Method max_ping_time

crates/buttplug_server/src/server_builder.rs:83–86  ·  view source on GitHub ↗

Set the maximum ping time, in milliseconds, for the server. If the server does not receive a [Ping](buttplug_core::messages::Ping) message in this amount of time after the handshake has succeeded, the server will automatically disconnect. If this is not called, the ping timer will not be activated. Note that this has nothing to do with communication medium specific pings, like those built into th

(&mut self, ping_time: u32)

Source from the content-addressed store, hash-verified

81 /// Note that this has nothing to do with communication medium specific pings, like those built
82 /// into the Websocket protocol. This ping is specific to the Buttplug protocol.
83 pub fn max_ping_time(&mut self, ping_time: u32) -> &mut Self {
84 self.max_ping_time = Some(ping_time);
85 self
86 }
87
88 /// Try to build a [ButtplugServer] using the parameters given.
89 pub fn finish(&self) -> Result<ButtplugServer, ButtplugServerError> {

Callers 5

test_client_pingFunction · 0.45
test_ping_timeoutFunction · 0.45
fromMethod · 0.45
fromMethod · 0.45

Calls

no outgoing calls

Tested by 3

test_client_pingFunction · 0.36
test_ping_timeoutFunction · 0.36