Skip to main content

ActionServerCoreFfi

Trait ActionServerCoreFfi 

Source
pub trait ActionServerCoreFfi: Sealed + Sized {
Show 25 methods // Required methods fn from_channels( send_goal_server: RmwServiceServer, cancel_goal_server: RmwServiceServer, get_result_server: RmwServiceServer, feedback_publisher: RmwPublisher, status_publisher: RmwPublisher, ) -> Self; fn try_recv_goal_request( &mut self, ) -> Result<Option<RawGoalRequest>, NodeError>; fn goal_buffer(&self) -> &[u8] ⓘ; fn accept_goal( &mut self, goal_id: GoalUuid, seq: i64, ) -> Result<(), NodeError>; fn reject_goal(&mut self, seq: i64) -> Result<(), NodeError>; fn publish_feedback_raw( &mut self, goal_id: &GoalUuid, feedback_cdr: &[u8], ) -> Result<(), NodeError>; fn set_goal_status(&mut self, goal_id: &GoalUuid, status: GoalStatusCode); fn expire_completed_results(&mut self) -> usize; fn completed_result_count(&self) -> usize; fn result_slab_used(&self) -> usize; fn goal_exists(&self, goal_id: &GoalUuid) -> bool; fn has_completed_result(&self, goal_id: &GoalUuid) -> bool; fn complete_goal_raw( &mut self, goal_id: &GoalUuid, status: GoalStatusCode, result_cdr: &[u8], ) -> Result<(), NodeError>; fn register_goal_waker(&self, waker: &Waker) -> bool; fn register_cancel_waker(&self, waker: &Waker) -> bool; fn register_get_result_waker(&self, waker: &Waker) -> bool; fn try_recv_cancel_request( &mut self, ) -> Result<Option<PendingCancelRequest>, NodeError>; fn send_cancel_reply( &mut self, sequence_number: i64, return_code: CancelResponseCode, accepted: &[GoalUuid], ) -> Result<(), NodeError>; fn try_handle_cancel( &mut self, cancel_handler: impl FnMut(&GoalUuid, GoalStatusCode) -> CancelResponse, ) -> Result<Option<(GoalUuid, CancelResponse)>, NodeError>; fn try_handle_get_result_raw( &mut self, default_result_cdr: &[u8], ) -> Result<Option<GoalUuid>, NodeError>; fn active_goal_count(&self) -> usize; fn active_goals(&self) -> &[RawActiveGoal]; fn goal_stamp(&self, goal_id: &GoalUuid) -> Time; fn find_goal_status(&self, goal_id: &GoalUuid) -> GoalStatusCode; fn publish_status_array(&self) -> Result<(), NodeError>;
}
Expand description

ActionServerCore’s methods, for nros-c, nros-cpp and the nros runtime. Sealed.

Required Methods§

Source

fn from_channels( send_goal_server: RmwServiceServer, cancel_goal_server: RmwServiceServer, get_result_server: RmwServiceServer, feedback_publisher: RmwPublisher, status_publisher: RmwPublisher, ) -> Self

The FFI entry point; see ActionServerCore::from_channels in action_core.rs.

Source

fn try_recv_goal_request(&mut self) -> Result<Option<RawGoalRequest>, NodeError>

The FFI entry point; see ActionServerCore::try_recv_goal_request in action_core.rs.

Source

fn goal_buffer(&self) -> &[u8] ⓘ

The FFI entry point; see ActionServerCore::goal_buffer in action_core.rs.

Source

fn accept_goal(&mut self, goal_id: GoalUuid, seq: i64) -> Result<(), NodeError>

The FFI entry point; see ActionServerCore::accept_goal in action_core.rs.

Source

fn reject_goal(&mut self, seq: i64) -> Result<(), NodeError>

The FFI entry point; see ActionServerCore::reject_goal in action_core.rs.

Source

