pub struct Fetcher { /* private fields */ }Expand description
HTTP fetcher for metadata
Implementations§
Source§impl Fetcher
impl Fetcher
Sourcepub async fn fetch_json<T: DeserializeOwned>(&self, url: &str) -> Result<T>
pub async fn fetch_json<T: DeserializeOwned>(&self, url: &str) -> Result<T>
Fetch JSON from a URL with proper error handling
Sourcepub async fn fetch_functions(
&self,
url: &str,
extension: String,
) -> Result<Vec<Function>>
pub async fn fetch_functions( &self, url: &str, extension: String, ) -> Result<Vec<Function>>
Fetch functions from URL, parsing each item individually so one bad entry doesn’t block the rest.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Fetcher
impl !RefUnwindSafe for Fetcher
impl Send for Fetcher
impl Sync for Fetcher
impl Unpin for Fetcher
impl UnsafeUnpin for Fetcher
impl !UnwindSafe for Fetcher
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