Struct rocket::response::content::JavaScript [−][src]
pub struct JavaScript<R>(pub R);
Expand description
Override the Content-Type
of the response to
JavaScript
, or
application/javascript
.
Delegates the remainder of the response to the wrapped responder.
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Sets the Content-Type of the response then delegates the remainder of the response to the wrapped responder.
Returns Ok
if a Response
could be generated successfully. Otherwise,
returns an Err
with a failing Status
. Read more
Auto Trait Implementations
impl<R> RefUnwindSafe for JavaScript<R> where
R: RefUnwindSafe,
impl<R> Send for JavaScript<R> where
R: Send,
impl<R> Sync for JavaScript<R> where
R: Sync,
impl<R> Unpin for JavaScript<R> where
R: Unpin,
impl<R> UnwindSafe for JavaScript<R> where
R: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
Converts self
into a collection.
type Output = T
type Output = T
Should always be Self
pub fn vzip(self) -> V