[−][src]Function kompact::prelude::ser_helpers::serialise_msg
pub fn serialise_msg<B: ?Sized>(
src: &ActorPath,
dst: &ActorPath,
msg: &B,
buf: &mut BufferEncoder
) -> Result<ChunkLease, SerError> where
B: Serialisable,
Serialises the provided actor paths and message
It allocates a new BytesMut according to the message's size hint. The message's serialised data is then stored in this buffer.
Format
The serialized format is:
source ActorPath
path_type u8
path [u8; 16]
if unique path, else a length-prefixed UTF-8 encoded string
destination ActorPath
(see above for specific format)
ser_id u64
message raw bytes