Struct PoolEndpoint

Source
pub struct PoolEndpoint<M: ManageConnection> { /* private fields */ }
Expand description

The endpoint which retrieves a connection from a connection pool.

Trait Implementations§

Source§

impl<M: Clone + ManageConnection> Clone for PoolEndpoint<M>

Source§

fn clone(&self) -> PoolEndpoint<M>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<M: Debug + ManageConnection> Debug for PoolEndpoint<M>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a, M> Endpoint<'a> for PoolEndpoint<M>
where M: ManageConnection + 'a,

Source§

type Output = (PooledConnection<M>,)

The inner type associated with this endpoint.
Source§

type Future = PoolFuture<'a, M>

The type of value which will be returned from apply.
Source§

fn apply(&'a self, _: &mut ApplyContext<'_>) -> ApplyResult<Self::Future>

Perform checking the incoming HTTP request and returns an instance of the associated Future if matched.
Source§

fn with_output<T>(self) -> Self
where T: Tuple, Self: Sized + Endpoint<'a, Output = T>,

Add an annotation that the associated type Output is fixed to T.
Source§

fn wrap<W>(self, wrapper: W) -> <W as Wrapper<'a, Self>>::Endpoint
where Self: Sized, W: Wrapper<'a, Self>,

Converts self using the provided Wrapper.

Auto Trait Implementations§

§

impl<M> Freeze for PoolEndpoint<M>

§

impl<M> !RefUnwindSafe for PoolEndpoint<M>

§

impl<M> Send for PoolEndpoint<M>

§

impl<M> Sync for PoolEndpoint<M>

§

impl<M> Unpin for PoolEndpoint<M>

§

impl<M> !UnwindSafe for PoolEndpoint<M>

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<'a, E> EndpointWrapExt<'a> for E
where E: Endpoint<'a>,

Source§

fn map<F>(self, f: F) -> <Map<Self::Output, F> as Wrapper<'a, Self>>::Endpoint
where F: Func<Self::Output> + 'a,

Source§

fn and_then<F>( self, f: F, ) -> <AndThen<Self::Output, F> as Wrapper<'a, Self>>::Endpoint
where F: Func<Self::Output> + 'a, <F as Func<Self::Output>>::Out: IntoFuture<Error = Error> + 'a,

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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<'a, E> IntoEndpoint<'a> for E
where E: Endpoint<'a>,

Source§

type Output = <E as Endpoint<'a>>::Output

The inner type of associated Endpoint.
Source§

type Endpoint = E

The type of transformed Endpoint.
Source§

fn into_endpoint(self) -> <E as IntoEndpoint<'a>>::Endpoint

Consume itself and transform into an Endpoint.
Source§

impl<'a, E> IntoEndpointExt<'a> for E
where E: IntoEndpoint<'a>,

Source§

fn and<E>( self, other: E, ) -> And<Self::Endpoint, <E as IntoEndpoint<'a>>::Endpoint>
where E: IntoEndpoint<'a>, Self::Output: Combine<<E as IntoEndpoint<'a>>::Output>,

Create an endpoint which evaluates self and e and returns a pair of their tasks. Read more
Source§

fn or<E>( self, other: E, ) -> Or<Self::Endpoint, <E as IntoEndpoint<'a>>::Endpoint>
where E: IntoEndpoint<'a>,

Create an endpoint which evaluates self and e sequentially. Read more
Source§

fn or_strict<E>( self, other: E, ) -> OrStrict<Self::Endpoint, <E as IntoEndpoint<'a>>::Endpoint>
where E: IntoEndpoint<'a, Output = Self::Output>,

Create an endpoint which evaluates self and e sequentially. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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.