[][src]Struct irc_rust::prefix::Prefix

pub struct Prefix<'a> { /* fields omitted */ }

Message prefix containing a name (servername or nickname) and optional user and host. If the user and host are set the name is semantically seen as the nickname.

Implementations

impl<'a> Prefix<'a>[src]

pub fn new(raw: &'a str) -> Prefix<'a>[src]

Create a new Prefix from the given string. Expects the string to be a valid prefix string.

pub fn name(&self) -> &'a str[src]

pub fn host(&self) -> Option<&'a str>[src]

pub fn user(&self) -> Option<&'a str>[src]

Trait Implementations

impl<'a> ToString for Prefix<'a>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for Prefix<'a>

impl<'a> Send for Prefix<'a>

impl<'a> Sync for Prefix<'a>

impl<'a> Unpin for Prefix<'a>

impl<'a> UnwindSafe for Prefix<'a>

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> ToString for T where
    T: Display + ?Sized
[src]

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.