Skip to main content

Message

Struct Message 

Source
pub struct Message<V: Validator, S: Signature, A: AggregateSignature, B: Block> { /* private fields */ }
Expand description

A message from the Tendermint consensus process.

This encapsulates a [Data] with the validator, block and round numbers, and signature.

Trait Implementations§

Source§

impl<V, S, A, B> BorshDeserialize for Message<V, S, A, B>

Source§

fn deserialize_reader<__R: Read>(reader: &mut __R) -> Result<Self, Error>

Source§

fn deserialize(buf: &mut &[u8]) -> Result<Self, Error>

Deserializes this instance from a given slice of bytes. Updates the buffer to point at the remaining bytes.
Source§

fn try_from_slice(v: &[u8]) -> Result<Self, Error>

Deserialize this instance from a slice of bytes.
Source§

fn try_from_reader<R>(reader: &mut R) -> Result<Self, Error>
where R: Read,

Source§

impl<V, S, A, B> BorshSerialize for Message<V, S, A, B>

Source§

fn serialize<__W: Write>(&self, writer: &mut __W) -> Result<(), Error>

Source§

impl<V: Clone + Validator, S: Clone + Signature, A: Clone + AggregateSignature, B: Clone + Block> Clone for Message<V, S, A, B>

Source§

fn clone(&self) -> Message<V, S, A, B>

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<V: Validator, S: Signature, A: AggregateSignature, B: Block> Eq for Message<V, S, A, B>

Source§

impl<V: Validator, S: Signature, A: AggregateSignature, B: Block> PartialEq for Message<V, S, A, B>

Source§

fn eq(&self, other: &Self) -> bool

This equality is semantic and does not consider if any present signatures are equal. This ensures even for signature schemes with malleable signatures, multiple signatures over the same messages are not semantically treated as distinct signatures. However, this also means a value with an invalid signature will be considered equal to a message with a valid signature.

1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more

Auto Trait Implementations§

§

impl<V, S, A, B> Freeze for Message<V, S, A, B>
where V: Freeze, S: Freeze, B: Freeze, <B as Block>::Hash: Freeze, A: Freeze,

§

impl<V, S, A, B> RefUnwindSafe for Message<V, S, A, B>

§

impl<V, S, A, B> Send for Message<V, S, A, B>
where V: Send, S: Send, B: Send, <B as Block>::Hash: Send, A: Send,

§

impl<V, S, A, B> Sync for Message<V, S, A, B>
where V: Sync, S: Sync, B: Sync, <B as Block>::Hash: Sync, A: Sync,

§

impl<V, S, A, B> Unpin for Message<V, S, A, B>
where V: Unpin, S: Unpin, B: Unpin, <B as Block>::Hash: Unpin, A: Unpin,

§

impl<V, S, A, B> UnsafeUnpin for Message<V, S, A, B>

§

impl<V, S, A, B> UnwindSafe for Message<V, S, A, B>

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. 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> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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.