pub enum MessageType {
Show 13 variants
PeerDiscovery,
RequestLocalPeers,
LocalPeers,
RequestSharedObjectUpdate,
SharedObjectUpdate,
Get,
Set,
Delete,
Response,
Notification,
Heartbeat,
Error,
Custom(String),
}
Expand description
Message types for inter-node communication
Variants§
PeerDiscovery
Peer discovery message
RequestLocalPeers
Request for local peers
LocalPeers
Response with local peers
Request for shared object update
Response with shared object data
Get
Request to get an object
Set
Request to set an object
Delete
Request to delete an object
Response
Response containing requested data
Notification
Notification of changes
Heartbeat
Heartbeat/ping message
Error
Error response
Custom(String)
Custom application message
Trait Implementations§
Source§impl Clone for MessageType
impl Clone for MessageType
Source§fn clone(&self) -> MessageType
fn clone(&self) -> MessageType
Returns a duplicate 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 MessageType
impl Debug for MessageType
Source§impl<'de> Deserialize<'de> for MessageType
impl<'de> Deserialize<'de> for MessageType
Source§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
Source§impl Display for MessageType
impl Display for MessageType
Source§impl PartialEq for MessageType
impl PartialEq for MessageType
Source§impl Serialize for MessageType
impl Serialize for MessageType
impl Eq for MessageType
impl StructuralPartialEq for MessageType
Auto Trait Implementations§
impl Freeze for MessageType
impl RefUnwindSafe for MessageType
impl Send for MessageType
impl Sync for MessageType
impl Unpin for MessageType
impl UnwindSafe for MessageType
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