pub struct BridgeCallRegistry { /* private fields */ }Expand description
Bounded call-specific response registry shared by all sessions.
A response is settled directly into the target registered for its globally unique call ID. It never enters the ordinary session command/event channel.
Implementations§
Source§impl BridgeCallRegistry
impl BridgeCallRegistry
pub fn new(max_pending: usize) -> Self
pub fn with_default_limit() -> Self
pub fn register_sync( &self, runtime: &RuntimeContext, request_bytes: usize, max_response_bytes: usize, call_id: u64, session_id: &str, session_generation: Option<u64>, ) -> Result<Receiver<BridgeResponse>, String>
pub fn register_async( &self, runtime: &RuntimeContext, request_bytes: usize, max_response_bytes: usize, call_id: u64, session_id: &str, session_generation: Option<u64>, sender: Sender<BridgeResponse>, ) -> Result<(), String>
pub fn settle( &self, supplied_session_id: &str, supplied_generation: Option<u64>, response: BridgeResponse, ) -> Result<(), String>
pub fn cancel(&self, call_id: u64)
pub fn cancel_session(&self, session_id: &str, session_generation: Option<u64>)
pub fn clear(&self)
Auto Trait Implementations§
impl !Freeze for BridgeCallRegistry
impl RefUnwindSafe for BridgeCallRegistry
impl Send for BridgeCallRegistry
impl Sync for BridgeCallRegistry
impl Unpin for BridgeCallRegistry
impl UnsafeUnpin for BridgeCallRegistry
impl UnwindSafe for BridgeCallRegistry
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