pub struct RealCatalogFetcher { /* private fields */ }Expand description
Production implementation of CatalogHttpClient that fetches from the network.
Implementations§
Source§impl RealCatalogFetcher
impl RealCatalogFetcher
Sourcepub fn with_fetcher(fetcher: Arc<dyn HttpFetcher>) -> Self
pub fn with_fetcher(fetcher: Arc<dyn HttpFetcher>) -> Self
Build a catalog fetcher backed by the given HTTP capability.
Sourcepub fn with_http_fetcher<F>(fetcher: F) -> Selfwhere
F: HttpFetcher + 'static,
pub fn with_http_fetcher<F>(fetcher: F) -> Selfwhere
F: HttpFetcher + 'static,
Build a catalog fetcher from any type that implements [HttpFetcher].
Trait Implementations§
Source§impl CatalogHttpClient for RealCatalogFetcher
impl CatalogHttpClient for RealCatalogFetcher
Source§fn fetch_api_catalog(
&self,
ttl_seconds: u64,
) -> Result<(ApiCatalog, Vec<CacheWarning>), CacheError>
fn fetch_api_catalog( &self, ttl_seconds: u64, ) -> Result<(ApiCatalog, Vec<CacheWarning>), CacheError>
Fetch the API catalog JSON and parse it.
Source§impl Clone for RealCatalogFetcher
impl Clone for RealCatalogFetcher
Source§fn clone(&self) -> RealCatalogFetcher
fn clone(&self) -> RealCatalogFetcher
Returns a duplicate 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 moreAuto Trait Implementations§
impl Freeze for RealCatalogFetcher
impl !RefUnwindSafe for RealCatalogFetcher
impl Send for RealCatalogFetcher
impl Sync for RealCatalogFetcher
impl Unpin for RealCatalogFetcher
impl UnsafeUnpin for RealCatalogFetcher
impl !UnwindSafe for RealCatalogFetcher
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,
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