pub struct HttpRecordResolver { /* private fields */ }Expand description
Resolver that fetches records using public XRPC endpoints.
Uses an identity resolver to dynamically determine the PDS endpoint for each record.
Implementations§
Source§impl HttpRecordResolver
impl HttpRecordResolver
Sourcepub fn new(
http_client: Client,
identity_resolver: Arc<dyn IdentityResolver>,
) -> Self
pub fn new( http_client: Client, identity_resolver: Arc<dyn IdentityResolver>, ) -> Self
Create a new resolver using the provided HTTP client and identity resolver.
The identity resolver is used to dynamically determine the PDS endpoint for each record based on the authority (DID or handle) in the AT URI.
Trait Implementations§
Source§impl Clone for HttpRecordResolver
impl Clone for HttpRecordResolver
Source§fn clone(&self) -> HttpRecordResolver
fn clone(&self) -> HttpRecordResolver
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 moreSource§impl RecordResolver for HttpRecordResolver
impl RecordResolver for HttpRecordResolver
Source§fn resolve<'life0, 'life1, 'async_trait, T>(
&'life0 self,
aturi: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<T>> + Send + 'async_trait>>where
T: DeserializeOwned + Send + 'async_trait,
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn resolve<'life0, 'life1, 'async_trait, T>(
&'life0 self,
aturi: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<T>> + Send + 'async_trait>>where
T: DeserializeOwned + Send + 'async_trait,
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Resolve an AT URI to a typed record.
Auto Trait Implementations§
impl Freeze for HttpRecordResolver
impl !RefUnwindSafe for HttpRecordResolver
impl Send for HttpRecordResolver
impl Sync for HttpRecordResolver
impl Unpin for HttpRecordResolver
impl UnsafeUnpin for HttpRecordResolver
impl !UnwindSafe for HttpRecordResolver
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