fn publish_feedback_raw( &mut self, goal_id: &GoalUuid, feedback_cdr: &[u8], ) -> Result<(), NodeError>

The FFI entry point; see ActionServerCore::publish_feedback_raw in action_core.rs.

Source

fn set_goal_status(&mut self, goal_id: &GoalUuid, status: GoalStatusCode)

The FFI entry point; see ActionServerCore::set_goal_status in action_core.rs.

Source

fn expire_completed_results(&mut self) -> usize

The FFI entry point; see ActionServerCore::expire_completed_results in action_core.rs.

Source

fn completed_result_count(&self) -> usize

The FFI entry point; see ActionServerCore::completed_result_count in action_core.rs.

Source

fn result_slab_used(&self) -> usize

The FFI entry point; see ActionServerCore::result_slab_used in action_core.rs.

Source

fn goal_exists(&self, goal_id: &GoalUuid) -> bool

The FFI entry point; see ActionServerCore::goal_exists in action_core.rs.

Source

fn has_completed_result(&self, goal_id: &GoalUuid) -> bool

The FFI entry point; see ActionServerCore::has_completed_result in action_core.rs.

Source

fn complete_goal_raw( &mut self, goal_id: &GoalUuid, status: GoalStatusCode, result_cdr: &[u8], ) -> Result<(), NodeError>

The FFI entry point; see ActionServerCore::complete_goal_raw in action_core.rs.

Source

fn register_goal_waker(&self, waker: &Waker) -> bool

The FFI entry point; see ActionServerCore::register_goal_waker in action_core.rs.

Source

fn register_cancel_waker(&self, waker: &Waker) -> bool

The FFI entry point; see ActionServerCore::register_cancel_waker in action_core.rs.

Source

fn register_get_result_waker(&self, waker: &Waker) -> bool

The FFI entry point; see ActionServerCore::register_get_result_waker in action_core.rs.

Source

fn try_recv_cancel_request( &mut self, ) -> Result<Option<PendingCancelRequest>, NodeError>

The FFI entry point; see ActionServerCore::try_recv_cancel_request in action_core.rs.

Source

fn send_cancel_reply( &mut self, sequence_number: i64, return_code: CancelResponseCode, accepted: &[GoalUuid], ) -> Result<(), NodeError>

The FFI entry point; see ActionServerCore::send_cancel_reply in action_core.rs.

Source

fn try_handle_cancel( &mut self, cancel_handler: impl FnMut(&GoalUuid, GoalStatusCode) -> CancelResponse, ) -> Result<Option<(GoalUuid, CancelResponse)>, NodeError>

The FFI entry point; see ActionServerCore::try_handle_cancel in action_core.rs.

Source

fn try_handle_get_result_raw( &mut self, default_result_cdr: &[u8], ) -> Result<Option<GoalUuid>, NodeError>

The FFI entry point; see ActionServerCore::try_handle_get_result_raw in action_core.rs.

Source

fn active_goal_count(&self) -> usize

The FFI entry point; see ActionServerCore::active_goal_count in action_core.rs.

Source

fn active_goals(&self) -> &[RawActiveGoal]

The FFI entry point; see ActionServerCore::active_goals in action_core.rs.

Source

fn goal_stamp(&self, goal_id: &GoalUuid) -> Time

The FFI entry point; see ActionServerCore::goal_stamp in action_core.rs.

Source

fn find_goal_status(&self, goal_id: &GoalUuid) -> GoalStatusCode

The FFI entry point; see ActionServerCore::find_goal_status in action_core.rs.

Source

fn publish_status_array(&self) -> Result<(), NodeError>

The FFI entry point; see ActionServerCore::publish_status_array in action_core.rs.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<const GOAL_BUF: usize, const RESULT_BUF: usize, const FEEDBACK_BUF: usize, const MAX_GOALS: usize> ActionServerCoreFfi for ActionServerCore<GOAL_BUF, RESULT_BUF, FEEDBACK_BUF, MAX_GOALS>