[][src]Enum audiosocket::Message

pub enum Message<'r> {
    Terminate,
    Identifier(Uuid),
    Silence,
    Audio(Option<&'r [u8]>),
    Error(Option<ErrorType>),
}

AudioSocket message.

You may use RawMessage to obtain one.

Variants

Terminate

Message indicates that a connection was closed.

Closing socket also works.

Identifier(Uuid)

Message contains UUID of current stream.

Silence

Message indicates presence of silence on the line.

Message possibly contains signed linear, 16-bit, 8kHz, mono PCM (little-endian) audio payload.

Message indicates Asterisk error, and possibly contains ErrorType.

Trait Implementations

impl<'r> Clone for Message<'r>[src]

impl<'r> Copy for Message<'r>[src]

impl<'r> Debug for Message<'r>[src]

impl<'r> Eq for Message<'r>[src]

impl<'r> PartialEq<Message<'r>> for Message<'r>[src]

impl<'r> StructuralEq for Message<'r>[src]

impl<'r> StructuralPartialEq for Message<'r>[src]

impl<'s> TryFrom<RawMessage<'s>> for Message<'s>[src]

type Error = AudioSocketError

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<'r> RefUnwindSafe for Message<'r>[src]

impl<'r> Send for Message<'r>[src]

impl<'r> Sync for Message<'r>[src]

impl<'r> Unpin for Message<'r>[src]

impl<'r> UnwindSafe for Message<'r>[src]

Blanket Implementations

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

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

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

impl<T> From<T> for T[src]

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

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

type Owned = T

The resulting type after obtaining ownership.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.