2018-05-24 19:13:55 +02:00
|
|
|
extern crate actix;
|
|
|
|
extern crate actix_web;
|
|
|
|
extern crate futures;
|
|
|
|
extern crate openssl;
|
|
|
|
#[macro_use]
|
|
|
|
extern crate serde;
|
|
|
|
|
|
|
|
mod cfg;
|
|
|
|
mod dhandler;
|
|
|
|
mod minfo;
|
|
|
|
mod norm;
|
|
|
|
mod norm2;
|
|
|
|
mod path;
|
|
|
|
mod path2;
|
|
|
|
mod pbuf;
|
|
|
|
mod pred;
|
|
|
|
mod pred2;
|
|
|
|
mod resource;
|
|
|
|
mod scope;
|
2019-06-13 09:24:25 +02:00
|
|
|
mod scope;
|
2018-05-24 19:13:55 +02:00
|
|
|
mod url_ext;
|
|
|
|
mod urls;
|
|
|
|
|
|
|
|
// <main>
|
|
|
|
use actix_web::{http::Method, App, HttpRequest, HttpResponse};
|
|
|
|
|
|
|
|
fn index(req: HttpRequest) -> HttpResponse {
|
|
|
|
unimplemented!()
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
App::new()
|
|
|
|
.route("/user/{name}", Method::GET, index)
|
|
|
|
.route("/user/{name}", Method::POST, index)
|
|
|
|
.finish();
|
|
|
|
}
|
|
|
|
// </main>
|