pub struct FlushCtx(/* private fields */);
Expand description
A context that will be passed-in in a call to [ffi::flush
] and later
passed back in the done
callback when the async operation has completed.
Implementations§
Source§impl FlushCtx
impl FlushCtx
A context to be passed into flush
.
Intended to be called like:
let session: Pin<&mut PerfettoTracingSession> = todo!();
let (ctx, rx) = FlushCtx::new_sync();
let timeout_ms = 100;
session.flush(timeout_ms, Box::new(ctx), FlushCtx::callback);
let success: bool = rx.recv().unwrap();
Auto Trait Implementations§
impl Freeze for FlushCtx
impl RefUnwindSafe for FlushCtx
impl Send for FlushCtx
impl Sync for FlushCtx
impl Unpin for FlushCtx
impl UnwindSafe for FlushCtx
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