Trait licensebat_rust::retriever::docs_rs::Retriever
source · pub trait Retriever: Send + Sync + Debug {
type Response: Future<Output = RetrievedDependency> + Send;
fn get_dependency(&self, dependency: Dependency) -> Self::Response;
}Expand description
Trait used by the DocsRs struct to retrieve dependencies.
Required Associated Types§
sourcetype Response: Future<Output = RetrievedDependency> + Send
type Response: Future<Output = RetrievedDependency> + Send
Future that resolves to a RetrievedDependency.
It cannot fail.
Required Methods§
sourcefn get_dependency(&self, dependency: Dependency) -> Self::Response
fn get_dependency(&self, dependency: Dependency) -> Self::Response
Validates dependency’s information from the original source.