Enum libp2p::websocket::framed::OutgoingData
source · pub enum OutgoingData {
Binary(Vec<u8, Global>),
Ping(Vec<u8, Global>),
Pong(Vec<u8, Global>),
}
Expand description
Data sent over the websocket connection.
Variants§
Binary(Vec<u8, Global>)
Send some bytes.
Ping(Vec<u8, Global>)
Send a PING message.
Pong(Vec<u8, Global>)
Send an unsolicited PONG message. (Incoming PINGs are answered automatically.)
Trait Implementations§
source§impl Clone for OutgoingData
impl Clone for OutgoingData
source§fn clone(&self) -> OutgoingData
fn clone(&self) -> OutgoingData
Returns a copy 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 OutgoingData
impl Debug for OutgoingData
source§impl<T> Sink<OutgoingData> for Connection<T>where
T: AsyncRead + AsyncWrite + Send + Unpin + 'static,
impl<T> Sink<OutgoingData> for Connection<T>where T: AsyncRead + AsyncWrite + Send + Unpin + 'static,
source§fn poll_ready(
self: Pin<&mut Connection<T>>,
cx: &mut Context<'_>
) -> Poll<Result<(), Error>>
fn poll_ready( self: Pin<&mut Connection<T>>, cx: &mut Context<'_> ) -> Poll<Result<(), Error>>
Attempts to prepare the
Sink
to receive a value. Read moresource§fn start_send(
self: Pin<&mut Connection<T>>,
item: OutgoingData
) -> Result<(), Error>
fn start_send( self: Pin<&mut Connection<T>>, item: OutgoingData ) -> Result<(), 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 moreAuto Trait Implementations§
impl RefUnwindSafe for OutgoingData
impl Send for OutgoingData
impl Sync for OutgoingData
impl Unpin for OutgoingData
impl UnwindSafe for OutgoingData
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