mirror of https://github.com/rwf2/Rocket.git
Cleanup documentation related code.
This commit is contained in:
parent
e30e4e6c7f
commit
0144b70fac
|
@ -83,6 +83,7 @@ mod catcher;
|
|||
mod config;
|
||||
|
||||
/// Defines the types for request and error handlers.
|
||||
#[doc(hidden)]
|
||||
pub mod handler {
|
||||
use request::{Request, Data};
|
||||
use response::Response;
|
||||
|
@ -95,10 +96,10 @@ pub mod handler {
|
|||
pub type ErrorHandler = for<'r> fn(Error, &'r Request) -> Response<'r>;
|
||||
}
|
||||
|
||||
#[doc(inline)] pub use response::{Response, Responder};
|
||||
#[doc(inline)] pub use response::Response;
|
||||
#[doc(inline)] pub use handler::{Handler, ErrorHandler};
|
||||
#[doc(inline)] pub use logger::LoggingLevel;
|
||||
pub use codegen::{StaticRouteInfo, StaticCatchInfo};
|
||||
#[doc(hidden)] pub use codegen::{StaticRouteInfo, StaticCatchInfo};
|
||||
pub use router::Route;
|
||||
pub use request::{Request, Data};
|
||||
pub use error::Error;
|
||||
|
|
|
@ -27,6 +27,7 @@ pub struct Rocket {
|
|||
catchers: HashMap<u16, Catcher>,
|
||||
}
|
||||
|
||||
#[doc(hidden)]
|
||||
impl HyperHandler for Rocket {
|
||||
fn handle<'h, 'k>(&self,
|
||||
req: HyperRequest<'h, 'k>,
|
||||
|
@ -146,7 +147,7 @@ impl Rocket {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn mount(mut self, base: &'static str, routes: Vec<Route>) -> Self {
|
||||
pub fn mount(mut self, base: &str, routes: Vec<Route>) -> Self {
|
||||
info!("🛰 {} '{}':", Magenta.paint("Mounting"), base);
|
||||
for mut route in routes {
|
||||
let path = format!("{}/{}", base, route.path.as_str());
|
||||
|
|
Loading…
Reference in New Issue