send_bytes

Function send_bytes 

Source
pub fn send_bytes(
    payload: &[u8],
    stream: &mut GenericBlockingStream,
) -> Result<(), Error>
Expand description

Send a Vec of bytes. This is part of the basic protocol beneath all communication. \

  1. Sends a u64 as 4bytes in BigEndian mode, which tells the receiver the length of the payload.
  2. Send the payload in chunks of PACKET_SIZE bytes.