pub enum ServerMessageParseError {
    MismatchedCommand(IRCMessage),
    MissingTag(IRCMessage, &'static str),
    MissingTagValue(IRCMessage, &'static str),
    MalformedTagValue(IRCMessage, &'static str, String),
    MissingParameter(IRCMessage, usize),
    MalformedChannel(IRCMessage),
    MalformedParameter(IRCMessage, usize),
    MissingPrefix(IRCMessage),
    MissingNickname(IRCMessage),
}Expand description
Errors encountered while trying to parse an IRC message as a more specialized “server message”, based on its IRC command.
Variants
MismatchedCommand(IRCMessage)
That command’s data is not parsed by this implementation
This type of error is only returned if you use try_from directly on a special
server message implementation, instead of the general ServerMessage::try_from
which covers all implementations and does not emit this type of error.
MissingTag(IRCMessage, &'static str)
No tag present under key key
MissingTagValue(IRCMessage, &'static str)
No tag value present under key key
MalformedTagValue(IRCMessage, &'static str, String)
Malformed tag value for tag key, value was value
MissingParameter(IRCMessage, usize)
No parameter found at index n
MalformedChannel(IRCMessage)
Malformed channel parameter (# must be present + something after it)
MalformedParameter(IRCMessage, usize)
Malformed parameter at index n
MissingPrefix(IRCMessage)
Missing prefix altogether
MissingNickname(IRCMessage)
No nickname found in prefix
Trait Implementations
sourceimpl Debug for ServerMessageParseError
 
impl Debug for ServerMessageParseError
sourceimpl Display for ServerMessageParseError
 
impl Display for ServerMessageParseError
sourceimpl Error for ServerMessageParseError
 
impl Error for ServerMessageParseError
1.30.0 · sourcefn source(&self) -> Option<&(dyn Error + 'static)>
 
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · sourcefn description(&self) -> &str
 
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
sourceimpl From<ServerMessageParseError> for IRCMessage
 
impl From<ServerMessageParseError> for IRCMessage
sourcefn from(msg: ServerMessageParseError) -> IRCMessage
 
fn from(msg: ServerMessageParseError) -> IRCMessage
Converts to this type from the input type.
sourceimpl PartialEq<ServerMessageParseError> for ServerMessageParseError
 
impl PartialEq<ServerMessageParseError> for ServerMessageParseError
sourcefn eq(&self, other: &ServerMessageParseError) -> bool
 
fn eq(&self, other: &ServerMessageParseError) -> bool
impl Eq for ServerMessageParseError
impl StructuralEq for ServerMessageParseError
impl StructuralPartialEq for ServerMessageParseError
Auto Trait Implementations
impl RefUnwindSafe for ServerMessageParseError
impl Send for ServerMessageParseError
impl Sync for ServerMessageParseError
impl Unpin for ServerMessageParseError
impl UnwindSafe for ServerMessageParseError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
    T: ?Sized,
 
impl<T> BorrowMut<T> for Twhere
    T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
 
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Qwhere
    Q: Eq + ?Sized,
    K: Borrow<Q> + ?Sized,
 
impl<Q, K> Equivalent<K> for Qwhere
    Q: Eq + ?Sized,
    K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
 
fn equivalent(&self, key: &K) -> bool
Compare self to 
key and return true if they are equal.