Paul Evans > Net-Async-IRC-0.07 > Protocol::IRC::Client

Download:
Net-Async-IRC-0.07.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
View/Report Bugs
Module Version: 0.02   Source   Latest Release: Net-Async-IRC-0.09

NAME ^

Protocol::IRC::Client - IRC protocol handling for a client

DESCRIPTION ^

This mix-in class provides a layer of IRC message handling logic suitable for an IRC client. It builds upon Protocol::IRC to provide extra message processing useful to IRC clients, such as handling inbound server numerics.

It provides some of the methods required by Protocol::IRC:

METHODS ^

$value = $irc->isupport( $key )

Returns an item of information from the server's 005 ISUPPORT lines. Traditionally IRC servers use all-capital names for keys.

$info = $irc->server_info( $key )

Returns an item of information from the server's 004 line. $key should one of

INTERNAL MESSAGE HANDLING ^

The following messages are handled internally by Protocol::IRC::Client.

MODE (on channels) and 324 (RPL_CHANNELMODEIS)

These message involve channel modes. The raw list of channel modes is parsed into an array containing one entry per affected piece of data. Each entry will contain at least a type key, indicating what sort of mode or mode change it is:

list

The mode relates to a list; bans, invites, etc..

value

The mode sets a value about the channel

bool

The mode is a simple boolean flag about the channel

occupant

The mode relates to a user in the channel

Every mode type then provides a mode key, containing the mode character itself, and a sense key which is an empty string, +, or -.

For list and value types, the value key gives the actual list entry or value being set.

For occupant types, a flag key gives the mode converted into an occupant flag (by the prefix_mode2flag method), nick and nick_folded store the user name affected.

boolean types do not create any extra keys.

AUTHOR ^

Paul Evans <leonerd@leonerd.org.uk>

syntax highlighting: