[][src]Struct solana_ws::Frame

pub struct Frame { /* fields omitted */ }

A struct representing a WebSocket frame.

Methods

impl Frame
[src]

Get the length of the frame. This is the length of the header + the length of the payload.

Return false: a frame is never empty since it has a header.

Test whether the frame is a final frame.

Test whether the first reserved bit is set.

Test whether the second reserved bit is set.

Test whether the third reserved bit is set.

Get the OpCode of the frame.

Test whether this is a control frame.

Get a reference to the frame's payload.

Make this frame a final frame.

Set the first reserved bit.

Set the second reserved bit.

Set the third reserved bit.

Set the OpCode.

Edit the frame's payload.

Consume the frame into its payload.

Create a new data frame.

Create a new Pong control frame.

Create a new Ping control frame.

Create a new Close control frame.

Parse the input stream into a frame.

Write a frame out to a buffer

Trait Implementations

impl Clone for Frame
[src]

Performs copy-assignment from source. Read more

impl Default for Frame
[src]

impl Debug for Frame
[src]

impl Display for Frame
[src]

Auto Trait Implementations

impl Send for Frame

impl Sync for Frame

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]