📄 event.pm
字号:
430 => "nonickchanges", # Yet Another Undocumented Austnet Extension, Andypoo 431 => "nonicknamegiven", 432 => "erroneusnickname", # This iz how its speld in thee RFC. 433 => "nicknameinuse", 436 => "nickcollision", 437 => "bannickchange", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 438 => "nicktoofast", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 439 => "targettoofast", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 441 => "usernotinchannel", 442 => "notonchannel", 443 => "useronchannel", 444 => "nologin", 445 => "summondisabled", 446 => "usersdisabled", 451 => "notregistered", 461 => "needmoreparams", 462 => "alreadyregistered", 463 => "nopermforhost", 464 => "passwdmismatch", 465 => "yourebannedcreep", # I love this one... 466 => "youwillbebanned", 467 => "keyset", 468 => "invalidusername", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 471 => "channelisfull", 472 => "unknownmode", 473 => "inviteonlychan", 474 => "bannedfromchan", 475 => "badchannelkey", 476 => "badchanmask", 478 => "banlistfull", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 481 => "noprivileges", 482 => "chanoprivsneeded", 483 => "cantkillserver", 484 => "ischanservice", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 491 => "nooperhost", 492 => "noservicehost", 501 => "umodeunknownflag", 502 => "usersdontmatch", 511 => "silelistfull", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 513 => "nosuchgline", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 513 => "badping", # Undernet Extension, Kajetan@Hinner.com, 17/10/98 );1;__END__=head1 NAMENet::IRC::Event - A class for passing event data between subroutines=head1 SYNOPSISNone yet. These docs are under construction.=head1 DESCRIPTIONThis documentation is a subset of the main Net::IRC documentation. Ifyou haven't already, please "perldoc Net::IRC" before continuing.Net::IRC::Event defines a standard interface to the salient information forjust about any event your client may witness on IRC. It's about as close aswe can get in Perl to a struct, with a few extra nifty features thrown in.=head1 METHOD DESCRIPTIONSThis section is under construction, but hopefully will be finally written upby the next release. Please see the C<irctest> script and the source fordetails about this module.=head1 LIST OF EVENTSNet::IRC is an entirely event-based system, which takes some getting used toat first. To interact with the IRC server, you tell Net::IRC's serverconnection to listen for certain events and activate your own subroutines whenthey occur. Problem is, this doesn't help you much if you don't know what totell it to look for. Below is a list of the possible events you can pass toNet::IRC, along with brief descriptions of each... hope this helps.=head2 Common events=over=item *nickThe "nick" event is triggered when the client receives a NICK message, meaningthat someone on a channel with the client has changed eir nickname.=item *quitThe "quit" event is triggered upon receipt of a QUIT message, which means thatsomeone on a channel with the client has disconnected.=item *joinThe "join" event is triggered upon receipt of a JOIN message, which means thatsomeone has entered a channel that the client is on.=item *partThe "part" event is triggered upon receipt of a PART message, which means thatsomeone has left a channel that the client is on.=item *modeThe "mode" event is triggered upon receipt of a MODE message, which means thatsomeone on a channel with the client has changed the channel's parameters.=item *topicThe "topic" event is triggered upon receipt of a TOPIC message, which meansthat someone on a channel with the client has changed the channel's topic.=item *kickThe "kick" event is triggered upon receipt of a KICK message, which means thatsomeone on a channel with the client (or possibly the client itself!) has beenforcibly ejected.=item *publicThe "public" event is triggered upon receipt of a PRIVMSG message to an entirechannel, which means that someone on a channel with the client has saidsomething aloud.=item *msgThe "msg" event is triggered upon receipt of a PRIVMSG message which isaddressed to one or more clients, which means that someone is sending theclient a private message. (Duh. :-)=item *noticeThe "notice" event is triggered upon receipt of a NOTICE message, which meansthat someone has sent the client a public or private notice. (Is thatsufficiently vague?)=item *pingThe "ping" event is triggered upon receipt of a PING message, which means thatthe IRC server is querying the client to see if it's alive. Don't confuse thiswith CTCP PINGs, explained later.=item *otherThe "other" event is triggered upon receipt of any number of unclassifiablemiscellaneous messages, but you're not likely to see it often.=item *inviteThe "invite" event is triggered upon receipt of an INVITE message, which meansthat someone is permitting the client's entry into a +i channel.=item *killThe "kill" event is triggered upon receipt of a KILL message, which means thatan IRC operator has just booted your sorry arse offline. Seeya!=item *disconnectThe "disconnect" event is triggered when the client loses itsconnection to the IRC server it's talking to. Don't confuse it withthe "leaving" event. (See below.)=item *leavingThe "leaving" event is triggered just before the client deliberatelycloses a connection to an IRC server, in case you want to do anythingspecial before you sign off.=item *umodeThe "umode" event is triggered when the client changes its personal mode flags.=item *errorThe "error" event is triggered when the IRC server complains to you aboutanything. Sort of the evil twin to the "other" event, actually.=back=head2 CTCP Requests=over=item *cpingThe "cping" event is triggered when the client receives a CTCP PING requestfrom another user. See the irctest script for an example of how to properlyrespond to this common request.=item *cversionThe "cversion" event is triggered when the client receives a CTCP VERSIONrequest from another client, asking for version info about its IRC clientprogram.=item *csourceThe "csource" event is triggered when the client receives a CTCP SOURCErequest from another client, asking where it can find the source to itsIRC client program.=item *ctimeThe "ctime" event is triggered when the client receives a CTCP TIMErequest from another client, asking for the local time at its end.=item *cdccThe "cdcc" event is triggered when the client receives a DCC request of anysort from another client, attempting to establish a DCC connection.=item *cuserinfoThe "cuserinfo" event is triggered when the client receives a CTCP USERINFOrequest from another client, asking for personal information from the client'suser.=item *cclientinfoThe "cclientinfo" event is triggered when the client receives a CTCP CLIENTINFOrequest from another client, asking for whatever the hell "clientinfo" means.=item *cerrmsgThe "cerrmsg" event is triggered when the client receives a CTCP ERRMSGrequest from another client, notifying it of a protocol error in a precedingCTCP communication.=item *cfingerThe "cfinger" event is triggered when the client receives a CTCP FINGERrequest from another client. How to respond to this should best be left upto your own moral stance.=item *cactionThe "caction" event is triggered when the client receives a CTCP ACTIONmessage from another client. I should hope you're getting the hang of howNet::IRC handles CTCP requests by now...=back=head2 CTCP Responses=over=item *crpingThe "crping" event is triggered when the client receives a CTCP PING responsefrom another user. See the irctest script for an example of how to properlyrespond to this common event.=item *crversionThe "crversion" event is triggered when the client receives a CTCP VERSIONresponse from another client.=item *crsourceThe "crsource" event is triggered when the client receives a CTCP SOURCEresponse from another client.=item *crtimeThe "crtime" event is triggered when the client receives a CTCP TIMEresponse from another client.=item *cruserinfoThe "cruserinfo" event is triggered when the client receives a CTCP USERINFOresponse from another client.=item *crclientinfoThe "crclientinfo" event is triggered when the client receives a CTCPCLIENTINFO response from another client.=item *crfingerThe "crfinger" event is triggered when the client receives a CTCP FINGERresponse from another client. I'm not even going to consider making a jokeabout this one.=back=head2 DCC Events=over=item *dcc_openThe "dcc_open" event is triggered when a DCC connection is established betweenthe client and another client.=item *dcc_updateThe "dcc_update" event is triggered when any data flows over a DCC connection.Useful for doing things like monitoring file transfer progress, for instance.=item *dcc_closeThe "dcc_close" event is triggered when a DCC connection closes, whether froman error or from natural causes.=item *chatThe "chat" event is triggered when the person on the other end of a DCC CHATconnection sends you a message. Think of it as the private equivalent of "msg",if you will.=back=head2 Numeric Events=over=item *There's a whole lot of them, and they're well-described elsewhere. Please seethe IRC RFC (1495, at http://cs-ftp.bu.edu/pub/irc/support/IRC_RFC ) for adetailed description, or the Net::IRC::Event.pm source code for a quick list.=back=head1 AUTHORSConceived and initially developed by Greg Bacon E<lt>gbacon@adtran.comE<gt> andDennis Taylor E<lt>dennis@funkplanet.comE<gt>.Ideas and large amounts of code donated by Nat "King" Torkington E<lt>gnat@frii.comE<gt>.Currently being hacked on, hacked up, and worked over by the members of theNet::IRC developers mailing list. For details, seehttp://www.execpc.com/~corbeau/irc/list.html .=head1 URLUp-to-date source and information about the Net::IRC project can be found athttp://netirc.betterbox.net/ .=head1 SEE ALSO=over=item *perl(1).=item *RFC 1459: The Internet Relay Chat Protocol=item *http://www.irchelp.org/, home of fine IRC resources.=back=cut
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -