Function caesar_core::receiver::client::start
source · pub async fn start(filepath: String, socket: Socket, fragment: &str)Expand description
Starts the receiver’s client.
This function takes in a file path, a socket, and a fragment string. It then extracts the room ID and HMAC from the fragment string. The function also generates an ephemeral secret key.
The function initializes a Context struct with the extracted information
and sets up the necessary communication channels. It then sends a join
request to the server and starts handling incoming messages.
§Arguments
filepath- The path to the file to be received.socket- The WebSocket connection to the server.fragment- The invite code containing the room ID and HMAC.