pub struct MultiCacheBuilder { /* private fields */ }
Expand description
A builder for a MultiCache
.
Implementations§
Source§impl MultiCacheBuilder
impl MultiCacheBuilder
Sourcepub fn new() -> Self
pub fn new() -> Self
Creates a new MultiCacheBuilder
.
Sourcepub fn skip_memory(&mut self) -> &mut Self
pub fn skip_memory(&mut self) -> &mut Self
Skips caching results in memory.
With this flag enabled, all cache accesses must go through a cache provider even if key in question was accessed earlier by the same process.
Sourcepub fn with_provider(&mut self, client: Client) -> &mut Self
pub fn with_provider(&mut self, client: Client) -> &mut Self
Adds a new provider to the cache.
Sourcepub fn build(&mut self) -> MultiCache
pub fn build(&mut self) -> MultiCache
Builds a MultiCache
from the configured parameters.
Trait Implementations§
Source§impl Clone for MultiCacheBuilder
impl Clone for MultiCacheBuilder
Source§fn clone(&self) -> MultiCacheBuilder
fn clone(&self) -> MultiCacheBuilder
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for MultiCacheBuilder
impl Debug for MultiCacheBuilder
Source§impl Default for MultiCacheBuilder
impl Default for MultiCacheBuilder
Source§fn default() -> MultiCacheBuilder
fn default() -> MultiCacheBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for MultiCacheBuilder
impl !RefUnwindSafe for MultiCacheBuilder
impl Send for MultiCacheBuilder
impl Sync for MultiCacheBuilder
impl Unpin for MultiCacheBuilder
impl !UnwindSafe for MultiCacheBuilder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request