#[non_exhaustive]pub enum HaPanicFunction {
Close,
Write,
Read,
}Expand description
The reason MySQL is invoking the engine-level panic callback.
Mirrors enum ha_panic_function in mysql-server/include/my_base.h. Used
only as the argument to Handlerton::panic.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Close
HA_PANIC_CLOSE: close all databases before shutdown.
Write
HA_PANIC_WRITE: unlock and write status.
Read
HA_PANIC_READ: lock and read keyinfo.
Implementations§
Source§impl HaPanicFunction
impl HaPanicFunction
Sourcepub const fn from_raw(value: u32) -> Self
pub const fn from_raw(value: u32) -> Self
Decode the C enum ha_panic_function value. Unknown values map to
HaPanicFunction::Close so the engine still observes a defined variant
rather than a panic on a forward-compatible MySQL change.
Trait Implementations§
Source§impl Clone for HaPanicFunction
impl Clone for HaPanicFunction
Source§fn clone(&self) -> HaPanicFunction
fn clone(&self) -> HaPanicFunction
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 moreimpl Copy for HaPanicFunction
Source§impl Debug for HaPanicFunction
impl Debug for HaPanicFunction
impl Eq for HaPanicFunction
Source§impl PartialEq for HaPanicFunction
impl PartialEq for HaPanicFunction
Source§fn eq(&self, other: &HaPanicFunction) -> bool
fn eq(&self, other: &HaPanicFunction) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for HaPanicFunction
Auto Trait Implementations§
impl Freeze for HaPanicFunction
impl RefUnwindSafe for HaPanicFunction
impl Send for HaPanicFunction
impl Sync for HaPanicFunction
impl Unpin for HaPanicFunction
impl UnsafeUnpin for HaPanicFunction
impl UnwindSafe for HaPanicFunction
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