pub struct LiveUpdateProxyDB<T>(/* private fields */);Available on crate feature
live-update only.Expand description
A wrapper around a T ProxyDB which can be updated
through the only linked writer LiveUpdateProxyDBSetter.
See proxy_db_updater for more details.
Trait Implementations§
Source§impl<T> Clone for LiveUpdateProxyDB<T>
impl<T> Clone for LiveUpdateProxyDB<T>
Source§impl<T: Debug> Debug for LiveUpdateProxyDB<T>
impl<T: Debug> Debug for LiveUpdateProxyDB<T>
Source§impl<T> ProxyDB for LiveUpdateProxyDB<T>
impl<T> ProxyDB for LiveUpdateProxyDB<T>
Source§type Error = Box<dyn Error + Sync + Send>
type Error = Box<dyn Error + Sync + Send>
The error type that can be returned by the proxy database Read more
Source§async fn get_proxies_if(
&self,
ctx: ProxyContext,
filter: ProxyFilter,
predicate: impl ProxyQueryPredicate,
limit: Option<NonZeroUsize>,
) -> Result<NonEmptyVec<Proxy>, Self::Error>
async fn get_proxies_if( &self, ctx: ProxyContext, filter: ProxyFilter, predicate: impl ProxyQueryPredicate, limit: Option<NonZeroUsize>, ) -> Result<NonEmptyVec<Proxy>, Self::Error>
Return matching
Proxy values in database-defined preference order,
after applying an additional predicate and optional result limit.Source§async fn get_proxies(
&self,
ctx: ProxyContext,
filter: ProxyFilter,
limit: Option<NonZeroUsize>,
) -> Result<NonEmptyVec<Proxy>, Self::Error>
async fn get_proxies( &self, ctx: ProxyContext, filter: ProxyFilter, limit: Option<NonZeroUsize>, ) -> Result<NonEmptyVec<Proxy>, Self::Error>
Return matching
Proxy values in database-defined preference order,
up to the optional result limit.Source§async fn get_proxy_if(
&self,
ctx: ProxyContext,
filter: ProxyFilter,
predicate: impl ProxyQueryPredicate,
) -> Result<Proxy, Self::Error>
async fn get_proxy_if( &self, ctx: ProxyContext, filter: ProxyFilter, predicate: impl ProxyQueryPredicate, ) -> Result<Proxy, Self::Error>
Return one matching proxy after applying an additional predicate. Read more
Source§async fn get_proxy(
&self,
ctx: ProxyContext,
filter: ProxyFilter,
) -> Result<Proxy, Self::Error>
async fn get_proxy( &self, ctx: ProxyContext, filter: ProxyFilter, ) -> Result<Proxy, Self::Error>
Get a
Proxy based on the given ProxyContext and ProxyFilter,
or return an error in case no Proxy could be returned.Auto Trait Implementations§
impl<T> Freeze for LiveUpdateProxyDB<T>
impl<T> RefUnwindSafe for LiveUpdateProxyDB<T>where
T: RefUnwindSafe,
impl<T> Send for LiveUpdateProxyDB<T>
impl<T> Sync for LiveUpdateProxyDB<T>
impl<T> Unpin for LiveUpdateProxyDB<T>
impl<T> UnsafeUnpin for LiveUpdateProxyDB<T>
impl<T> UnwindSafe for LiveUpdateProxyDB<T>where
T: RefUnwindSafe,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
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