use crate::contracts::support::Responsable;
use crate::http::{Request, Response};
use std::future::Future;
pub trait Controller: Send + Sync + 'static {
fn index(&self, _req: Request) -> impl Future<Output = impl Responsable> + Send {
async { Response::not_implemented().text("501 Not Implemented: index") }
}
fn create(&self, _req: Request) -> impl Future<Output = impl Responsable> + Send {
async { Response::not_implemented().text("501 Not Implemented: create") }
}
fn store(&self, _req: Request) -> impl Future<Output = impl Responsable> + Send {
async { Response::not_implemented().text("501 Not Implemented: store") }
}
fn show(&self, _req: Request) -> impl Future<Output = impl Responsable> + Send {
async { Response::not_implemented().text("501 Not Implemented: show") }
}
fn edit(&self, _req: Request) -> impl Future<Output = impl Responsable> + Send {
async { Response::not_implemented().text("501 Not Implemented: edit") }
}
fn update(&self, _req: Request) -> impl Future<Output = impl Responsable> + Send {
async { Response::not_implemented().text("501 Not Implemented: update") }
}
fn destroy(&self, _req: Request) -> impl Future<Output = impl Responsable> + Send {
async { Response::not_implemented().text("501 Not Implemented: destroy") }
}
}