Struct rocket::response::status::Custom [−][src]
pub struct Custom<R>(pub Status, pub R);
Expand description
Creates a response with the given status code and underlying responder.
Example
use rocket::response::status;
use rocket::http::Status;
let response = status::Custom(Status::ImATeapot, "Hi!");
Tuple Fields
0: Status
1: R
Trait Implementations
Sets the status code of the response and then delegates the remainder of the response to the wrapped responder.
Auto Trait Implementations
impl<R> RefUnwindSafe for Custom<R> where
R: RefUnwindSafe,
impl<R> UnwindSafe for Custom<R> where
R: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more