Enum chain_impl_mockchain::vote::payload::PayloadType
source · #[repr(u8)]pub enum PayloadType {
Public,
Private,
}
Expand description
the PayloadType
to use for a vote plan
this defines how the vote must be published on chain.
Be careful because the default is set to Public
.
use chain_impl_mockchain::vote::PayloadType;
assert_eq!(PayloadType::Public, PayloadType::default());
Variants§
Trait Implementations§
source§impl Arbitrary for PayloadType
impl Arbitrary for PayloadType
source§impl Clone for PayloadType
impl Clone for PayloadType
source§fn clone(&self) -> PayloadType
fn clone(&self) -> PayloadType
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for PayloadType
impl Debug for PayloadType
source§impl Default for PayloadType
impl Default for PayloadType
source§fn default() -> PayloadType
fn default() -> PayloadType
Returns the “default value” for a type. Read more
source§impl Hash for PayloadType
impl Hash for PayloadType
source§impl Ord for PayloadType
impl Ord for PayloadType
source§fn cmp(&self, other: &PayloadType) -> Ordering
fn cmp(&self, other: &PayloadType) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<PayloadType> for PayloadType
impl PartialEq<PayloadType> for PayloadType
source§fn eq(&self, other: &PayloadType) -> bool
fn eq(&self, other: &PayloadType) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<PayloadType> for PayloadType
impl PartialOrd<PayloadType> for PayloadType
source§fn partial_cmp(&self, other: &PayloadType) -> Option<Ordering>
fn partial_cmp(&self, other: &PayloadType) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl TryFrom<u8> for PayloadType
impl TryFrom<u8> for PayloadType
impl Copy for PayloadType
impl Eq for PayloadType
impl StructuralEq for PayloadType
impl StructuralPartialEq for PayloadType
Auto Trait Implementations§
impl RefUnwindSafe for PayloadType
impl Send for PayloadType
impl Sync for PayloadType
impl Unpin for PayloadType
impl UnwindSafe for PayloadType
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