pub struct Reply<'c, 'a, K> { /* private fields */ }Expand description
A response with its body read, keyed by the form’s field enum K for the queries over its
form.
The queries are those of the free functions this crate exports, over the response’s HTML.
Implementations§
Source§impl<'c, 'a, K: PartialEq> Reply<'c, 'a, K>
impl<'c, 'a, K: PartialEq> Reply<'c, 'a, K>
pub fn status(&self) -> StatusCode
The (name, value) pairs the response’s Set-Cookie headers carry.
Sourcepub fn notification(&self) -> Option<Notification>
pub fn notification(&self) -> Option<Notification>
The flash notification the response set for the next page.
pub fn html(&self) -> &str
Sourcepub async fn follow(&self) -> Reply<'c, 'a, K>where
K: Clone,
pub async fn follow(&self) -> Reply<'c, 'a, K>where
K: Clone,
Follows the redirect, carrying the cookies the response set, as a browser does.
§Panics
When the response names no Location.
Sourcepub fn empty_table(&self) -> Option<EmptyTable>
pub fn empty_table(&self) -> Option<EmptyTable>
See empty_table.
Sourcepub fn stale(&self) -> bool
pub fn stale(&self) -> bool
Whether the edit form refused the save as stale; see stale_form.
Sourcepub fn field_error(&self, field: K) -> Option<ErrorKind>
pub fn field_error(&self, field: K) -> Option<ErrorKind>
Why field’s error slot renders, read under its first key; see
field_error.
Sourcepub fn field_error_message(&self, field: K) -> Option<String>
pub fn field_error_message(&self, field: K) -> Option<String>
The message field’s error slot renders; see
field_error_message.
Sourcepub fn input_value(&self, field: K) -> Option<String>
pub fn input_value(&self, field: K) -> Option<String>
The value field’s input renders, as an edit page fills it; see
input_value.
Auto Trait Implementations§
impl<'c, 'a, K> !RefUnwindSafe for Reply<'c, 'a, K>
impl<'c, 'a, K> !UnwindSafe for Reply<'c, 'a, K>
impl<'c, 'a, K> Freeze for Reply<'c, 'a, K>
impl<'c, 'a, K> Send for Reply<'c, 'a, K>
impl<'c, 'a, K> Sync for Reply<'c, 'a, K>
impl<'c, 'a, K> Unpin for Reply<'c, 'a, K>
impl<'c, 'a, K> UnsafeUnpin for Reply<'c, 'a, K>
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