#[non_exhaustive]pub struct RespondPayload {
pub file_path: Option<String>,
pub text: Option<String>,
pub json: Option<String>,
pub status: Option<u16>,
pub delay_milliseconds: Option<u32>,
}Expand description
Payload for UpdateRespond.
file_path / text / json are mutually specialised (RFC 065):
exactly one should be populated. Validation catches cases that
violate this.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.file_path: Option<String>§text: Option<String>§json: Option<String>The response body, declared as JSON (RFC 065) — served as
application/json rather than text’s text/plain. Mutually
exclusive with file_path and text.
status: Option<u16>§delay_milliseconds: Option<u32>Trait Implementations§
Source§impl Clone for RespondPayload
impl Clone for RespondPayload
Source§fn clone(&self) -> RespondPayload
fn clone(&self) -> RespondPayload
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RespondPayload
impl Debug for RespondPayload
Source§impl Default for RespondPayload
impl Default for RespondPayload
Source§fn default() -> RespondPayload
fn default() -> RespondPayload
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for RespondPayload
impl RefUnwindSafe for RespondPayload
impl Send for RespondPayload
impl Sync for RespondPayload
impl Unpin for RespondPayload
impl UnsafeUnpin for RespondPayload
impl UnwindSafe for RespondPayload
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