pub struct FulfillBuilder<'a, 'b> {
inner: Weak<Route>,
args: FulfillArgs<'a, 'b>,
}Fields§
§inner: Weak<Route>§args: FulfillArgs<'a, 'b>Implementations§
Source§impl<'a, 'b> FulfillBuilder<'a, 'b>
impl<'a, 'b> FulfillBuilder<'a, 'b>
pub(crate) fn new(inner: Weak<Impl>, body: &'a str, is_base64: bool) -> Self
pub async fn fulfill(self) -> Result<(), Arc<Error>>
Sourcepub fn headers<T>(self, x: T) -> Self
pub fn headers<T>(self, x: T) -> Self
Response headers. Header values will be converted to a string.
Sourcepub fn content_type(self, x: &'b str) -> Self
pub fn content_type(self, x: &'b str) -> Self
If set, equals to setting Content-Type response header.
pub fn clear_content_type(self) -> Self
pub fn clear_status(self) -> Self
pub fn clear_headers(self) -> Self
Auto Trait Implementations§
impl<'a, 'b> Freeze for FulfillBuilder<'a, 'b>
impl<'a, 'b> RefUnwindSafe for FulfillBuilder<'a, 'b>
impl<'a, 'b> Send for FulfillBuilder<'a, 'b>
impl<'a, 'b> Sync for FulfillBuilder<'a, 'b>
impl<'a, 'b> Unpin for FulfillBuilder<'a, 'b>
impl<'a, 'b> UnwindSafe for FulfillBuilder<'a, 'b>
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