pub struct PreviewServiceConfig {
pub cache_capacity: usize,
pub cache_strategy: CacheStrategy,
pub default_fetcher: Option<Fetcher>,
pub twitter_fetcher: Option<Fetcher>,
pub github_fetcher: Option<Fetcher>,
pub max_concurrent_requests: usize,
}
Fields§
§cache_capacity: usize
§cache_strategy: CacheStrategy
§default_fetcher: Option<Fetcher>
§twitter_fetcher: Option<Fetcher>
§github_fetcher: Option<Fetcher>
§max_concurrent_requests: usize
Implementations§
Source§impl PreviewServiceConfig
impl PreviewServiceConfig
pub fn new(cache_capacity: usize, cache_strategy: CacheStrategy) -> Self
pub fn with_github_fetcher(self, fetcher: Fetcher) -> Self
pub fn with_default_fetcher(self, fetcher: Fetcher) -> Self
pub fn with_twitter_fetcher(self, fetcher: Fetcher) -> Self
Trait Implementations§
Source§impl Clone for PreviewServiceConfig
impl Clone for PreviewServiceConfig
Source§fn clone(&self) -> PreviewServiceConfig
fn clone(&self) -> PreviewServiceConfig
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 Default for PreviewServiceConfig
impl Default for PreviewServiceConfig
Source§fn default() -> PreviewServiceConfig
fn default() -> PreviewServiceConfig
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for PreviewServiceConfig
impl !RefUnwindSafe for PreviewServiceConfig
impl Send for PreviewServiceConfig
impl Sync for PreviewServiceConfig
impl Unpin for PreviewServiceConfig
impl !UnwindSafe for PreviewServiceConfig
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