#[non_exhaustive]pub struct Message {
pub message: Option<String>,
pub severity: Option<String>,
/* private fields */
}Expand description
Represents a notice or warning message from the database.
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.message: Option<String>The full message string. For PostgreSQL, this is a formatted string that may include severity, code, and the notice/warning message. For MySQL, this contains the warning message.
severity: Option<String>The severity of the message (e.g., “NOTICE” for PostgreSQL, “WARNING” for MySQL).
Implementations§
Source§impl Message
impl Message
pub fn new() -> Self
Sourcepub fn set_message<T>(self, v: T) -> Self
pub fn set_message<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_message<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_message<T>(self, v: Option<T>) -> Self
Sourcepub fn set_severity<T>(self, v: T) -> Self
pub fn set_severity<T>(self, v: T) -> Self
Trait Implementations§
impl StructuralPartialEq for Message
Auto Trait Implementations§
impl Freeze for Message
impl RefUnwindSafe for Message
impl Send for Message
impl Sync for Message
impl Unpin for Message
impl UnwindSafe for Message
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