1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
use thruster_app::app::App;
use thruster_core::context::Context;
use thruster_core::request::RequestWithParams;

pub trait ThrusterServer {
  type Context: Context + Send;
  type Response: Send;
  type Request: RequestWithParams + Send;

  fn new(_: App<Self::Request, Self::Context>) -> Self;
  fn start(self, host: &str, port: u16);
}