pub enum CommandMsg {
Subscribe {
req_id: Option<String>,
ret_msg: Option<String>,
conn_id: String,
success: bool,
},
Unsubscribe {
req_id: Option<String>,
ret_msg: Option<String>,
conn_id: String,
success: bool,
},
Auth {
req_id: Option<String>,
ret_msg: Option<String>,
conn_id: String,
success: bool,
},
Pong {
req_id: Option<String>,
ret_msg: Option<String>,
conn_id: Option<String>,
args: Option<Vec<String>>,
success: Option<bool>,
},
Ping {
req_id: Option<String>,
ret_msg: Option<String>,
conn_id: Option<String>,
args: Option<Vec<String>>,
success: Option<bool>,
},
}Expand description
Reply of a public or private stream to a command.
Variants§
Subscribe
Reply to subscribe.
Fields
Unsubscribe
Reply to unsubscribe.
Fields
Auth
Reply to auth.
Fields
Pong
Heartbeat reply. Its shape differs per stream (option and spread
public streams send neither conn_id nor success), so every field
is optional.
Fields
Ping
Heartbeat reply of spot and linear/inverse public streams
("op": "ping", "ret_msg": "pong").
Fields
Trait Implementations§
Source§impl Debug for CommandMsg
impl Debug for CommandMsg
Source§impl<'de> Deserialize<'de> for CommandMsg
impl<'de> Deserialize<'de> for CommandMsg
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 PartialEq for CommandMsg
impl PartialEq for CommandMsg
impl StructuralPartialEq for CommandMsg
Auto Trait Implementations§
impl Freeze for CommandMsg
impl RefUnwindSafe for CommandMsg
impl Send for CommandMsg
impl Sync for CommandMsg
impl Unpin for CommandMsg
impl UnsafeUnpin for CommandMsg
impl UnwindSafe for CommandMsg
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