Struct warp::filters::ws::Message[][src]

pub struct Message { /* fields omitted */ }

A WebSocket message.

Only repesents Text and Binary messages.

This will likely become a non-exhaustive enum in the future, once that language feature has stabilized.

Methods

impl Message
[src]

Construct a new Text Message.

Construct a new Binary Message.

Returns true if this message is a Text message.

Returns true if this message is a Binary message.

Try to get a reference to the string text, if this is a Text message.

Return the bytes of this message.

Trait Implementations

impl Debug for Message
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl Send for Message

impl Sync for Message