pub struct Packet {
pub stream: IsStream,
pub end: IsEnd,
pub body_type: BodyType,
pub id: i32,
pub body: Vec<u8>,
}Fields§
§stream: IsStream§end: IsEnd§body_type: BodyType§id: i32§body: Vec<u8>Implementations§
Trait Implementations§
Source§impl<W> Sink<Packet> for PacketSink<W>where
W: AsyncWrite + Unpin + 'static,
impl<W> Sink<Packet> for PacketSink<W>where
W: AsyncWrite + Unpin + 'static,
Source§fn poll_ready(
self: Pin<&mut Self>,
cx: &mut Context<'_>,
) -> Poll<Result<(), Self::Error>>
fn poll_ready( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Self::Error>>
Attempts to prepare the
Sink to receive a value. Read moreSource§fn start_send(self: Pin<&mut Self>, item: Packet) -> Result<(), Self::Error>
fn start_send(self: Pin<&mut Self>, item: Packet) -> Result<(), Self::Error>
Begin the process of sending a value to the sink.
Each call to this function must be preceded by a successful call to
poll_ready which returned Poll::Ready(Ok(())). Read moreimpl StructuralPartialEq for Packet
Auto Trait Implementations§
impl Freeze for Packet
impl RefUnwindSafe for Packet
impl Send for Packet
impl Sync for Packet
impl Unpin for Packet
impl UnwindSafe for Packet
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