Next: Introduction, Previous: (dir), Up: (dir) [Contents][Index]
This is the cl-irc Reference Manual, version 0.9.2, generated automatically by Declt version 4.0 beta 2 "William Riker" on Mon Aug 15 03:44:22 2022 GMT+0.
Next: Systems, Previous: The cl-irc Reference Manual, Up: The cl-irc Reference Manual [Contents][Index]
cl-irc: A Common Lisp interface to the client-part of the IRC protocol; RFCs 2810, 2811 and 2812. See doc/user-guide.txt for more information.
Next: Files, Previous: Introduction, Up: The cl-irc Reference Manual [Contents][Index]
The main system appears first, followed by any subsystem dependency.
Common Lisp interface to the IRC protocol
Erik Enge & Contributors
MIT
0.9.2
Next: Packages, Previous: Systems, Up: The cl-irc Reference Manual [Contents][Index]
Files are sorted by type and then listed depth-first from the systems components trees.
Next: cl-irc/package.lisp, Previous: Lisp, Up: Lisp [Contents][Index]
cl-irc (system).
Next: cl-irc/variable.lisp, Previous: cl-irc/cl-irc.asd, Up: Lisp [Contents][Index]
cl-irc (system).
Next: cl-irc/utility.lisp, Previous: cl-irc/package.lisp, Up: Lisp [Contents][Index]
package.lisp (file).
cl-irc (system).
Next: cl-irc/parse-message.lisp, Previous: cl-irc/variable.lisp, Up: Lisp [Contents][Index]
variable.lisp (file).
cl-irc (system).
Next: cl-irc/protocol.lisp, Previous: cl-irc/utility.lisp, Up: Lisp [Contents][Index]
utility.lisp (file).
cl-irc (system).
Next: cl-irc/command.lisp, Previous: cl-irc/parse-message.lisp, Up: Lisp [Contents][Index]
parse-message.lisp (file).
cl-irc (system).
Next: cl-irc/event.lisp, Previous: cl-irc/protocol.lisp, Up: Lisp [Contents][Index]
protocol.lisp (file).
cl-irc (system).
Previous: cl-irc/command.lisp, Up: Lisp [Contents][Index]
command.lisp (file).
cl-irc (system).
Next: Definitions, Previous: Files, Up: The cl-irc Reference Manual [Contents][Index]
Packages are listed by definition order.
Previous: cl-irc-system, Up: Packages [Contents][Index]
irc
common-lisp.
Next: Indexes, Previous: Packages, Up: The cl-irc Reference Manual [Contents][Index]
Definitions are sorted by export status, category, package, and then by lexicographic order.
Next: Internals, Previous: Definitions, Up: Definitions [Contents][Index]
Next: Ordinary functions, Previous: Public Interface, Up: Public Interface [Contents][Index]
Destructures the ‘arguments’ slot in ‘message’ according
to ‘lambda-list’ and binds them in ‘body’.
The lambda list syntax is as follows:
wholevar::= &whole var
reqvars::= var*
optvars::= [&optional {var | (var [init-form [supplied-p-parameter]])}* ]
restvar::= [&rest var]
reqtrailingvars::= [&req var*]
lambda-list::= (wholevar reqvars optvars restvar reqtrailingvars)
With the exception of &req (which is new) and &rest, all lambda list keywords are analogous to a destructuring lambda list (see clhs 3.4.5).
If &req is specified, these values are consumed off the end of the list
before processing any preceeding &optional or &rest keywords.
For any variable, the ‘:ignored’ keyword can be passed instead, indicating the binding should be ignored in the ‘body’.
Next: Generic functions, Previous: Macros, Up: Public Interface [Contents][Index]
Connect to server and return a connection object.
‘port’ and ‘connection-security’ have a relation: when ‘port’ equals ‘:default’ ‘*default-irc-server-port*’ is used to find which port to connect to. ‘connection-security’ determines which port number is found.
‘connection-security’ can be either ‘:none’ or ‘:ssl’. When passing ‘:ssl’, the cl+ssl library must have been loaded by the caller.
Numeric replies in the IRC RFCs have more meaningful names. Given a numeric reply (‘reply-number’) this function will either return the symbol representing the reply or raise a continuable error (‘no-such-reply’) which gives you the opportunity to ignore the situation.
Wildcard matching.
Uses ‘*’ to match any number of characters and ‘?’ to match exactly any one character. The routine does not enforce hostmask matching patterns, but can be used for the purpose.
Normalize ‘string’ so that it represents an all-downcased channel name.
Normalize ‘string’ so that represents an all-downcased IRC nickname.
Create a list of mode changes with their arguments for ‘target’
from ‘mode-string’ and ‘arguments’.
Throw nil to the UNKNOWN-MODE symbol if any of the mode chars are unknown.
Assuming ‘string’ is a valid IRC message, parse the message and
return the values in the following order:
- source
- user
- host
- command
- arguments
- trailing-argument
Any values not present will be represented as nil.
Read messages from the ‘connection’, parse them and dispatch irc-message-event on them. Returns background process ID if available.
This function has been DEPRECATED. The function body is meant as an
example for library users on handling connection input. Users
are strongly encouraged to implement error handling (which is lacking
from the prototype given here.
Stops a background message handler process returned by the start function.
Just as its cousin START-BACKGROUND-MESSAGE-HANDLER,
this function is DEPRECATED.
Next: Standalone methods, Previous: Ordinary functions, Up: Public Interface [Contents][Index]
Add ‘channel’ to ‘connection’.
Add ‘hook’ to ‘class’.
Add the mode-holding object ‘mode-value’ to ‘target’
under the access key ‘mode-name’.
If mode-value is a subtype of irc-mode, it is added as-is. Otherwise, a mode-object will be generated from the
Add ‘user’ to ‘connection’.
Append ‘hook’ to ‘class’.
automatically generated reader method
automatically generated writer method
automatically generated reader method
automatically generated writer method
automatically generated writer method
Input from the remote is sent to this stream.
Messages coming back from the server are sent to this stream.
Makes sure that the DCC connection is closed
as soon as either the IRC connection is actively closed or when
a lost connection is detected.
automatically generated reader method
automatically generated writer method
Returns t if ‘connection’ is connected to a server and is ready for input.
automatically generated reader method
automatically generated writer method
Initiate a DCC chat session with ‘nickname’ associated
with ‘connection’.
If ‘passive’ is non-NIL, the remote is requested to serve as a DCC host. Otherwise, the local system will serve as a DCC host. The latter may be a problem for firewalled or NATted hosts.
Upon receipt of an IRC message from the
connection’s stream, irc-message-event will be called with the
message.
Return channel as designated by ‘channel’. If no such channel can be found, return nil.
Return user as designated by ‘nickname’ or nil if no such user is known.
Return a list of all hooks for ‘class’.
Get the value associated with ‘mode’ for ‘target’ or ‘nil’ if no mode available.
Return a generalised boolean indicating if ‘target’ has a mode ‘mode’ associated with it.
Return a generalised boolean indicating if ‘target’ has
a mode ‘mode’ associated with the value ‘value’ for given a ‘key’ transform
and ‘test’ test.
automatically generated reader method
host.
automatically generated writer method
host.
The associated IRC connection used to send
CTCP control commands. When this connection is closed/lost,
the DCC connection should be terminated too for security reasons.
Upon receipt of an IRC message from the
connection’s stream, irc-message-event will be called with the
message.
automatically generated reader method
Stream used to talk binary to the IRC server.
automatically generated writer method
Stream used to talk binary to the IRC server.
Stream used to communicate with the other end of the network pipe.
Stream used to send messages to the IRC server
A "PASS" command is not required for a client connection to be
registered, but it MUST precede the latter of the NICK/USER
combination (for a user connection) or the SERVICE command (for a
service connection). The RECOMMENDED order for a client to register is
as follows:
1. Pass message
2. Nick message 2. Service message
3. User message
Upon success, the client will receive an RPL_WELCOME (for users) or RPL_YOURESERVICE (for services) message indicating that the connection is now registered and known the to the entire IRC network. The reply message MUST contain the full client identifier upon which it was registered.
automatically generated reader method
automatically generated writer method
automatically generated reader method
automatically generated reader method
automatically generated writer method
automatically generated writer method
Read and parse an IRC message from the ‘connection’.
automatically generated reader method
automatically generated reader method
automatically generated writer method
automatically generated writer method
The user at the other end of this connection. The
user at this end can be reached via your normal connection object.
Remove all channels known to ‘connection’.
Remove all users known to ‘connection’.
Remove ‘channel’ from ‘connection’.
Remove ‘hook’ from ‘class’.
Remove all hooks for ‘class’.
Remove the mode-holding object in the ‘mode-name’ key from ‘target’.
Remove ‘user’ from ‘connection’ but leave user in any channels he may be already be on.
Did we send this message?
automatically generated reader method
automatically generated writer method
automatically generated reader method
automatically generated writer method
Set the mode designated by the ‘mode’ keyword to a value passed in ‘parameter’ or T if ‘parameter’ is absent.
automatically generated reader method
automatically generated writer method
Sets value of the mode designated by the ‘mode’ keyword to nil.
If the mode holds a list of values ‘parameter’ is used to indicate which
element to remove.
automatically generated reader method
user.
automatically generated reader method
user.
automatically generated writer method
user.
automatically generated writer method
user.
May not represent the real number of users in the
channel. Rather, the number returned from the LIST command gets stuck
in there so the user of this library can use it for searching
channels, for instance. If the value is NIL then the slot has not
been populated by a LIST command.
automatically generated reader method
automatically generated writer method
automatically generated writer method
Next: Conditions, Previous: Generic functions, Up: Public Interface [Contents][Index]
Print the object for the Lisp reader.
Print the object for the Lisp reader.
Print the object for the Lisp reader.
Print the object for the Lisp reader.
Next: Classes, Previous: Standalone methods, Up: Public Interface [Contents][Index]
condition.
:reply-number
This slot is read-only.
Previous: Conditions, Up: Public Interface [Contents][Index]
:normalized-name
:topic
(quote nil)
:modes
(member nil :public :private :secret :unknown)
:visibility
(make-hash-table :test (function equal))
:users
May not represent the real number of users in the
channel. Rather, the number returned from the LIST command gets stuck
in there so the user of this library can use it for searching
channels, for instance. If the value is NIL then the slot has not
been populated by a LIST command.
:user-count
:password
"unknown server"
:server-name
cl-irc::*default-irc-server-port*
:server-port
Stream used to talk binary to the IRC server.
:network-stream
Stream used to send messages to the IRC server
:output-stream
Assoc array for rpl_isupport message;
see http://www.irc.org/tech_docs/draft-brocklesby-irc-isupport-03.txt
cl-irc::*default-isupport-values*
Messages coming back from the server are sent to this stream.
t
:client-stream
The DCC offers sent out in association with this connection.
(quote nil)
The DCC connections associated with this IRC connection.
(quote nil)
(make-hash-table :test (function equal))
:channels
(make-hash-table :test (function equal))
:hooks
Describes the modes an application intends to register with channels.
(cl-irc::chanmode-descs-from-isupport cl-irc::*default-isupport-values*)
:channel-mode-descriptions
(cl-irc::nick-prefixes-from-isupport cl-irc::*default-isupport-values*)
:nick-prefixes
Describes the modes an application intends to register with channels.
(mapcar (function (lambda (cl-irc::x) (cl-irc::make-mode-description :char (car cl-irc::x) :symbol (cdr cl-irc::x)))) cl-irc::*char-to-user-modes-map*)
:user-mode-descriptions
(make-hash-table :test (function equal))
:users
Abstract superclass of all types of DCC connections.
This class isn’t meant to be instanciated. The different DCC subprotocols differ widely in the way they transmit their data, meaning there are relatively few methods which can be defined for this class. They do share a number of properties though.
The associated IRC connection used to send
CTCP control commands. When this connection is closed/lost,
the DCC connection should be terminated too for security reasons.
:irc-connection
Makes sure that the DCC connection is closed
as soon as either the IRC connection is actively closed or when
a lost connection is detected.
t
:close-on-main
The user at the other end of this connection. The
user at this end can be reached via your normal connection object.
:remote-user
:network-stream
Input from the remote is sent to this stream.
:client-stream
:connection
list
:arguments
:received-time
string
:raw-message-string
string
:source
string
:command
list
:arguments
:connection
:received-time
string
:raw-message-string
""
:nickname
""
:normalized-nickname
""
:username
""
:hostname
""
:realname
(quote nil)
:modes
:channels
Previous: Public Interface, Up: Definitions [Contents][Index]
Next: Special variables, Previous: Internals, Up: Internals [Contents][Index]
The external-formats we use to decode incoming messages. This should
be a list of external format specs that flexi-streams accepts.
The external formats are tried in order, until one decodes the
message without encoding errors. Note that the last external
format should be a single-byte one with most or even all valid
codepoints (such as latin-1).
:eol-style will always be overridden to be :crlf as required by the IRC protocol.
The external-format we use to encode outgoing messages. This should be an external format spec that flexi-streams accepts.
:eol-style will always be overridden to be :crlf as required by the IRC protocol.
A function of two arguments, called with the related irc connection
object and the protocol message string upon detection of an unmappable
response code.
The function should return a valid IRC-MESSAGE class or NIL.
The parameter can be NIL to disable the hook.
Next: Ordinary functions, Previous: Special variables, Up: Internals [Contents][Index]
Next: Generic functions, Previous: Macros, Up: Internals [Contents][Index]
Parses a string describing channel modes conforming to
http://www.irc.org/tech_docs/draft-brocklesby-irc-isupport-03.txt
paragraph 3.3.
It returns a list of mode-description records.
If ‘string’ is a valid IRC message parse it and return an object of the correct type with its slots prefilled according to the information in the message.
If ‘string’ is a CTCP message, return the type of the message or nil if this is a) not a CTCP message or b) a CTCP message we don’t know about.
Is the ‘string’ actually a representation of the CTCP ‘type’?
Cut ‘string’ before ‘substring’ or any of the ‘end-chars’, from ‘start’,
if none of substring or end-chars are found, until the end of the string
when ‘cut-to-end’ is true.
If ‘cut-extra’ is t, we will cut from start + 1 instead of just
‘start’.
When there is no string matching the input parameters ‘start’ and nil will be returned, otherwise ‘end-position’ and the string are returned.
If ‘start-char’ is not nil, cut string between ‘start-char’ and any
of the ‘end-chars’, from ‘start’. If ‘start-char’ is nil, cut from
‘start’ until any of the ‘end-chars’ (or sting-end when ‘cut-to-end’ is true).
If ‘cut-extra’ is t, we will cut from start + 1 instead of just
‘start’.
When there is no string matching the input parameters ‘start’ and nil
will be returned, otherwise ‘end-position’ and the string are
returned.
Is the ‘string’ actually a representation of the DCC ‘type’?
Given a number, such as 1, return the appropriate day name, abbrevated, such as "Tue". Index 0 is Monday.
Index 1 is January.
Host-byte-order integer to dotted-quad string conversion utility.
Host-byte-order integer to dotted-quad string conversion utility.
Convert a string, such as 192.168.1.1, to host-byte-order, such as 3232235777.
Intern based on symbol-name to support case-sensitive mlisp
Returns t if ‘string’ is a string-representation of an IRC error reply message, nil otherwise.
Take a list of strings and return a new list of integers (from parse-integer) on each of the string elements.
Return a valid IRC CTCP message, as a string, composed by ‘string’.
Return a valid IRC message, as a string, composed of the input parameters.
Returns a string composed of the input parameters so that it represents a time message as by the IRC protocol.
char.
Returns an assoc list associating prefix characters with mode characters.
Returns t if ‘string’ is a string-representation of an IRC number reply, nil otherwise.
Reads a line from the input network stream, returning a character array with the input read.
Reads data from ‘stream’ into ‘target’ until the subsequence ‘limit’ is reached or ‘target’ is not large enough to hold the data.
Assuming ‘string’ is a valid IRC message this function returns the arguments part of the message as a list. Returns nil if the arguments part is not present.
Assuming ‘string’ is a valid IRC message this function returns the command part of the message. Returns nil if the command part is not present.
Assuming ‘string’ is a valid IRC message this function returns the host part of the message. Returns nil if the host part is not present.
Assuming ‘string’ is a valid IRC message this function returns the source part of the message. Returns nil if the source part is not present.
Assuming ‘string’ is a valid IRC message this function returns the trailing-argument part of the message. Returns nil if the trailing-argument part is not present.
Assuming ‘string’ is a valid IRC message this function returns the user part of the message. Returns nil if the user part is not present.
Internal helper for the DEPRECATED function START-BACKGROUND-MESSAGE-HANDLER and therefore DEPRECATED itself.
Split string into a list, splitting on ‘delimiters’ and removing any empty subsequences.
Next: Structures, Previous: Ordinary functions, Up: Internals [Contents][Index]
Applies any applicable hooks to ‘message’.
Returns non-nil if any of the hooks do.
Describes the modes an application intends to register with channels.
automatically generated reader method
automatically generated writer method
Adds an offer to the list off outstanding offers list for ‘connection’.
The DCC connections associated with this IRC connection.
The DCC offers sent out in association with this connection.
Remove an offer from the list of outstanding offers for ‘connection’.
Minimum action to be executed upon reception
of the IRC message to keep the connection, channel and user
objects in sync.
automatically generated reader method
automatically generated reader method
automatically generated writer method
automatically generated writer method
Retrieve a ‘mode-description’ structure for the given ‘mode-name’ keyword.
Map the mode character used in the MODE message to a symbol used internally to describe the mode given a ‘target’.
automatically generated reader method
automatically generated writer method
Remove ‘user’ anywhere present in the ‘connection’.
Turn the arguments into a valid IRC message and send it to the server, via the ‘connection’.
Assoc array for rpl_isupport message;
see http://www.irc.org/tech_docs/draft-brocklesby-irc-isupport-03.txt
Describes the modes an application intends to register with channels.
Next: Classes, Previous: Generic functions, Up: Internals [Contents][Index]
structure-object.
common-lisp.
common-lisp.
common-lisp.
(quote cl-irc:single-value-mode)
Previous: Structures, Up: Internals [Contents][Index]
:ctcp-command
Previous: Definitions, Up: The cl-irc Reference Manual [Contents][Index]
Jump to: | (
A B C D E F G H I J K L M N O P Q R S T U V W |
---|