pub enum Message {
Result {
id: Uuid,
jsonrpc: String,
result: Box<SnapcastResult>,
},
Error {
id: Uuid,
jsonrpc: String,
error: SnapcastError,
},
Notification {
jsonrpc: String,
method: Box<Notification>,
},
}
Expand description
A message received from the Snapcast server
Variants§
Result
A message that is in response to a request
Fields
§
result: Box<SnapcastResult>
The result of the request
Error
An error from the server
Fields
§
error: SnapcastError
The error
Notification
A notification from the server
Fields
§
method: Box<Notification>
The notification data itself as a tagged enum
Trait Implementations§
Source§impl TryFrom<Message> for ValidMessage
impl TryFrom<Message> for ValidMessage
impl StructuralPartialEq for Message
Auto Trait Implementations§
impl Freeze for Message
impl RefUnwindSafe for Message
impl Send for Message
impl Sync for Message
impl Unpin for Message
impl UnwindSafe for Message
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