use crate::{errors::VetisError, Request, Response};
use std::{future::Future, pin::Pin, sync::Arc};
pub trait Path: Sync + Send {
fn uri(&self) -> &str;
fn handle(
&self,
request: Request,
uri: Arc<String>,
) -> Pin<Box<dyn Future<Output = Result<Response, VetisError>> + Send + Sync + '_>>;
}
#[typetag::serde]
pub trait PathConfig: Send + Sync {
fn uri(&mut self, value: &str);
}