Did you know ... Search Documentation:
Pack irc_client -- prolog/irc_client_parser.pl
PublicShow source

This module takes a message line relayed from an IRC server and parses it into a compound term that acts as an acceptable message type for the messages themselves. This is useful for manipulating, processing and acting on events in an IRC session.

Source : http://www.networksorcery.com/enp/protocol/irc.htm

Alternative Source : http://irchelp.org/irchelp/rfc/

CTCP : http://irchelp.org/irchelp/rfc/ctcpspec.html

Message syntax:

message = [ ":" prefix SPACE ] command [ params ] crlf

prefix = servername / ( nickname [ [ "!" user ] "@" host ])

command = 1*letter / 3digit

params = *14( SPACE middle ) [ SPACE ":" trailing ] =/ 14( SPACE middle ) [ SPACE [ ":" ] trailing ]

// Any byte except NUL, CR, LF, " " and ":".

nospcrlfcl = %x01-09 / %x0B-0C / %x0E-1F / %x21-39 / %x3B-FF

middle = nospcrlfcl *( ":" / nospcrlfcl )

trailing = *( ":" / " " / nospcrlfcl )

SPACE = %x20 ; Whitespace.

crlf = %x0D %x0A ; Carriage return/linefeed.

 prefix_id(+Prefix, -Servername) is semidet
Extract a servername from a msg prefix.
Arguments:
Prefix- A string (usually in message structure) that represents the prefix of the sender
Servername- The server name obtained from the sender's prefix
 prefix_id(+Prefix, -Nick, -User, -Host) is semidet
Extract the Nick, User, and Host portions of a prefix from a msg. All of these arguments are to take the form of a string type.

Undocumented predicates

The following predicates are exported, but not or incorrectly documented.

 parse_line(Arg1, Arg2)