ServiceMainFn

Type Alias ServiceMainFn 

Source
pub type ServiceMainFn<T> = fn(rx: Receiver<ServiceEvent<T>>, tx: Sender<ServiceEvent<T>>, args: Vec<String>, standalone_mode: bool) -> u32;
Expand description

Signature of the service main function. rx receives the events that are sent to the service. tx can be used to send custom events on the channel. args is the list or arguments that were passed to the service. When standalone_mode is true, the service main function is being called directly (outside of the system service support).