[][src]Struct linux_aio_tokio::GenericAioContextHandle

pub struct GenericAioContextHandle<M: RawMutex, A: IntrusiveAdapter<M, L>, L: DefaultLinkOps<Ops = A::LinkOps> + Default> where
    A::LinkOps: LinkedListOps + Default
{ /* fields omitted */ }

Cloneable handle to AIO context. Required for any AIO operations

Methods

impl<M: RawMutex, A: IntrusiveAdapter<M, L>, L: DefaultLinkOps<Ops = A::LinkOps> + Default> GenericAioContextHandle<M, A, L> where
    A::LinkOps: LinkedListOps + Default
[src]

pub fn available_slots(&self) -> Option<usize>[src]

Number of available AIO slots left in the context

Return None if AIO context stopped, or if use_semaphore was set to false

pub async fn submit_request<'_, '_, '_>(
    &'_ self,
    fd: &'_ impl AsRawFd,
    __arg2: RawCommand<'_>
) -> Result<u64, AioCommandError>
[src]

Submit command to the AIO context

If use_semaphore set to false, this function will return CapacityExceeded error if the user's code tries to exceed the allowed number of in-flight requests

Trait Implementations

impl<M: RawMutex, A: IntrusiveAdapter<M, L>, L: DefaultLinkOps<Ops = A::LinkOps> + Default> Clone for GenericAioContextHandle<M, A, L> where
    A::LinkOps: LinkedListOps + Default
[src]

impl<M: RawMutex, A: IntrusiveAdapter<M, L>, L: DefaultLinkOps<Ops = A::LinkOps> + Default> Debug for GenericAioContextHandle<M, A, L> where
    A::LinkOps: LinkedListOps + Default
[src]

Auto Trait Implementations

impl<M, A, L> !RefUnwindSafe for GenericAioContextHandle<M, A, L>

impl<M, A, L> Send for GenericAioContextHandle<M, A, L> where
    A: Send,
    L: Send,
    M: Send + Sync

impl<M, A, L> Sync for GenericAioContextHandle<M, A, L> where
    A: Send,
    L: Send,
    M: Send + Sync

impl<M, A, L> Unpin for GenericAioContextHandle<M, A, L>

impl<M, A, L> !UnwindSafe for GenericAioContextHandle<M, A, L>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.