Skip to main content

Reply

Enum Reply 

Source
pub enum Reply {
Show 36 variants Welcome { nick: String, network: String, }, YourHost { nick: String, servername: String, version: String, }, Created { nick: String, date: String, }, MyInfo { nick: String, servername: String, version: String, usermodes: String, chanmodes: String, }, ISupport { nick: String, tokens: Vec<String>, }, NoTopic { nick: String, channel: String, }, Topic { nick: String, channel: String, topic: String, }, NamReply { nick: String, symbol: char, channel: String, names: Vec<String>, }, EndOfNames { nick: String, channel: String, }, MotdStart { nick: String, server: String, }, Motd { nick: String, line: String, }, EndOfMotd { nick: String, }, NoMotd { nick: String, }, NoSuchNick { nick: String, target: String, }, NoSuchChannel { nick: String, channel: String, }, CannotSendToChan { nick: String, channel: String, }, NotOnChannel { nick: String, channel: String, }, NicknameInUse { nick: String, attempted: String, }, NeedMoreParams { nick: String, command: String, }, AlreadyRegistered { nick: String, }, UnknownCommand { nick: String, command: String, }, PasswdMismatch { nick: String, }, NotRegistered { nick: String, }, ErroneousNickname { nick: String, attempted: String, }, BadChannelKey { nick: String, channel: String, }, ChannelIsFull { nick: String, channel: String, }, ChanOpPrivsNeeded { nick: String, channel: String, }, UserNotInChannel { nick: String, target: String, channel: String, }, ChannelModeIs { nick: String, channel: String, modes: String, params: Vec<String>, }, List { nick: String, channel: String, visible: usize, topic: String, }, EndOfWho { nick: String, target: String, }, WhoisUser { nick: String, target: String, username: String, host: String, realname: String, }, WhoisServer { nick: String, target: String, server: String, info: String, }, EndOfWhois { nick: String, target: String, }, ListStart { nick: String, }, ListEnd { nick: String, },
}
Expand description

IRC numeric replies and error codes

Variantsยง

ยง

Welcome

001 RPL_WELCOME

Fields

ยงnetwork: String
ยง

YourHost

002 RPL_YOURHOST

Fields

ยงservername: String
ยงversion: String
ยง

Created

003 RPL_CREATED

Fields

ยง

MyInfo

004 RPL_MYINFO

Fields

ยงservername: String
ยงversion: String
ยงusermodes: String
ยงchanmodes: String
ยง

ISupport

005 RPL_ISUPPORT

Fields

ยงtokens: Vec<String>
ยง

NoTopic

331 RPL_NOTOPIC

Fields

ยงchannel: String
ยง

Topic

332 RPL_TOPIC

Fields

ยงchannel: String
ยง

NamReply

353 RPL_NAMREPLY

Fields

ยงsymbol: char
ยงchannel: String
ยง

EndOfNames

366 RPL_ENDOFNAMES

Fields

ยงchannel: String
ยง

MotdStart

375 RPL_MOTDSTART

Fields

ยงserver: String
ยง

Motd

372 RPL_MOTD

Fields

ยง

EndOfMotd

376 RPL_ENDOFMOTD

Fields

ยง

NoMotd

422 ERR_NOMOTD

Fields

ยง

NoSuchNick

401 ERR_NOSUCHNICK

Fields

ยงtarget: String
ยง

NoSuchChannel

403 ERR_NOSUCHCHANNEL

Fields

ยงchannel: String
ยง

CannotSendToChan

404 ERR_CANNOTSENDTOCHAN

Fields

ยงchannel: String
ยง

NotOnChannel

442 ERR_NOTONCHANNEL

Fields

ยงchannel: String
ยง

NicknameInUse

433 ERR_NICKNAMEINUSE

Fields

ยงattempted: String
ยง

NeedMoreParams

461 ERR_NEEDMOREPARAMS

Fields

ยงcommand: String
ยง

AlreadyRegistered

462 ERR_ALREADYREGISTERED

Fields

ยง

UnknownCommand

421 ERR_UNKNOWNCOMMAND

Fields

ยงcommand: String
ยง

PasswdMismatch

464 ERR_PASSWDMISMATCH

Fields

ยง

NotRegistered

451 ERR_NOTREGISTERED

Fields

ยง

ErroneousNickname

432 ERR_ERRONEUSNICKNAME

Fields

ยงattempted: String
ยง

BadChannelKey

475 ERR_BADCHANNELKEY

Fields

ยงchannel: String
ยง

ChannelIsFull

471 ERR_CHANNELISFULL

Fields

ยงchannel: String
ยง

ChanOpPrivsNeeded

482 ERR_CHANOPRIVSNEEDED

Fields

ยงchannel: String
ยง

UserNotInChannel

441 ERR_USERNOTINCHANNEL

Fields

ยงtarget: String
ยงchannel: String
ยง

ChannelModeIs

324 RPL_CHANNELMODEIS

Fields

ยงchannel: String
ยงparams: Vec<String>
ยง

List

322 RPL_LIST

Fields

ยงchannel: String
ยงvisible: usize
ยง

EndOfWho

315 RPL_ENDOFWHO

Fields

ยงtarget: String
ยง

WhoisUser

311 RPL_WHOISUSER

Fields

ยงtarget: String
ยงusername: String
ยงrealname: String
ยง

WhoisServer

312 RPL_WHOISSERVER

Fields

ยงtarget: String
ยงserver: String
ยง

EndOfWhois

318 RPL_ENDOFWHOIS

Fields

ยงtarget: String
ยง

ListStart

321 RPL_LISTSTART

Fields

ยง

ListEnd

323 RPL_LISTEND

Fields

Implementationsยง

Sourceยง

impl Reply

Source

pub fn to_message(&self, server_name: &str) -> IrcMessage

Convert reply to IRC message

Trait Implementationsยง

Sourceยง

impl Clone for Reply

Sourceยง

fn clone(&self) -> Reply

Returns a duplicate of the value. Read more
1.0.0 ยท Sourceยง

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Sourceยง

impl Debug for Reply

Sourceยง

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Sourceยง

impl From<Reply> for IrcMessage

Sourceยง

fn from(reply: Reply) -> Self

Converts to this type from the input type.

Auto Trait Implementationsยง

Blanket Implementationsยง

Sourceยง

impl<T> Any for T
where T: 'static + ?Sized,

Sourceยง

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Sourceยง

impl<T> Borrow<T> for T
where T: ?Sized,

Sourceยง

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Sourceยง

impl<T> BorrowMut<T> for T
where T: ?Sized,

Sourceยง

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Sourceยง

impl<T> CloneToUninit for T
where T: Clone,

Sourceยง

unsafe fn clone_to_uninit(&self, dest: *mut u8)

๐Ÿ”ฌThis is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Sourceยง

impl<T> From<T> for T

Sourceยง

fn from(t: T) -> T

Returns the argument unchanged.

Sourceยง

impl<T, U> Into<U> for T
where U: From<T>,

Sourceยง

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Sourceยง

impl<T> Same for T

Sourceยง

type Output = T

Should always be Self
Sourceยง

impl<T> ToOwned for T
where T: Clone,

Sourceยง

type Owned = T

The resulting type after obtaining ownership.
Sourceยง

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Sourceยง

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Sourceยง

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Sourceยง

type Error = Infallible

The type returned in the event of a conversion error.
Sourceยง

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Sourceยง

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Sourceยง

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

The type returned in the event of a conversion error.
Sourceยง

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Sourceยง

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Sourceยง

fn vzip(self) -> V