Struct diem_sdk::types::mempool_status::MempoolStatus
pub struct MempoolStatus {
pub code: MempoolStatusCode,
pub message: String,
}
Expand description
A MempoolStatus
is represented as a required status code that is semantic coupled with an optional sub status and message.
Fields§
§code: MempoolStatusCode
insertion status code
message: String
optional message
Implementations§
§impl MempoolStatus
impl MempoolStatus
pub fn new(code: MempoolStatusCode) -> MempoolStatus
pub fn with_message(self, message: String) -> MempoolStatus
pub fn with_message(self, message: String) -> MempoolStatus
Adds a message to the Mempool status.
Trait Implementations§
§impl Arbitrary for MempoolStatus
impl Arbitrary for MempoolStatus
§type Parameters = ()
type Parameters = ()
The type of parameters that
arbitrary_with
accepts for configuration
of the generated Strategy
. Parameters must implement Default
.§type Strategy = Map<(<MempoolStatusCode as Arbitrary>::Strategy, <String as Arbitrary>::Strategy), fn(_: (MempoolStatusCode, String)) -> MempoolStatus>
type Strategy = Map<(<MempoolStatusCode as Arbitrary>::Strategy, <String as Arbitrary>::Strategy), fn(_: (MempoolStatusCode, String)) -> MempoolStatus>
The type of
Strategy
used to generate values of type Self
.§fn arbitrary_with(
_top: <MempoolStatus as Arbitrary>::Parameters
) -> <MempoolStatus as Arbitrary>::Strategy
fn arbitrary_with( _top: <MempoolStatus as Arbitrary>::Parameters ) -> <MempoolStatus as Arbitrary>::Strategy
§impl Clone for MempoolStatus
impl Clone for MempoolStatus
§fn clone(&self) -> MempoolStatus
fn clone(&self) -> MempoolStatus
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 more§impl Debug for MempoolStatus
impl Debug for MempoolStatus
§impl Hash for MempoolStatus
impl Hash for MempoolStatus
§impl Ord for MempoolStatus
impl Ord for MempoolStatus
§impl PartialEq<MempoolStatus> for MempoolStatus
impl PartialEq<MempoolStatus> for MempoolStatus
§fn eq(&self, other: &MempoolStatus) -> bool
fn eq(&self, other: &MempoolStatus) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.§impl PartialOrd<MempoolStatus> for MempoolStatus
impl PartialOrd<MempoolStatus> for MempoolStatus
§fn partial_cmp(&self, other: &MempoolStatus) -> Option<Ordering>
fn partial_cmp(&self, other: &MempoolStatus) -> 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 moreimpl Eq for MempoolStatus
impl StructuralEq for MempoolStatus
impl StructuralPartialEq for MempoolStatus
Auto Trait Implementations§
impl RefUnwindSafe for MempoolStatus
impl Send for MempoolStatus
impl Sync for MempoolStatus
impl Unpin for MempoolStatus
impl UnwindSafe for MempoolStatus
Blanket Implementations§
source§impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.