Skip to main content

Context

Struct Context 

Source
pub struct Context<'a, 'd> { /* private fields */ }

Implementations§

Source§

impl<'a, 'd> Context<'a, 'd>

Source

pub fn reborrow(&mut self) -> Context<'_, 'd>

Source

pub fn region_token(&mut self) -> &mut Token<'d>

Source

pub fn driver_ref(&self) -> Reference<'d>

Source

pub fn timer(&self) -> &'d Timer<'d>

Source

pub fn deadline_now(&self) -> Deadline<'d>

Source

pub fn turn_now(&self) -> Instant

Trait Implementations§

Source§

impl<'d> Bootstrap<'d> for Context<'_, 'd>

Source§

fn bind_listener_slot( &mut self, addr: SocketAddr, backlog: i32, config: &ListenerConfig, ) -> Result<(Descriptor<'d>, SocketAddr)>

Source§

fn bind_datagram_slot( &mut self, addr: SocketAddr, ) -> Result<(DatagramDescriptor<'d>, SocketAddr)>

Source§

impl Buffers for Context<'_, '_>

Source§

impl<'d> Control<'d> for Context<'_, 'd>
where Uring: Socket,

Source§

fn reserve_route(&mut self, id: u8) -> bool

Source§

fn release_route(&mut self, id: u8)

Source§

fn submit_socket<Tag: Tag>( &mut self, flights: &Slots<'d, Tag>, request: Bound<'d, Tag, SocketSlot<'d>>, socket: StreamSpec, ) -> Result<CreatingSocket<'d>, SubmitError>

Source§

fn submit_tuning<Tag: Tag>( &mut self, request: Bound<'d, Tag, Descriptor<'d>>, options: StreamOptions, ) -> Result<Tuning<'d>, Descriptor<'d>>

Source§

fn cancel_tuning( &mut self, pending: TuningPending<'d>, ) -> Result<TuningPending<'d, Cancelled>, (TuningPending<'d>, SubmitError)>

Source§

fn cancel_connection( &mut self, pending: ConnectionPending<'d>, ) -> Result<ConnectionPending<'d, Cancelled>, (ConnectionPending<'d>, SubmitError)>

Source§

impl<'d> Files<'d> for Context<'_, 'd>

Source§

fn close(&mut self, fd: impl Into<Descriptor<'d>>)

Source§

fn reserve_outbound<const ID: u8>( &mut self, count: u32, ) -> Result<OutboundReservation<'d, ID>>

Source§

impl<'d> Poll<'d> for Context<'_, 'd>

Source§

fn commit(&mut self, work: Reactor<'_, 'd>) -> Result<Commit>

Source§

fn wait( &mut self, work: Reactor<'_, 'd>, timeout: Option<Duration>, ) -> Result<()>

Source§

impl<'d> Source<'d> for Context<'_, 'd>

Source§

impl<'d> Submit<'d> for Context<'_, 'd>
where Uring: Source,

Source§

fn cancel<Tag: Tag>( &mut self, flight: &mut Flight<'d>, target: Operation<'d, Tag>, ) -> Result<(), SubmitError>

Auto Trait Implementations§

§

impl<'a, 'd> !RefUnwindSafe for Context<'a, 'd>

§

impl<'a, 'd> !Send for Context<'a, 'd>

§

impl<'a, 'd> !Sync for Context<'a, 'd>

§

impl<'a, 'd> !UnwindSafe for Context<'a, 'd>

§

impl<'a, 'd> Freeze for Context<'a, 'd>

§

impl<'a, 'd> Unpin for Context<'a, 'd>

§

impl<'a, 'd> UnsafeUnpin for Context<'a, 'd>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.