Enum libp2p_websocket::framed::OutgoingData
source · [−]Expand description
Data sent over the websocket connection.
Variants
Binary(Vec<u8>)
Send some bytes.
Ping(Vec<u8>)
Send a PING message.
Pong(Vec<u8>)
Send an unsolicited PONG message. (Incoming PINGs are answered automatically.)
Trait Implementations
sourceimpl Clone for OutgoingData
impl Clone for OutgoingData
sourcefn clone(&self) -> OutgoingData
fn clone(&self) -> OutgoingData
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for OutgoingData
impl Debug for OutgoingData
sourceimpl<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,
sourcefn poll_ready(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<()>>
fn poll_ready(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<()>>
Attempts to prepare the Sink
to receive a value. Read more
sourcefn start_send(self: Pin<&mut Self>, item: OutgoingData) -> Result<()>
fn start_send(self: Pin<&mut Self>, item: OutgoingData) -> Result<()>
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 more
Auto Trait Implementations
impl RefUnwindSafe for OutgoingData
impl Send for OutgoingData
impl Sync for OutgoingData
impl Unpin for OutgoingData
impl UnwindSafe for OutgoingData
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more