pub struct AsyncifyFd<S, F, D> { /* private fields */ }Expand description
Spawn a blocking function with a file descriptor in the thread pool.
Implementations§
Source§impl<S, F, D> AsyncifyFd<S, F, D>
impl<S, F, D> AsyncifyFd<S, F, D>
Sourcepub fn new(fd: SharedFd<S>, f: F) -> Self
pub fn new(fd: SharedFd<S>, f: F) -> Self
Create AsyncifyFd.
Trait Implementations§
Source§impl<S, F, D> IntoInner for AsyncifyFd<S, F, D>
impl<S, F, D> IntoInner for AsyncifyFd<S, F, D>
Source§impl<S, D: Send + 'static, F: FnOnce(&S) -> BufResult<usize, D> + Send + 'static> OpCode for AsyncifyFd<S, F, D>
impl<S, D: Send + 'static, F: FnOnce(&S) -> BufResult<usize, D> + Send + 'static> OpCode for AsyncifyFd<S, F, D>
Source§fn pre_submit(self: Pin<&mut Self>) -> Result<Decision>
fn pre_submit(self: Pin<&mut Self>) -> Result<Decision>
Perform the operation before submit, and return
Decision to
indicate whether submitting the operation to polling is required.Auto Trait Implementations§
impl<S, F, D> Freeze for AsyncifyFd<S, F, D>
impl<S, F, D> RefUnwindSafe for AsyncifyFd<S, F, D>where
F: RefUnwindSafe,
D: RefUnwindSafe,
impl<S, F, D> Send for AsyncifyFd<S, F, D>
impl<S, F, D> Sync for AsyncifyFd<S, F, D>
impl<S, F, D> !Unpin for AsyncifyFd<S, F, D>
impl<S, F, D> UnwindSafe for AsyncifyFd<S, F, D>where
F: UnwindSafe,
D: 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