Enum primitives::validator::MessageType
source · pub enum MessageType {
ApproveState,
NewState,
RejectState,
Heartbeat,
}
Expand description
All available message type names.
Variants
ApproveState
NewState
RejectState
Heartbeat
Trait Implementations
sourceimpl Clone for MessageType
impl Clone for MessageType
sourcefn clone(&self) -> MessageType
fn clone(&self) -> MessageType
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for MessageType
impl Debug for MessageType
sourceimpl<'de> Deserialize<'de> for MessageType
impl<'de> Deserialize<'de> for MessageType
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Display for MessageType
impl Display for MessageType
sourceimpl From<&MessageTypes> for MessageType
impl From<&MessageTypes> for MessageType
This ensures that all MessageTypes
are also listed in the enum MessageType
!
sourcefn from(message_types: &MessageTypes) -> Self
fn from(message_types: &MessageTypes) -> Self
Converts to this type from the input type.
sourceimpl From<MessageTypes> for MessageType
impl From<MessageTypes> for MessageType
sourcefn from(message_types: MessageTypes) -> Self
fn from(message_types: MessageTypes) -> Self
Converts to this type from the input type.
sourceimpl<'a> FromSql<'a> for MessageType
impl<'a> FromSql<'a> for MessageType
sourcefn from_sql(
ty: &Type,
raw: &'a [u8]
) -> Result<Self, Box<dyn Error + Sync + Send>>
fn from_sql(
ty: &Type,
raw: &'a [u8]
) -> Result<Self, Box<dyn Error + Sync + Send>>
Creates a new value of this type from a buffer of data of the specified
Postgres
Type
in its binary format. Read moresourcefn accepts(ty: &Type) -> bool
fn accepts(ty: &Type) -> bool
Determines if a value of this type can be created from the specified
Postgres
Type
. Read moresourceimpl FromStr for MessageType
impl FromStr for MessageType
sourceimpl PartialEq<MessageType> for MessageType
impl PartialEq<MessageType> for MessageType
sourcefn eq(&self, other: &MessageType) -> bool
fn eq(&self, other: &MessageType) -> bool
sourceimpl Serialize for MessageType
impl Serialize for MessageType
sourceimpl ToSql for MessageType
impl ToSql for MessageType
sourcefn to_sql(
&self,
ty: &Type,
w: &mut BytesMut
) -> Result<IsNull, Box<dyn Error + Sync + Send>>
fn to_sql(
&self,
ty: &Type,
w: &mut BytesMut
) -> Result<IsNull, Box<dyn Error + Sync + Send>>
Converts the value of
self
into the binary format of the specified
Postgres Type
, appending it to out
. Read moresourcefn accepts(ty: &Type) -> bool
fn accepts(ty: &Type) -> bool
Determines if a value of this type can be converted to the specified
Postgres
Type
. Read moresourcefn to_sql_checked(
&self,
ty: &Type,
out: &mut BytesMut
) -> Result<IsNull, Box<dyn Error + Sync + Send>>
fn to_sql_checked(
&self,
ty: &Type,
out: &mut BytesMut
) -> Result<IsNull, Box<dyn Error + Sync + Send>>
An adaptor method used internally by Rust-Postgres. Read more
sourcefn encode_format(&self, _ty: &Type) -> Format
fn encode_format(&self, _ty: &Type) -> Format
Specify the encode format
impl Copy for MessageType
impl Eq for MessageType
impl StructuralEq for MessageType
impl StructuralPartialEq for MessageType
Auto Trait Implementations
impl RefUnwindSafe for MessageType
impl Send for MessageType
impl Sync for MessageType
impl Unpin for MessageType
impl UnwindSafe for MessageType
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> BorrowToSql for Twhere
T: ToSql,
impl<T> BorrowToSql for Twhere
T: ToSql,
sourcefn borrow_to_sql(&self) -> &dyn ToSql
fn borrow_to_sql(&self) -> &dyn ToSql
Returns a reference to
self
as a ToSql
trait object.