Function chrome_native_messaging::event_loop [] [src]

pub fn event_loop<F, E>(callback: F) where
    F: Fn(Value) -> StdResult<(), E>,
    E: StdError

Starts an 'event loop' which waits for input from Chrome, and then calls the callback with the message. Despite its name, nothing about this function is asynchronous so if you want really efficient performance while running async tasks, you should probably write your own loop.