Struct ntex_redis::RedisConnector[][src]

pub struct RedisConnector<A, T> { /* fields omitted */ }

Redis connector

Implementations

impl<A> RedisConnector<A, ()> where
    A: Address + Clone
[src]

pub fn new(address: A) -> RedisConnector<A, Connector<A>>[src]

Create new redis connector

impl<A, T> RedisConnector<A, T> where
    A: Address + Clone,
    T: Service<Request = Connect<A>, Error = ConnectError>,
    T::Response: AsyncRead + AsyncWrite + Unpin + 'static, 
[src]

pub fn password<U>(self, password: U) -> Self where
    U: AsRef<str>, 
[src]

Add redis auth password

pub fn connector<U>(self, connector: U) -> RedisConnector<A, U> where
    U: Service<Request = Connect<A>, Error = ConnectError>,
    U::Response: AsyncRead + AsyncWrite + Unpin + 'static, 
[src]

Use custom connector

pub fn connect(&self) -> impl Future<Output = Result<Client, ConnectError>>[src]

Connect to redis server

pub fn connect_simple(
    &self
) -> impl Future<Output = Result<SimpleClient<T::Response>, ConnectError>>
[src]

Connect to redis server and create simple client

Auto Trait Implementations

impl<A, T> RefUnwindSafe for RedisConnector<A, T> where
    A: RefUnwindSafe,
    T: RefUnwindSafe

impl<A, T> Send for RedisConnector<A, T> where
    A: Send,
    T: Send

impl<A, T> Sync for RedisConnector<A, T> where
    A: Sync,
    T: Sync

impl<A, T> Unpin for RedisConnector<A, T> where
    A: Unpin,
    T: Unpin

impl<A, T> UnwindSafe for RedisConnector<A, T> where
    A: UnwindSafe,
    T: UnwindSafe

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> Instrument for T[src]

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

impl<T> Same<T> for T

type Output = T

Should always be Self

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.