pub struct Builder<B> { /* private fields */ }Implementations§
Source§impl<B> Builder<B>
impl<B> Builder<B>
pub fn status(self, status: StatusCode) -> Self
pub fn header(self, key: impl IntoUtf8Bytes, value: impl IntoUtf8Bytes) -> Self
Source§impl Builder<()>
impl Builder<()>
pub fn empty(self) -> Builder<Outgoing>
pub fn bytes(self, body: Bytes) -> Builder<Outgoing>
pub fn encoded<T: Encode>(self, body: &T) -> Result<Builder<Outgoing>>
pub fn html(self, body: impl IntoUtf8Bytes) -> Builder<Outgoing>
pub fn text(self, body: impl IntoUtf8Bytes) -> Builder<Outgoing>
pub fn body<B>(self, body: B) -> Builder<B>
Trait Implementations§
Auto Trait Implementations§
impl<B> Freeze for Builder<B>where
B: Freeze,
impl<B> RefUnwindSafe for Builder<B>where
B: RefUnwindSafe,
impl<B> Send for Builder<B>where
B: Send,
impl<B> Sync for Builder<B>where
B: Sync,
impl<B> Unpin for Builder<B>where
B: Unpin,
impl<B> UnsafeUnpin for Builder<B>where
B: UnsafeUnpin,
impl<B> UnwindSafe for Builder<B>where
B: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more