Struct saito_rust::networking::api_message::APIMessage [−][src]
pub struct APIMessage {
pub message_name: [u8; 8],
pub message_id: u32,
pub message_data: Vec<u8>,
}
Expand description
The core data type for transporting data across the Saito Network. See the Network module doc for more details.
ERROR___
RESULT__
SHAKINIT
SHAKCOMP
REQCHAIN
SNDCHAIN
REQBLKHD
SNDBLKHD
SNDTRANS
REQBLOCK
SNDKYLST
Fields
message_name: [u8; 8]
message_id: u32
message_data: Vec<u8>
Implementations
pub fn new_from_string(
message_name: &str,
message_id: u32,
message_string: &str
) -> APIMessage
pub fn get_message_data(&self) -> &Vec<u8>ⓘ
pub fn get_into_message_data(self) -> Vec<u8>ⓘ
Trait Implementations
fn 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
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for APIMessage
impl Send for APIMessage
impl Sync for APIMessage
impl Unpin for APIMessage
impl UnwindSafe for APIMessage
Blanket Implementations
Mutably borrows from an owned value. Read more
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more