Skip to main content

serialize_daemon_to_client_message

Function serialize_daemon_to_client_message 

pub fn serialize_daemon_to_client_message(
    msg: &DaemonToClientMessage,
) -> Vec<u8> 
Expand description

Serialize a DaemonToClientMessage into its tagged-envelope wire representation.

The first byte of the returned vector is the tag identifying the variant; the remaining bytes (if any) are the variant’s payload.

§Arguments

  • msg - The message to serialize.

§Returns

A vector containing the framed wire bytes ready to be written to the daemon’s named pipe.