pub type WriteFn<Connection> = dyn Fn(&Connection, &[u8]) -> CommsResult<()> + Send + Sync + 'static;
Type definition for a “write” function pointer.