pub struct RawServiceClient<const REQ_BUF: usize = { crate::config::DEFAULT_RX_BUF_SIZE }, const REPLY_BUF: usize = { crate::config::DEFAULT_RX_BUF_SIZE }> { /* private fields */ }Expand description
Typeless service-client handle. L1 counterpart of
EmbeddedServiceClient for the same audience as
RawServiceServer.
Implementations§
Source§impl<const REQ_BUF: usize, const REPLY_BUF: usize> RawServiceClient<REQ_BUF, REPLY_BUF>
impl<const REQ_BUF: usize, const REPLY_BUF: usize> RawServiceClient<REQ_BUF, REPLY_BUF>
Sourcepub fn register_waker(&self, waker: &Waker)
pub fn register_waker(&self, waker: &Waker)
Phase 122.3.c.6.e — register a Waker that fires when the
reply to a previously-sent request lands.
Sourcepub fn new(handle: RmwServiceClient) -> Self
pub fn new(handle: RmwServiceClient) -> Self
Construct from a backend-allocated handle. Same audience as
RawServiceServer::new.
Sourcepub fn send_request_raw(&mut self, request: &[u8]) -> Result<(), NodeError>
pub fn send_request_raw(&mut self, request: &[u8]) -> Result<(), NodeError>
Send a raw CDR request. Non-blocking; the reply arrives via
try_recv_reply_raw.
Sourcepub fn server_available(&self) -> Result<bool, NodeError>
pub fn server_available(&self) -> Result<bool, NodeError>
Phase 124.G.3 — graph-aware “is the matching server up?”
probe. Mirrors [Client::server_available] for the raw API.
Sourcepub fn try_recv_reply_raw(&mut self) -> Result<Option<usize>, NodeError>
pub fn try_recv_reply_raw(&mut self) -> Result<Option<usize>, NodeError>
Try to receive a reply (non-blocking). Returns
Ok(Some(len)) with the reply length on success; bytes
live in reply_buffer until the next
call.
Sourcepub fn reply_buffer(&self) -> &[u8] ⓘ
pub fn reply_buffer(&self) -> &[u8] ⓘ
Borrow the inline reply buffer. Valid after a successful
try_recv_reply_raw call.
Auto Trait Implementations§
impl<const REQ_BUF: usize, const REPLY_BUF: usize> Freeze for RawServiceClient<REQ_BUF, REPLY_BUF>
impl<const REQ_BUF: usize, const REPLY_BUF: usize> RefUnwindSafe for RawServiceClient<REQ_BUF, REPLY_BUF>
impl<const REQ_BUF: usize = { crate::config::DEFAULT_RX_BUF_SIZE }, const REPLY_BUF: usize = { crate::config::DEFAULT_RX_BUF_SIZE }> !Send for RawServiceClient<REQ_BUF, REPLY_BUF>
impl<const REQ_BUF: usize = { crate::config::DEFAULT_RX_BUF_SIZE }, const REPLY_BUF: usize = { crate::config::DEFAULT_RX_BUF_SIZE }> !Sync for RawServiceClient<REQ_BUF, REPLY_BUF>
impl<const REQ_BUF: usize, const REPLY_BUF: usize> Unpin for RawServiceClient<REQ_BUF, REPLY_BUF>
impl<const REQ_BUF: usize, const REPLY_BUF: usize> UnsafeUnpin for RawServiceClient<REQ_BUF, REPLY_BUF>
impl<const REQ_BUF: usize, const REPLY_BUF: usize> UnwindSafe for RawServiceClient<REQ_BUF, REPLY_BUF>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more