Struct SemiSyncAckPacket

Source
pub struct SemiSyncAckPacket<'a> { /* private fields */ }
Expand description

Each Semi Sync Binlog Event with the SEMI_SYNC_ACK_REQ flag set the slave has to acknowledge with Semi-Sync ACK packet.

Implementations§

Source§

impl<'a> SemiSyncAckPacket<'a>

Source

pub fn new(position: u64, filename: impl Into<Cow<'a, [u8]>>) -> Self

Source

pub fn with_position(self, position: u64) -> Self

Sets the position field value.

Source

pub fn with_filename(self, filename: impl Into<Cow<'a, [u8]>>) -> Self

Sets the filename field value.

Source

pub fn position(&self) -> u64

Returns the position field value.

Source

pub fn filename_raw(&self) -> &[u8]

Returns the raw filename field value.

Source

pub fn filename(&self) -> Cow<'_, str>

Returns the filename field value as a string (lossy converted).

Trait Implementations§

Source§

impl<'de> MyDeserialize<'de> for SemiSyncAckPacket<'de>

Source§

const SIZE: Option<usize> = None

Size hint of a serialized value (in bytes), if it’s constant.
Source§

type Ctx = ()

Some structs defines deserialization in the context of another value. Read more
Source§

fn deserialize((): Self::Ctx, buf: &mut ParseBuf<'de>) -> Result<Self>

Deserializes self from the given buf. Read more
Source§

impl MySerialize for SemiSyncAckPacket<'_>

Source§

fn serialize(&self, buf: &mut Vec<u8>)

Serializes self into the buf.

Auto Trait Implementations§

§

impl<'a> Freeze for SemiSyncAckPacket<'a>

§

impl<'a> RefUnwindSafe for SemiSyncAckPacket<'a>

§

impl<'a> Send for SemiSyncAckPacket<'a>

§

impl<'a> Sync for SemiSyncAckPacket<'a>

§

impl<'a> Unpin for SemiSyncAckPacket<'a>

§

impl<'a> UnwindSafe for SemiSyncAckPacket<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.