rclrs

Trait ServiceBase

Source
pub trait ServiceBase: Send + Sync {
    // Required methods
    fn handle(&self) -> &ServiceHandle;
    fn execute(&self) -> Result<(), RclrsError>;
}
Expand description

Trait to be implemented by concrete Service structs.

See Service<T> for an example

Required Methods§

Source

fn handle(&self) -> &ServiceHandle

Internal function to get a reference to the rcl handle.

Source

fn execute(&self) -> Result<(), RclrsError>

Tries to take a new request and run the callback with it.

Implementors§

Source§

impl<T> ServiceBase for Service<T>
where T: Service,