Skip to main content

CffiSubscriber

Struct CffiSubscriber 

Source
pub struct CffiSubscriber { /* private fields */ }
Expand description

Subscriber backed by a C vtable.

Implementations§

Source§

impl CffiSubscriber

Source

pub fn topic_name(&self) -> &str

Source

pub fn type_name(&self) -> &str

Source

pub fn qos(&self) -> NrosRmwQos

Source

pub fn can_loan_messages(&self) -> bool

true iff the backend exposes the receive loan primitive (Phase 99).

Trait Implementations§

Source§

impl Drop for CffiSubscriber

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

impl Subscriber for CffiSubscriber

Source§

type Error = TransportError

Error type for receive operations
Source§

fn supports_process_in_place(&self) -> bool

Whether this backend implements the in-place dispatch methods (process_raw_in_place / process_raw_in_place_with_info) with a real zero-copy borrow. Read more
Source§

fn process_raw_in_place( &mut self, f: impl FnOnce(&[u8]), ) -> Result<bool, Self::Error>

Process the received message in-place without copying. Read more
Source§

fn has_data(&self) -> bool

Check if data is available without consuming it. Read more
Source§

fn try_recv_raw( &mut self, buf: &mut [u8], ) -> Result<Option<usize>, TransportError>

Try to receive one message into buf. Read more
Source§

fn try_recv_raw_with_info( &mut self, buf: &mut [u8], ) -> Result<Option<(usize, Option<MessageInfo>)>, TransportError>

Try to receive raw data along with publisher metadata. Read more
Source§

fn try_recv_sequence( &mut self, buf: &mut [u8], per_msg_cap: usize, max_msgs: usize, out_lens: &mut [usize], ) -> Result<usize, TransportError>

Phase 124.D.1 — burst-take. Read more
Source§

fn deserialization_error(&self) -> TransportError

Return a deserialization error (implementation specific)
Source§

fn unsupported_event_error(&self) -> TransportError

Phase 108 — backend’s error variant for “this event kind is not supported.” Default reuses deserialization_error() for backends that don’t have a distinct Unsupported mapping.
Source§

unsafe fn register_event_callback( &mut self, kind: EventKind, deadline_ms: u32, cb: EventCallback, user_ctx: *mut c_void, ) -> Result<(), TransportError>

Phase 108 — register a callback fired when the named status event occurs. deadline_ms applies to EventKind::RequestedDeadlineMissed only; ignored otherwise. Default impl returns the backend’s “unsupported”-shaped error. Read more
Source§

fn try_recv_raw_with_attachment( &mut self, buf: &mut [u8], _att_buf: &mut [u8], ) -> Result<Option<(usize, usize)>, Self::Error>

Phase 128.F.4 — receive with attachment bytes alongside the payload. Read more
Source§

fn try_recv<M>(&mut self, buf: &mut [u8]) -> Result<Option<M>, Self::Error>
where M: RosMessage,

Try to receive a typed message (non-blocking)
Source§

fn process_raw_in_place_with_info( &mut self, f: impl FnOnce(&[u8], Option<MessageInfo>), ) -> Result<bool, Self::Error>
where Self::Error: From<TransportError>,

In-place processing variant that also surfaces publisher metadata. Read more
Source§

fn register_waker(&self, _waker: &Waker)

Register an async waker to be notified when data arrives. Read more
Source§

fn supports_event(&self, _kind: EventKind) -> bool

Phase 108 — true if the backend can generate this event for this subscriber. Default returns false; backends override per supported event kind. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.