pub type OnConnect = Arc<dyn Fn() + Send + Sync>;
Callback invoked when connected to the server
pub struct OnConnect { /* private fields */ }