[REBOL] IRC Protocol (I give up ) Re:(6)
From: peoyli:algonet:se at: 8-Sep-2000 15:14
> Is this line "prefix: make object! [full: nick: user: host: string!]"
> supposed to be replaced with the actual nick user and host portions or is
> this proper syntax!
>
> Paul Tretter
>
I use this object to store a parsed RAW line from the IRC server (a
call to a parse-irc-str function I wrote for this purpose).
'full' contains the whole prefix from the string sent by the server, and
the rest of the prefix object contains the actual parts of the prefix.
>From the RFC:
Each IRC message may consist of up to three main parts: the prefix
(optional), the command, and the command parameters (of which there
may be up to 15). The prefix, command, and all parameters are
separated by one (or more) ASCII space character(s) (0x20).
The presence of a prefix is indicated with a single leading ASCII
colon character (':', 0x3b), which must be the first character of the
message itself.
...
<message> ::= [':' <prefix> <SPACE> ] <command> <params> <crlf>
<prefix> ::= <servername> | <nick> [ '!' <user> ] [ ['--'] <host> ]
It could be nice to have a REBOL function to actually parse (any)
whole 'pseudo' BNF formatted description..
/PeO