MCPcopy Create free account
hub / github.com/clockworklabs/SpacetimeDB / encode_message

Method encode_message

sdks/rust/src/websocket.rs:389–391  ·  view source on GitHub ↗
(msg: ws::v2::ClientMessage)

Source from the content-addressed store, hash-verified

387 }
388
389 pub(crate) fn encode_message(msg: ws::v2::ClientMessage) -> WebSocketMessage {
390 WebSocketMessage::Binary(bsatn::to_vec(&msg).unwrap().into())
391 }
392
393 #[cfg(not(feature = "browser"))]
394 async fn message_loop(

Callers

nothing calls this directly

Calls 2

to_vecFunction · 0.85
unwrapMethod · 0.45

Tested by

no test coverage detected