Enum mysql_common::packets::ErrPacket [−][src]
MySql error packet.
May hold an error or a progress report.
Variants
Error(u16, [u8; 5], Cow<'a, [u8]>)
(
Progress(ProgressReport<'a>)
Methods
impl<'a> ErrPacket<'a>
[src]
impl<'a> ErrPacket<'a>
pub fn is_error(&self) -> bool
[src]
pub fn is_error(&self) -> bool
Returns false if this error packet contains progress report.
pub fn is_progress_report(&self) -> bool
[src]
pub fn is_progress_report(&self) -> bool
Returns true if this error packet contains progress report.
pub fn progress_report(&self) -> &ProgressReport
[src]
pub fn progress_report(&self) -> &ProgressReport
Will panic if ErrPacket does not contains progress report
pub fn error_code(&self) -> u16
[src]
pub fn error_code(&self) -> u16
Will panic if ErrPacket contains progress report
pub fn sql_state_ref(&self) -> &[u8; 5]
[src]
pub fn sql_state_ref(&self) -> &[u8; 5]
Will panic if ErrPacket contains progress report
pub fn sql_state_str(&self) -> Cow<str>
[src]
pub fn sql_state_str(&self) -> Cow<str>
Will panic if ErrPacket contains progress report
pub fn message_ref(&self) -> &[u8]
[src]
pub fn message_ref(&self) -> &[u8]
Will panic if ErrPacket contains progress report
pub fn message_str(&self) -> Cow<str>
[src]
pub fn message_str(&self) -> Cow<str>
Will panic if ErrPacket contains progress report
pub fn into_owned(self) -> ErrPacket<'static>
[src]
pub fn into_owned(self) -> ErrPacket<'static>
Trait Implementations
impl<'a> Clone for ErrPacket<'a>
[src]
impl<'a> Clone for ErrPacket<'a>
fn clone(&self) -> ErrPacket<'a>
[src]
fn clone(&self) -> ErrPacket<'a>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl<'a> PartialEq for ErrPacket<'a>
[src]
impl<'a> PartialEq for ErrPacket<'a>
fn eq(&self, other: &ErrPacket<'a>) -> bool
[src]
fn eq(&self, other: &ErrPacket<'a>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &ErrPacket<'a>) -> bool
[src]
fn ne(&self, other: &ErrPacket<'a>) -> bool
This method tests for !=
.
impl<'a> Debug for ErrPacket<'a>
[src]
impl<'a> Debug for ErrPacket<'a>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<'a> Display for ErrPacket<'a>
[src]
impl<'a> Display for ErrPacket<'a>