pub enum PhoenixMessage {
PhxJoin {
topic: String,
payload: Value,
msg_ref: String,
},
PhxReply {
topic: String,
payload: PhxReplyPayload,
msg_ref: String,
},
Heartbeat {
topic: String,
payload: Value,
msg_ref: String,
},
Broadcast {
topic: String,
payload: BroadcastPayload,
msg_ref: Option<String>,
},
PresenceState {
topic: String,
payload: Value,
msg_ref: Option<String>,
},
PresenceDiff {
topic: String,
payload: Value,
msg_ref: Option<String>,
},
}Expand description
Message types for Supabase Realtime protocol
Variants§
PhxJoin
Join a channel
Fields
PhxReply
Reply to a message
Fields
§
payload: PhxReplyPayloadReply payload with status.
Heartbeat
Heartbeat (keep-alive)
Fields
Broadcast
Broadcast message
Fields
§
payload: BroadcastPayloadBroadcast payload containing the event data.
PresenceState
Presence state
Fields
PresenceDiff
Presence diff
Trait Implementations§
Source§impl Clone for PhoenixMessage
impl Clone for PhoenixMessage
Source§fn clone(&self) -> PhoenixMessage
fn clone(&self) -> PhoenixMessage
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 PhoenixMessage
impl Debug for PhoenixMessage
Source§impl<'de> Deserialize<'de> for PhoenixMessage
impl<'de> Deserialize<'de> for PhoenixMessage
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
Auto Trait Implementations§
impl Freeze for PhoenixMessage
impl RefUnwindSafe for PhoenixMessage
impl Send for PhoenixMessage
impl Sync for PhoenixMessage
impl Unpin for PhoenixMessage
impl UnsafeUnpin for PhoenixMessage
impl UnwindSafe for PhoenixMessage
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