//! HTTP client traits.
//!//! This module defines the traits that HTTP client implementations must implement.
#[cfg(not(feature ="blocking"))]useasync_trait::async_trait;usesuper::{Request, Response};usecrate::error::Result;/// Trait for async HTTP clients.
#[cfg(not(feature ="blocking"))]#[async_trait]pubtraitHttpClient: Send + Sync {/// Sends an HTTP request and returns the response.
////// # Errors
////// Returns an error if the request fails.
async fnsend(&self, request: Request)->Result<Response>;}/// Trait for blocking HTTP clients.
#[cfg(feature ="blocking")]#[cfg_attr(docsrs,doc(cfg(feature ="blocking")))]pubtraitBlockingHttpClient: Send + Sync {/// Sends an HTTP request and returns the response.
////// # Errors
////// Returns an error if the request fails.
fnsend(&self, request: Request)->Result<Response>;}