pub enum ToClientBody {
Init(Init),
Error(Error),
ActionResponse(ActionResponse),
Event(Event),
}Expand description
BARE union ToClientBody.
Variants§
Trait Implementations§
Source§impl Clone for ToClientBody
impl Clone for ToClientBody
Source§impl Debug for ToClientBody
impl Debug for ToClientBody
Source§impl Encode for ToClientBody
impl Encode for ToClientBody
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
The exact encoded length, computed without encoding.
fn encode<S: Sink>(&self, out: &mut S)
fn encode_to_vec(&self) -> Vec<u8> ⓘ
fn encode_to_bytes(&self) -> Bytes
Source§fn encode_to_slice(&self, out: &mut [u8]) -> Result<usize, EncodeError>
fn encode_to_slice(&self, out: &mut [u8]) -> Result<usize, EncodeError>
Encodes into the front of
out and returns the number of bytes written. Checks the length
first instead of panicking when out is too short.impl Eq for ToClientBody
Source§impl From<ToClientBody> for ToClientBody
impl From<ToClientBody> for ToClientBody
Source§fn from(value: ToClientBody) -> Self
fn from(value: ToClientBody) -> Self
Converts to this type from the input type.
Source§impl From<ToClientBody> for ToClientBody
impl From<ToClientBody> for ToClientBody
Source§fn from(value: ToClientBody) -> Self
fn from(value: ToClientBody) -> Self
Converts to this type from the input type.
Source§impl Hash for ToClientBody
impl Hash for ToClientBody
Source§impl Message for ToClientBody
impl Message for ToClientBody
Source§type Wire = ToClientBodyWire
type Wire = ToClientBodyWire
The wire marker whose owned form is this type.
Source§fn view(bytes: Bytes) -> Result<View<Self::Wire>, DecodeError>
fn view(bytes: Bytes) -> Result<View<Self::Wire>, DecodeError>
Verifies
bytes and returns a zero-copy view over them.Source§impl PartialEq for ToClientBody
impl PartialEq for ToClientBody
impl StructuralPartialEq for ToClientBody
Auto Trait Implementations§
impl !Freeze for ToClientBody
impl RefUnwindSafe for ToClientBody
impl Send for ToClientBody
impl Sync for ToClientBody
impl Unpin for ToClientBody
impl UnsafeUnpin for ToClientBody
impl UnwindSafe for ToClientBody
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