pub struct SyncBridge<S> { /* private fields */ }Expand description
Adapts a detached async store to the synchronous Reader/Writer
traits by blocking on a tokio runtime handle.
§Contract
Operations must be called from a thread that is NOT a tokio runtime
worker (Handle::block_on panics inside a runtime context). The
intended callers are dedicated blocking threads — spawn_blocking
closures, or plain OS threads — which is exactly where synchronous
block code runs.
Implementations§
Source§impl<S: DetachedStore> SyncBridge<S>
impl<S: DetachedStore> SyncBridge<S>
Sourcepub fn into_inner(self) -> S
pub fn into_inner(self) -> S
Unwrap, returning the inner store.
Trait Implementations§
Source§impl<S: DetachedStore + Sync> Reader for SyncBridge<S>
impl<S: DetachedStore + Sync> Reader for SyncBridge<S>
Auto Trait Implementations§
impl<S> Freeze for SyncBridge<S>where
S: Freeze,
impl<S> RefUnwindSafe for SyncBridge<S>where
S: RefUnwindSafe,
impl<S> Send for SyncBridge<S>where
S: Send,
impl<S> Sync for SyncBridge<S>where
S: Sync,
impl<S> Unpin for SyncBridge<S>where
S: Unpin,
impl<S> UnsafeUnpin for SyncBridge<S>where
S: UnsafeUnpin,
impl<S> UnwindSafe for SyncBridge<S>where
S: UnwindSafe,
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