mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-27 13:09:23 +01:00
Refresh autogen docs
This commit is contained in:
parent
6b40c97a75
commit
ce95e15897
@ -23,15 +23,17 @@ Here be dragons.</tt></p>
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="hashlib.html">hashlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<a href="logging.html">logging</a><br>
|
||||
<a href="os.html">os</a><br>
|
||||
</td><td width="25%" valign=top><a href="socket.html">socket</a><br>
|
||||
</td><td width="25%" valign=top><a href="os.html">os</a><br>
|
||||
<a href="socket.html">socket</a><br>
|
||||
<a href="ssl.html">ssl</a><br>
|
||||
</td><td width="25%" valign=top><a href="structures.html">structures</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
</td><td width="25%" valign=top><a href="threading.html">threading</a><br>
|
||||
<a href="time.html">time</a><br>
|
||||
<a href="threading.html">threading</a><br>
|
||||
</td><td width="25%" valign=top><a href="time.html">time</a><br>
|
||||
<a href="utils.html">utils</a><br>
|
||||
</td><td width="25%" valign=top><a href="world.html">world</a><br>
|
||||
<a href="world.html">world</a><br>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ee77aa">
|
||||
@ -43,7 +45,8 @@ Here be dragons.</tt></p>
|
||||
<dt><font face="helvetica, arial"><a href="builtins.html#Exception">builtins.Exception</a>(<a href="builtins.html#BaseException">builtins.BaseException</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="classes.html#ProtocolError">ProtocolError</a>
|
||||
<dt><font face="helvetica, arial"><a href="classes.html#NotAuthenticatedError">NotAuthenticatedError</a>
|
||||
</font></dt><dt><font face="helvetica, arial"><a href="classes.html#ProtocolError">ProtocolError</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
<dt><font face="helvetica, arial"><a href="builtins.html#object">builtins.object</a>
|
||||
@ -83,12 +86,11 @@ Here be dragons.</tt></p>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="FakeIRC-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Runs the connect loop for the IRC <a href="builtins.html#object">object</a>. This is usually called by<br>
|
||||
__init__ in a separate thread to allow multiple concurrent connections.</tt></dd></dl>
|
||||
<dl><dt><a name="FakeIRC-connect"><strong>connect</strong></a>(self)</dt></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-run"><strong>run</strong></a>(self, data)</dt><dd><tt>Queues a message to the fake IRC server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-send"><strong>send</strong></a>(self, data)</dt><dd><tt>Sends raw text to the uplink server.</tt></dd></dl>
|
||||
<dl><dt><a name="FakeIRC-send"><strong>send</strong></a>(self, data)</dt></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-takeCommands"><strong>takeCommands</strong></a>(self, msgs)</dt><dd><tt>Returns a list of commands parsed from the output of <a href="#FakeIRC-takeMsgs">takeMsgs</a>().</tt></dd></dl>
|
||||
|
||||
@ -104,15 +106,27 @@ Methods inherited from <a href="classes.html#Irc">Irc</a>:<br>
|
||||
(a string), the name of the protocol module to use for this connection,<br>
|
||||
and a configuration <a href="builtins.html#object">object</a>.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-__repr__"><strong>__repr__</strong></a>(self)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
<dl><dt><a name="FakeIRC-__repr__"><strong>__repr__</strong></a>(self)</dt></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-applyModes"><strong>applyModes</strong></a>(self, target, changedmodes)</dt><dd><tt>Takes a list of parsed IRC modes, and applies them on the given target.<br>
|
||||
<br>
|
||||
The target can be either a channel or a user; this is handled automatically.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-callCommand"><strong>callCommand</strong></a>(self, source, text)</dt><dd><tt>Calls a PyLink bot command. source is the caller's UID, and text is the<br>
|
||||
full, unparsed text of the message.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-callHooks"><strong>callHooks</strong></a>(self, hook_args)</dt><dd><tt>Calls a hook function with the given hook args.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-checkAuthenticated"><strong>checkAuthenticated</strong></a>(self, uid, allowAuthed=True, allowOper=True)</dt><dd><tt>Checks whether the given user has operator status on PyLink, raising<br>
|
||||
<a href="#NotAuthenticatedError">NotAuthenticatedError</a> and logging the access denial if not.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-disconnect"><strong>disconnect</strong></a>(self)</dt><dd><tt>Handle disconnects from the remote server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-getHostmask"><strong>getHostmask</strong></a>(self, user, realhost=False, ip=False)</dt><dd><tt>Returns the hostmask of the given user, if present. If the realhost option<br>
|
||||
is given, return the real host of the user instead of the displayed host.<br>
|
||||
If the ip option is given, return the IP address of the user (this overrides<br>
|
||||
realhost).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-getServer"><strong>getServer</strong></a>(self, numeric)</dt><dd><tt>Finds the SID of the server a user is on.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-initVars"><strong>initVars</strong></a>(self)</dt><dd><tt>(Re)sets an IRC <a href="builtins.html#object">object</a> to its default state. This should be called when<br>
|
||||
@ -123,6 +137,17 @@ returning the SID of the server it's on
|
||||
|
||||
<dl><dt><a name="FakeIRC-isInternalServer"><strong>isInternalServer</strong></a>(self, sid)</dt><dd><tt>Returns whether the given SID is an internal PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-isManipulatableClient"><strong>isManipulatableClient</strong></a>(self, uid)</dt><dd><tt>Returns whether the given user is marked as an internal, manipulatable<br>
|
||||
client. Usually, automatically spawned services clients should have this<br>
|
||||
set True to prevent interactions with opers (like mode changes) from<br>
|
||||
causing desyncs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-isOper"><strong>isOper</strong></a>(self, uid, allowAuthed=True, allowOper=True)</dt><dd><tt>Returns whether the given user has operator status on PyLink. This can be achieved<br>
|
||||
by either identifying to PyLink as admin (if allowAuthed is True),<br>
|
||||
or having user mode +o set (if allowOper is True). At least one of<br>
|
||||
allowAuthed or allowOper must be True for this to give any meaningful<br>
|
||||
results.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-logSetup"><strong>logSetup</strong></a>(self)</dt><dd><tt>Initializes any channel loggers defined for the current network.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-msg"><strong>msg</strong></a>(self, target, text, notice=False, source=None)</dt><dd><tt>Handy function to send messages/notices to clients. Source<br>
|
||||
@ -130,14 +155,43 @@ is optional, and defaults to the main PyLink&
|
||||
|
||||
<dl><dt><a name="FakeIRC-nickToUid"><strong>nickToUid</strong></a>(self, nick)</dt><dd><tt>Looks up the UID of a user with the given nick, if one is present.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-parseModes"><strong>parseModes</strong></a>(self, target, args)</dt><dd><tt>Parses a modestring list into a list of (mode, argument) tuples.<br>
|
||||
['+mitl-o', '3', 'person'] => [('+m', None), ('+i', None), ('+t', None), ('+l', '3'), ('-o', 'person')]</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-reply"><strong>reply</strong></a>(self, text, notice=False, source=None)</dt><dd><tt>Replies to the last caller in the right context (channel or PM).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-reverseModes"><strong>reverseModes</strong></a>(self, target, modes, oldobj=None)</dt><dd><tt>Reverses/Inverts the mode string or mode list given.<br>
|
||||
<br>
|
||||
Optionally, an oldobj argument can be given to look at an earlier state of<br>
|
||||
a channel/user <a href="builtins.html#object">object</a>, e.g. for checking the op status of a mode setter<br>
|
||||
before their modes are processed and added to the channel state.<br>
|
||||
<br>
|
||||
This function allows both mode strings or mode lists. Example uses:<br>
|
||||
"+mi-lk test => "-mi+lk test"<br>
|
||||
"mi-k test => "-mi+k test"<br>
|
||||
[('+m', None), ('+r', None), ('+l', '3'), ('-o', 'person')<br>
|
||||
=> {('-m', None), ('-r', None), ('-l', None), ('+o', 'person')})<br>
|
||||
{('s', None), ('+o', 'whoever') => {('-s', None), ('-o', 'whoever')})</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-runline"><strong>runline</strong></a>(self, line)</dt><dd><tt>Sends a command to the protocol module.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-schedulePing"><strong>schedulePing</strong></a>(self)</dt><dd><tt>Schedules periodic pings in a loop.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-spawnMain"><strong>spawnMain</strong></a>(self)</dt><dd><tt>Spawns the main PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-toLower"><strong>toLower</strong></a>(self, text)</dt><dd><tt>Returns a lowercase representation of text based on the IRC <a href="builtins.html#object">object</a>'s<br>
|
||||
casemapping (rfc1459 or ascii).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="FakeIRC-version"><strong>version</strong></a>(self)</dt><dd><tt>Returns a detailed version string including the PyLink daemon version,<br>
|
||||
the protocol module in use, and the server hostname.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Static methods inherited from <a href="classes.html#Irc">Irc</a>:<br>
|
||||
<dl><dt><a name="FakeIRC-joinModes"><strong>joinModes</strong></a>(modes)</dt><dd><tt>Takes a list of (mode, arg) tuples in <a href="#FakeIRC-parseModes">parseModes</a>() format, and<br>
|
||||
joins them into a string.<br>
|
||||
<br>
|
||||
See testJoinModes in tests/test_utils.py for some examples.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="classes.html#Irc">Irc</a>:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
@ -176,7 +230,7 @@ Data and other attributes defined here:<br>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="classes.html#Protocol">Protocol</a>:<br>
|
||||
<dl><dt><a name="FakeProto-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="FakeProto-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="FakeProto-parseArgs"><strong>parseArgs</strong></a>(self, args)</dt><dd><tt>Parses a string of <a href="http://www.rfc-editor.org/rfc/rfc1459.txt">RFC1459</a>-style arguments split into a list, where ":" may<br>
|
||||
be used for multi-word arguments that last until the end of a line.</tt></dd></dl>
|
||||
@ -208,18 +262,30 @@ Data descriptors inherited from <a href="classes.html#Protocol">Protocol</a>:<br
|
||||
(a string), the name of the protocol module to use for this connection,<br>
|
||||
and a configuration <a href="builtins.html#object">object</a>.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-__repr__"><strong>__repr__</strong></a>(self)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
<dl><dt><a name="Irc-__repr__"><strong>__repr__</strong></a>(self)</dt></dl>
|
||||
|
||||
<dl><dt><a name="Irc-applyModes"><strong>applyModes</strong></a>(self, target, changedmodes)</dt><dd><tt>Takes a list of parsed IRC modes, and applies them on the given target.<br>
|
||||
<br>
|
||||
The target can be either a channel or a user; this is handled automatically.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-callCommand"><strong>callCommand</strong></a>(self, source, text)</dt><dd><tt>Calls a PyLink bot command. source is the caller's UID, and text is the<br>
|
||||
full, unparsed text of the message.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-callHooks"><strong>callHooks</strong></a>(self, hook_args)</dt><dd><tt>Calls a hook function with the given hook args.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-checkAuthenticated"><strong>checkAuthenticated</strong></a>(self, uid, allowAuthed=True, allowOper=True)</dt><dd><tt>Checks whether the given user has operator status on PyLink, raising<br>
|
||||
<a href="#NotAuthenticatedError">NotAuthenticatedError</a> and logging the access denial if not.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Runs the connect loop for the IRC <a href="builtins.html#object">object</a>. This is usually called by<br>
|
||||
__init__ in a separate thread to allow multiple concurrent connections.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-disconnect"><strong>disconnect</strong></a>(self)</dt><dd><tt>Handle disconnects from the remote server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-getHostmask"><strong>getHostmask</strong></a>(self, user, realhost=False, ip=False)</dt><dd><tt>Returns the hostmask of the given user, if present. If the realhost option<br>
|
||||
is given, return the real host of the user instead of the displayed host.<br>
|
||||
If the ip option is given, return the IP address of the user (this overrides<br>
|
||||
realhost).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-getServer"><strong>getServer</strong></a>(self, numeric)</dt><dd><tt>Finds the SID of the server a user is on.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-initVars"><strong>initVars</strong></a>(self)</dt><dd><tt>(Re)sets an IRC <a href="builtins.html#object">object</a> to its default state. This should be called when<br>
|
||||
@ -230,6 +296,17 @@ returning the SID of the server it's on
|
||||
|
||||
<dl><dt><a name="Irc-isInternalServer"><strong>isInternalServer</strong></a>(self, sid)</dt><dd><tt>Returns whether the given SID is an internal PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-isManipulatableClient"><strong>isManipulatableClient</strong></a>(self, uid)</dt><dd><tt>Returns whether the given user is marked as an internal, manipulatable<br>
|
||||
client. Usually, automatically spawned services clients should have this<br>
|
||||
set True to prevent interactions with opers (like mode changes) from<br>
|
||||
causing desyncs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-isOper"><strong>isOper</strong></a>(self, uid, allowAuthed=True, allowOper=True)</dt><dd><tt>Returns whether the given user has operator status on PyLink. This can be achieved<br>
|
||||
by either identifying to PyLink as admin (if allowAuthed is True),<br>
|
||||
or having user mode +o set (if allowOper is True). At least one of<br>
|
||||
allowAuthed or allowOper must be True for this to give any meaningful<br>
|
||||
results.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-logSetup"><strong>logSetup</strong></a>(self)</dt><dd><tt>Initializes any channel loggers defined for the current network.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-msg"><strong>msg</strong></a>(self, target, text, notice=False, source=None)</dt><dd><tt>Handy function to send messages/notices to clients. Source<br>
|
||||
@ -237,8 +314,24 @@ is optional, and defaults to the main PyLink&
|
||||
|
||||
<dl><dt><a name="Irc-nickToUid"><strong>nickToUid</strong></a>(self, nick)</dt><dd><tt>Looks up the UID of a user with the given nick, if one is present.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-parseModes"><strong>parseModes</strong></a>(self, target, args)</dt><dd><tt>Parses a modestring list into a list of (mode, argument) tuples.<br>
|
||||
['+mitl-o', '3', 'person'] => [('+m', None), ('+i', None), ('+t', None), ('+l', '3'), ('-o', 'person')]</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-reply"><strong>reply</strong></a>(self, text, notice=False, source=None)</dt><dd><tt>Replies to the last caller in the right context (channel or PM).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-reverseModes"><strong>reverseModes</strong></a>(self, target, modes, oldobj=None)</dt><dd><tt>Reverses/Inverts the mode string or mode list given.<br>
|
||||
<br>
|
||||
Optionally, an oldobj argument can be given to look at an earlier state of<br>
|
||||
a channel/user <a href="builtins.html#object">object</a>, e.g. for checking the op status of a mode setter<br>
|
||||
before their modes are processed and added to the channel state.<br>
|
||||
<br>
|
||||
This function allows both mode strings or mode lists. Example uses:<br>
|
||||
"+mi-lk test => "-mi+lk test"<br>
|
||||
"mi-k test => "-mi+k test"<br>
|
||||
[('+m', None), ('+r', None), ('+l', '3'), ('-o', 'person')<br>
|
||||
=> {('-m', None), ('-r', None), ('-l', None), ('+o', 'person')})<br>
|
||||
{('s', None), ('+o', 'whoever') => {('-s', None), ('-o', 'whoever')})</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-run"><strong>run</strong></a>(self)</dt><dd><tt>Main IRC loop which listens for messages.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-runline"><strong>runline</strong></a>(self, line)</dt><dd><tt>Sends a command to the protocol module.</tt></dd></dl>
|
||||
@ -249,6 +342,19 @@ is optional, and defaults to the main PyLink&
|
||||
|
||||
<dl><dt><a name="Irc-spawnMain"><strong>spawnMain</strong></a>(self)</dt><dd><tt>Spawns the main PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-toLower"><strong>toLower</strong></a>(self, text)</dt><dd><tt>Returns a lowercase representation of text based on the IRC <a href="builtins.html#object">object</a>'s<br>
|
||||
casemapping (rfc1459 or ascii).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="Irc-version"><strong>version</strong></a>(self)</dt><dd><tt>Returns a detailed version string including the PyLink daemon version,<br>
|
||||
the protocol module in use, and the server hostname.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Static methods defined here:<br>
|
||||
<dl><dt><a name="Irc-joinModes"><strong>joinModes</strong></a>(modes)</dt><dd><tt>Takes a list of (mode, arg) tuples in <a href="#Irc-parseModes">parseModes</a>() format, and<br>
|
||||
joins them into a string.<br>
|
||||
<br>
|
||||
See testJoinModes in tests/test_utils.py for some examples.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
@ -267,9 +373,9 @@ Data descriptors defined here:<br>
|
||||
<td colspan=2><tt>PyLink IRC channel class.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="IrcChannel-__init__"><strong>__init__</strong></a>(self, name=None)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="IrcChannel-__init__"><strong>__init__</strong></a>(self, name=None)</dt></dl>
|
||||
|
||||
<dl><dt><a name="IrcChannel-__repr__"><strong>__repr__</strong></a>(self)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
<dl><dt><a name="IrcChannel-__repr__"><strong>__repr__</strong></a>(self)</dt></dl>
|
||||
|
||||
<dl><dt><a name="IrcChannel-deepcopy"><strong>deepcopy</strong></a>(self)</dt><dd><tt>Returns a deep copy of the channel <a href="builtins.html#object">object</a>.</tt></dd></dl>
|
||||
|
||||
@ -320,9 +426,9 @@ name: The name of the server.<br>
|
||||
internal: Whether the server is an internal PyLink PseudoServer.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="IrcServer-__init__"><strong>__init__</strong></a>(self, uplink, name, internal=False, desc='(None given)')</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="IrcServer-__init__"><strong>__init__</strong></a>(self, uplink, name, internal=False, desc='(None given)')</dt></dl>
|
||||
|
||||
<dl><dt><a name="IrcServer-__repr__"><strong>__repr__</strong></a>(self)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
<dl><dt><a name="IrcServer-__repr__"><strong>__repr__</strong></a>(self)</dt></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
@ -342,9 +448,9 @@ Data descriptors defined here:<br>
|
||||
<td colspan=2><tt>PyLink IRC user class.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="IrcUser-__init__"><strong>__init__</strong></a>(self, nick, ts, uid, ident='null', host='null', realname='PyLink dummy client', realhost='null', ip='0.0.0.0', manipulatable=False)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="IrcUser-__init__"><strong>__init__</strong></a>(self, nick, ts, uid, ident='null', host='null', realname='PyLink dummy client', realhost='null', ip='0.0.0.0', manipulatable=False, opertype='IRC Operator')</dt></dl>
|
||||
|
||||
<dl><dt><a name="IrcUser-__repr__"><strong>__repr__</strong></a>(self)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
<dl><dt><a name="IrcUser-__repr__"><strong>__repr__</strong></a>(self)</dt></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
@ -358,13 +464,75 @@ Data descriptors defined here:<br>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="NotAuthenticatedError">class <strong>NotAuthenticatedError</strong></a>(<a href="builtins.html#Exception">builtins.Exception</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt><a href="builtins.html#Exception">Exception</a> raised by checkAuthenticated() when a user fails authentication<br>
|
||||
requirements.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="classes.html#NotAuthenticatedError">NotAuthenticatedError</a></dd>
|
||||
<dd><a href="builtins.html#Exception">builtins.Exception</a></dd>
|
||||
<dd><a href="builtins.html#BaseException">builtins.BaseException</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods inherited from <a href="builtins.html#Exception">builtins.Exception</a>:<br>
|
||||
<dl><dt><a name="NotAuthenticatedError-__init__"><strong>__init__</strong></a>(self, /, *args, **kwargs)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__new__"><strong>__new__</strong></a>(*args, **kwargs)<font color="#909090"><font face="helvetica, arial"> from <a href="builtins.html#type">builtins.type</a></font></font></dt><dd><tt>Create and return a new <a href="builtins.html#object">object</a>. See help(type) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="builtins.html#BaseException">builtins.BaseException</a>:<br>
|
||||
<dl><dt><a name="NotAuthenticatedError-__delattr__"><strong>__delattr__</strong></a>(self, name, /)</dt><dd><tt>Implement delattr(self, name).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__getattribute__"><strong>__getattribute__</strong></a>(self, name, /)</dt><dd><tt>Return getattr(self, name).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__reduce__"><strong>__reduce__</strong></a>(...)</dt></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__repr__"><strong>__repr__</strong></a>(self, /)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__setattr__"><strong>__setattr__</strong></a>(self, name, value, /)</dt><dd><tt>Implement setattr(self, name, value).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__setstate__"><strong>__setstate__</strong></a>(...)</dt></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__str__"><strong>__str__</strong></a>(self, /)</dt><dd><tt>Return str(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-with_traceback"><strong>with_traceback</strong></a>(...)</dt><dd><tt><a href="builtins.html#Exception">Exception</a>.<a href="#NotAuthenticatedError-with_traceback">with_traceback</a>(tb) --<br>
|
||||
set self.<strong>__traceback__</strong> to tb and return self.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="builtins.html#BaseException">builtins.BaseException</a>:<br>
|
||||
<dl><dt><strong>__cause__</strong></dt>
|
||||
<dd><tt>exception cause</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__context__</strong></dt>
|
||||
<dd><tt>exception context</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
</dl>
|
||||
<dl><dt><strong>__suppress_context__</strong></dt>
|
||||
</dl>
|
||||
<dl><dt><strong>__traceback__</strong></dt>
|
||||
</dl>
|
||||
<dl><dt><strong>args</strong></dt>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="Protocol">class <strong>Protocol</strong></a>(<a href="builtins.html#object">builtins.object</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base <a href="#Protocol">Protocol</a> module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="Protocol-parseArgs"><strong>parseArgs</strong></a>(self, args)</dt><dd><tt>Parses a string of <a href="http://www.rfc-editor.org/rfc/rfc1459.txt">RFC1459</a>-style arguments split into a list, where ":" may<br>
|
||||
be used for multi-word arguments that last until the end of a line.</tt></dd></dl>
|
||||
@ -388,9 +556,7 @@ Data descriptors defined here:<br>
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="ProtocolError">class <strong>ProtocolError</strong></a>(<a href="builtins.html#Exception">builtins.Exception</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Common base class for all non-exit exceptions.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="classes.html#ProtocolError">ProtocolError</a></dd>
|
||||
<dd><a href="builtins.html#Exception">builtins.Exception</a></dd>
|
||||
@ -414,7 +580,7 @@ Methods inherited from <a href="builtins.html#BaseException">builtins.BaseExcept
|
||||
|
||||
<dl><dt><a name="ProtocolError-__getattribute__"><strong>__getattribute__</strong></a>(self, name, /)</dt><dd><tt>Return getattr(self, name).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="ProtocolError-__reduce__"><strong>__reduce__</strong></a>(...)</dt><dd><tt>helper for pickle</tt></dd></dl>
|
||||
<dl><dt><a name="ProtocolError-__reduce__"><strong>__reduce__</strong></a>(...)</dt></dl>
|
||||
|
||||
<dl><dt><a name="ProtocolError-__repr__"><strong>__repr__</strong></a>(self, /)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
|
||||
@ -450,13 +616,12 @@ Data descriptors inherited from <a href="builtins.html#BaseException">builtins.B
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f8f3fcbc9d8>, {})}<br>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f36077522f0>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_handler</strong> = <logging.StreamHandler object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
@ -47,8 +47,8 @@ configurations from arbitrary files.</tt></p>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7fbb4a5c3840>, {})}<br>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7fcd1260b730>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>fname</strong> = None<br>
|
||||
<strong>testconf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7fbb4a5c3840>, {})}</td></tr></table>
|
||||
<strong>testconf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7fcd1260b730>, {})}</td></tr></table>
|
||||
</body></html>
|
@ -17,10 +17,14 @@
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="gc.html">gc</a><br>
|
||||
</td><td width="25%" valign=top><a href="sys.html">sys</a><br>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="classes.html">classes</a><br>
|
||||
<a href="conf.html">conf</a><br>
|
||||
</td><td width="25%" valign=top><a href="gc.html">gc</a><br>
|
||||
<a href="os.html">os</a><br>
|
||||
</td><td width="25%" valign=top><a href="signal.html">signal</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
</td><td width="25%" valign=top><a href="utils.html">utils</a><br>
|
||||
</td><td width="25%" valign=top><a href="world.html">world</a><br>
|
||||
<a href="world.html">world</a><br>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#eeaa77">
|
||||
@ -42,13 +46,18 @@ Logs in to PyLink using the configured admini
|
||||
<dl><dt><a name="-load"><strong>load</strong></a>(irc, source, args)</dt><dd><tt><plugin name>.<br>
|
||||
<br>
|
||||
Loads a plugin from the plugin folder.</tt></dd></dl>
|
||||
<dl><dt><a name="-main"><strong>main</strong></a>(irc=None)</dt></dl>
|
||||
<dl><dt><a name="-rehash"><strong>rehash</strong></a>(irc, source, args)</dt><dd><tt>takes no arguments.<br>
|
||||
<br>
|
||||
Reloads the configuration file for PyLink, (dis)connecting added/removed networks.<br>
|
||||
Plugins must be manually reloaded.</tt></dd></dl>
|
||||
<dl><dt><a name="-reload"><strong>reload</strong></a>(irc, source, args)</dt><dd><tt><plugin name>.<br>
|
||||
<br>
|
||||
Loads a plugin from the plugin folder.</tt></dd></dl>
|
||||
<dl><dt><a name="-shutdown"><strong>shutdown</strong></a>(irc, source, args)</dt><dd><tt>takes no arguments.<br>
|
||||
<br>
|
||||
Exits PyLink by disconnecting all networks.</tt></dd></dl>
|
||||
<dl><dt><a name="-sighup_handler"><strong>sighup_handler</strong></a>(_signo, _stack_frame)</dt><dd><tt>Handles SIGHUP by rehashing the PyLink daemon.</tt></dd></dl>
|
||||
<dl><dt><a name="-sigterm_handler"><strong>sigterm_handler</strong></a>(_signo, _stack_frame)</dt><dd><tt>Handles SIGTERM gracefully by shutting down the PyLink daemon.</tt></dd></dl>
|
||||
<dl><dt><a name="-unload"><strong>unload</strong></a>(irc, source, args)</dt><dd><tt><plugin name>.<br>
|
||||
<br>
|
||||
Unloads a currently loaded plugin.</tt></dd></dl>
|
||||
|
466
docs/technical/autogen/hybrid.html
Normal file
466
docs/technical/autogen/hybrid.html
Normal file
@ -0,0 +1,466 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html><head><title>Python: module hybrid</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
</head><body bgcolor="#f0f0f8">
|
||||
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
|
||||
<tr bgcolor="#7799ee">
|
||||
<td valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong>hybrid</strong></big></big></font></td
|
||||
><td align=right valign=bottom
|
||||
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/gl/pylink/protocols/hybrid.py">/home/gl/pylink/protocols/hybrid.py</a></font></td></tr></table>
|
||||
<p></p>
|
||||
<p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#aa55cc">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="hashlib.html">hashlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<a href="logging.html">logging</a><br>
|
||||
<a href="os.html">os</a><br>
|
||||
</td><td width="25%" valign=top><a href="re.html">re</a><br>
|
||||
<a href="socket.html">socket</a><br>
|
||||
<a href="ssl.html">ssl</a><br>
|
||||
<a href="string.html">string</a><br>
|
||||
</td><td width="25%" valign=top><a href="structures.html">structures</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
<a href="threading.html">threading</a><br>
|
||||
<a href="time.html">time</a><br>
|
||||
</td><td width="25%" valign=top><a href="utils.html">utils</a><br>
|
||||
<a href="world.html">world</a><br>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ee77aa">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl>
|
||||
<dt><font face="helvetica, arial"><a href="ts6.html#TS6Protocol">ts6.TS6Protocol</a>(<a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="hybrid.html#HybridProtocol">HybridProtocol</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
</dl>
|
||||
<p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><strong>Class</strong> = <a name="Class">class HybridProtocol</a>(<a href="ts6.html#TS6Protocol">ts6.TS6Protocol</a>)</font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="hybrid.html#HybridProtocol">HybridProtocol</a></dd>
|
||||
<dd><a href="ts6.html#TS6Protocol">ts6.TS6Protocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
<dd><a href="classes.html#Protocol">classes.Protocol</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="HybridProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Initializes a connection to a server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_capab"><strong>handle_capab</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_eob"><strong>handle_eob</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_svsmode"><strong>handle_svsmode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles SVSMODE, which is used for sending services metadata<br>
|
||||
(vhosts, account logins), and other forced usermode changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_tburst"><strong>handle_tburst</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming topic burst (TBURST) commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_uid"><strong>handle_uid</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles Hybrid-style UID commands (user introduction). This is INCOMPATIBLE<br>
|
||||
with standard TS6 implementations, as the arguments are slightly different.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-topicBurst"><strong>topicBurst</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a topic change from a PyLink server. This is usually used on burst.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-updateClient"><strong>updateClient</strong></a>(self, target, field, text)</dt><dd><tt>Updates the ident, host, or realname of a PyLink client.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="ts6.html#TS6Protocol">ts6.TS6Protocol</a>:<br>
|
||||
<dl><dt><a name="HybridProtocol-handle_472"><strong>handle_472</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the incoming 472 numeric.<br>
|
||||
<br>
|
||||
472 is sent to us when one of our clients tries to set a mode the uplink<br>
|
||||
server doesn't support. In this case, we'll raise a warning to alert<br>
|
||||
the administrator that certain extensions should be loaded for the best<br>
|
||||
compatibility.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_bmask"><strong>handle_bmask</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming BMASK commands (ban propagation on burst).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_chghost"><strong>handle_chghost</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming CHGHOST commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_encap"><strong>handle_encap</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the ENCAP command - encapsulated TS6 commands with a variety of<br>
|
||||
subcommands used for different purposes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_euid"><strong>handle_euid</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming EUID commands (user introduction).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_invite"><strong>handle_invite</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming INVITEs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_join"><strong>handle_join</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming channel JOINs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_mode"><strong>handle_mode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming user mode changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_pass"><strong>handle_pass</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the PASS command, used to send the server's SID and negotiate<br>
|
||||
passwords on connect.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_ping"><strong>handle_ping</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PING commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_pong"><strong>handle_pong</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PONG commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_server"><strong>handle_server</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles 1) incoming legacy (no SID) server introductions,<br>
|
||||
2) Sending server data in initial connection.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_sid"><strong>handle_sid</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming server introductions.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_sjoin"><strong>handle_sjoin</strong></a>(self, servernumeric, command, args)</dt><dd><tt>Handles incoming SJOIN commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_tb"><strong>handle_tb</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming topic burst (TB) commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_tmode"><strong>handle_tmode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming TMODE commands (channel mode change).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_whois"><strong>handle_whois</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming WHOIS commands.<br>
|
||||
<br>
|
||||
Note: The core of WHOIS handling is done by coreplugin.py<br>
|
||||
(IRCd-independent), and not here.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-invite"><strong>invite</strong></a>(self, numeric, target, channel)</dt><dd><tt>Sends an INVITE from a PyLink client..</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-join"><strong>join</strong></a>(self, client, channel)</dt><dd><tt>Joins a PyLink client to a channel.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-kill"><strong>kill</strong></a>(self, numeric, target, reason)</dt><dd><tt>Sends a kill from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-knock"><strong>knock</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a KNOCK from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-mode"><strong>mode</strong></a>(self, numeric, target, modes, ts=None)</dt><dd><tt>Sends mode changes from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-ping"><strong>ping</strong></a>(self, source=None, target=None)</dt><dd><tt>Sends a PING to a target server. Periodic PINGs are sent to our uplink<br>
|
||||
automatically by the Irc() internals; plugins shouldn't have to use this.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-sjoin"><strong>sjoin</strong></a>(self, server, channel, users, ts=None)</dt><dd><tt>Sends an SJOIN for a group of users to a channel.<br>
|
||||
<br>
|
||||
The sender should always be a Server ID (SID). TS is optional, and defaults<br>
|
||||
to the one we've stored in the channel state if not given.<br>
|
||||
<users> is a list of (prefix mode, UID) pairs:<br>
|
||||
<br>
|
||||
Example uses:<br>
|
||||
<a href="#Class-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('o', 100AAABBB'), ('v', '100AAADDD')])<br>
|
||||
<a href="#Class-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>:<br>
|
||||
<dl><dt><a name="HybridProtocol-away"><strong>away</strong></a>(self, source, text)</dt><dd><tt>Sends an AWAY message from a PyLink client. <text> can be an empty string<br>
|
||||
to unset AWAY status.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_away"><strong>handle_away</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming AWAY messages.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_error"><strong>handle_error</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles ERROR messages - these mean that our uplink has disconnected us!</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_events"><strong>handle_events</strong></a>(self, data)</dt><dd><tt>Event handler for TS6 protocols.<br>
|
||||
<br>
|
||||
This passes most commands to the various handle_ABCD() functions<br>
|
||||
elsewhere defined protocol modules, coersing various sender prefixes<br>
|
||||
from nicks and server names to UIDs and SIDs respectively,<br>
|
||||
whenever possible.<br>
|
||||
<br>
|
||||
Commands sent without an explicit sender prefix will have them set to<br>
|
||||
the SID of the uplink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_kick"><strong>handle_kick</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KICKs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_kill"><strong>handle_kill</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_nick"><strong>handle_nick</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming NICK changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_notice"><strong>handle_notice</strong></a> = handle_privmsg(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_part"><strong>handle_part</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PART commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_quit"><strong>handle_quit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming QUIT commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_save"><strong>handle_save</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming SAVE messages, used to handle nick collisions.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_squit"><strong>handle_squit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming SQUITs (netsplits).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_topic"><strong>handle_topic</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming TOPIC changes from clients. For topic bursts,<br>
|
||||
TB (TS6/charybdis) and FTOPIC (InspIRCd) are used instead.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_version"><strong>handle_version</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles requests for the PyLink server version.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-kick"><strong>kick</strong></a>(self, numeric, channel, target, reason=None)</dt><dd><tt>Sends kicks from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-message"><strong>message</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a PRIVMSG from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-nick"><strong>nick</strong></a>(self, numeric, newnick)</dt><dd><tt>Changes the nick of a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-notice"><strong>notice</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a NOTICE from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt><dd><tt>Sends raw numerics from a server to a remote client, used for WHOIS<br>
|
||||
replies.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-parseTS6Args"><strong>parseTS6Args</strong></a>(self, args)</dt><dd><tt>Similar to <a href="#Class-parseArgs">parseArgs</a>(), but stripping leading colons from the first argument<br>
|
||||
of a line (usually the sender field).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-part"><strong>part</strong></a>(self, client, channel, reason=None)</dt><dd><tt>Sends a part from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-quit"><strong>quit</strong></a>(self, numeric, reason)</dt><dd><tt>Quits a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-spawnServer"><strong>spawnServer</strong></a>(self, name, sid=None, uplink=None, desc=None, endburst_delay=0)</dt><dd><tt>Spawns a server off a PyLink server. desc (server description)<br>
|
||||
defaults to the one in the config. uplink defaults to the main PyLink<br>
|
||||
server, and sid (the server ID) is automatically generated if not<br>
|
||||
given.<br>
|
||||
<br>
|
||||
Note: TS6 doesn't use a specific ENDBURST command, so the endburst_delay<br>
|
||||
option will be ignored if given.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-squit"><strong>squit</strong></a>(self, source, target, text='No reason given')</dt><dd><tt>SQUITs a PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-topic"><strong>topic</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a TOPIC change from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><a name="HybridProtocol-parseArgs"><strong>parseArgs</strong></a>(self, args)</dt><dd><tt>Parses a string of <a href="http://www.rfc-editor.org/rfc/rfc1459.txt">RFC1459</a>-style arguments split into a list, where ":" may<br>
|
||||
be used for multi-word arguments that last until the end of a line.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-removeClient"><strong>removeClient</strong></a>(self, numeric)</dt><dd><tt>Internal function to remove a client from our internal state.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-updateTS"><strong>updateTS</strong></a>(self, channel, their_ts)</dt><dd><tt>Compares the current TS of the channel given with the new TS, resetting<br>
|
||||
all modes we have if the one given is older.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="HybridProtocol">class <strong>HybridProtocol</strong></a>(<a href="ts6.html#TS6Protocol">ts6.TS6Protocol</a>)</font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="hybrid.html#HybridProtocol">HybridProtocol</a></dd>
|
||||
<dd><a href="ts6.html#TS6Protocol">ts6.TS6Protocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
<dd><a href="classes.html#Protocol">classes.Protocol</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="HybridProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Initializes a connection to a server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_capab"><strong>handle_capab</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_eob"><strong>handle_eob</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_svsmode"><strong>handle_svsmode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles SVSMODE, which is used for sending services metadata<br>
|
||||
(vhosts, account logins), and other forced usermode changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_tburst"><strong>handle_tburst</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming topic burst (TBURST) commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_uid"><strong>handle_uid</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles Hybrid-style UID commands (user introduction). This is INCOMPATIBLE<br>
|
||||
with standard TS6 implementations, as the arguments are slightly different.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-topicBurst"><strong>topicBurst</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a topic change from a PyLink server. This is usually used on burst.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-updateClient"><strong>updateClient</strong></a>(self, target, field, text)</dt><dd><tt>Updates the ident, host, or realname of a PyLink client.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="ts6.html#TS6Protocol">ts6.TS6Protocol</a>:<br>
|
||||
<dl><dt><a name="HybridProtocol-handle_472"><strong>handle_472</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the incoming 472 numeric.<br>
|
||||
<br>
|
||||
472 is sent to us when one of our clients tries to set a mode the uplink<br>
|
||||
server doesn't support. In this case, we'll raise a warning to alert<br>
|
||||
the administrator that certain extensions should be loaded for the best<br>
|
||||
compatibility.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_bmask"><strong>handle_bmask</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming BMASK commands (ban propagation on burst).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_chghost"><strong>handle_chghost</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming CHGHOST commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_encap"><strong>handle_encap</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the ENCAP command - encapsulated TS6 commands with a variety of<br>
|
||||
subcommands used for different purposes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_euid"><strong>handle_euid</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming EUID commands (user introduction).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_invite"><strong>handle_invite</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming INVITEs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_join"><strong>handle_join</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming channel JOINs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_mode"><strong>handle_mode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming user mode changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_pass"><strong>handle_pass</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the PASS command, used to send the server's SID and negotiate<br>
|
||||
passwords on connect.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_ping"><strong>handle_ping</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PING commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_pong"><strong>handle_pong</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PONG commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_server"><strong>handle_server</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles 1) incoming legacy (no SID) server introductions,<br>
|
||||
2) Sending server data in initial connection.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_sid"><strong>handle_sid</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming server introductions.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_sjoin"><strong>handle_sjoin</strong></a>(self, servernumeric, command, args)</dt><dd><tt>Handles incoming SJOIN commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_tb"><strong>handle_tb</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming topic burst (TB) commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_tmode"><strong>handle_tmode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming TMODE commands (channel mode change).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_whois"><strong>handle_whois</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming WHOIS commands.<br>
|
||||
<br>
|
||||
Note: The core of WHOIS handling is done by coreplugin.py<br>
|
||||
(IRCd-independent), and not here.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-invite"><strong>invite</strong></a>(self, numeric, target, channel)</dt><dd><tt>Sends an INVITE from a PyLink client..</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-join"><strong>join</strong></a>(self, client, channel)</dt><dd><tt>Joins a PyLink client to a channel.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-kill"><strong>kill</strong></a>(self, numeric, target, reason)</dt><dd><tt>Sends a kill from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-knock"><strong>knock</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a KNOCK from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-mode"><strong>mode</strong></a>(self, numeric, target, modes, ts=None)</dt><dd><tt>Sends mode changes from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-ping"><strong>ping</strong></a>(self, source=None, target=None)</dt><dd><tt>Sends a PING to a target server. Periodic PINGs are sent to our uplink<br>
|
||||
automatically by the Irc() internals; plugins shouldn't have to use this.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-sjoin"><strong>sjoin</strong></a>(self, server, channel, users, ts=None)</dt><dd><tt>Sends an SJOIN for a group of users to a channel.<br>
|
||||
<br>
|
||||
The sender should always be a Server ID (SID). TS is optional, and defaults<br>
|
||||
to the one we've stored in the channel state if not given.<br>
|
||||
<users> is a list of (prefix mode, UID) pairs:<br>
|
||||
<br>
|
||||
Example uses:<br>
|
||||
<a href="#HybridProtocol-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('o', 100AAABBB'), ('v', '100AAADDD')])<br>
|
||||
<a href="#HybridProtocol-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>:<br>
|
||||
<dl><dt><a name="HybridProtocol-away"><strong>away</strong></a>(self, source, text)</dt><dd><tt>Sends an AWAY message from a PyLink client. <text> can be an empty string<br>
|
||||
to unset AWAY status.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_away"><strong>handle_away</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming AWAY messages.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_error"><strong>handle_error</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles ERROR messages - these mean that our uplink has disconnected us!</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_events"><strong>handle_events</strong></a>(self, data)</dt><dd><tt>Event handler for TS6 protocols.<br>
|
||||
<br>
|
||||
This passes most commands to the various handle_ABCD() functions<br>
|
||||
elsewhere defined protocol modules, coersing various sender prefixes<br>
|
||||
from nicks and server names to UIDs and SIDs respectively,<br>
|
||||
whenever possible.<br>
|
||||
<br>
|
||||
Commands sent without an explicit sender prefix will have them set to<br>
|
||||
the SID of the uplink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_kick"><strong>handle_kick</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KICKs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_kill"><strong>handle_kill</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_nick"><strong>handle_nick</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming NICK changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_notice"><strong>handle_notice</strong></a> = handle_privmsg(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_part"><strong>handle_part</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PART commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_quit"><strong>handle_quit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming QUIT commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_save"><strong>handle_save</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming SAVE messages, used to handle nick collisions.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_squit"><strong>handle_squit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming SQUITs (netsplits).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_topic"><strong>handle_topic</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming TOPIC changes from clients. For topic bursts,<br>
|
||||
TB (TS6/charybdis) and FTOPIC (InspIRCd) are used instead.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-handle_version"><strong>handle_version</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles requests for the PyLink server version.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-kick"><strong>kick</strong></a>(self, numeric, channel, target, reason=None)</dt><dd><tt>Sends kicks from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-message"><strong>message</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a PRIVMSG from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-nick"><strong>nick</strong></a>(self, numeric, newnick)</dt><dd><tt>Changes the nick of a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-notice"><strong>notice</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a NOTICE from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt><dd><tt>Sends raw numerics from a server to a remote client, used for WHOIS<br>
|
||||
replies.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-parseTS6Args"><strong>parseTS6Args</strong></a>(self, args)</dt><dd><tt>Similar to <a href="#HybridProtocol-parseArgs">parseArgs</a>(), but stripping leading colons from the first argument<br>
|
||||
of a line (usually the sender field).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-part"><strong>part</strong></a>(self, client, channel, reason=None)</dt><dd><tt>Sends a part from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-quit"><strong>quit</strong></a>(self, numeric, reason)</dt><dd><tt>Quits a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-spawnServer"><strong>spawnServer</strong></a>(self, name, sid=None, uplink=None, desc=None, endburst_delay=0)</dt><dd><tt>Spawns a server off a PyLink server. desc (server description)<br>
|
||||
defaults to the one in the config. uplink defaults to the main PyLink<br>
|
||||
server, and sid (the server ID) is automatically generated if not<br>
|
||||
given.<br>
|
||||
<br>
|
||||
Note: TS6 doesn't use a specific ENDBURST command, so the endburst_delay<br>
|
||||
option will be ignored if given.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-squit"><strong>squit</strong></a>(self, source, target, text='No reason given')</dt><dd><tt>SQUITs a PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-topic"><strong>topic</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a TOPIC change from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><a name="HybridProtocol-parseArgs"><strong>parseArgs</strong></a>(self, args)</dt><dd><tt>Parses a string of <a href="http://www.rfc-editor.org/rfc/rfc1459.txt">RFC1459</a>-style arguments split into a list, where ":" may<br>
|
||||
be used for multi-word arguments that last until the end of a line.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-removeClient"><strong>removeClient</strong></a>(self, numeric)</dt><dd><tt>Internal function to remove a client from our internal state.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="HybridProtocol-updateTS"><strong>updateTS</strong></a>(self, channel, their_ts)</dt><dd><tt>Compares the current TS of the channel given with the new TS, resetting<br>
|
||||
all modes we have if the one given is older.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#55aa55">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f183a5c3bf8>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
@ -18,12 +18,15 @@
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="hashlib.html">hashlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<a href="logging.html">logging</a><br>
|
||||
<a href="os.html">os</a><br>
|
||||
</td><td width="25%" valign=top><a href="re.html">re</a><br>
|
||||
<a href="socket.html">socket</a><br>
|
||||
<a href="ssl.html">ssl</a><br>
|
||||
</td><td width="25%" valign=top><a href="sys.html">sys</a><br>
|
||||
<a href="string.html">string</a><br>
|
||||
</td><td width="25%" valign=top><a href="structures.html">structures</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
<a href="threading.html">threading</a><br>
|
||||
<a href="time.html">time</a><br>
|
||||
</td><td width="25%" valign=top><a href="utils.html">utils</a><br>
|
||||
@ -49,9 +52,7 @@
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><strong>Class</strong> = <a name="Class">class InspIRCdProtocol</a>(<a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base Protocol module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="inspircd.html#InspIRCdProtocol">InspIRCdProtocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
@ -60,7 +61,7 @@
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="InspIRCdProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="InspIRCdProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-away"><strong>away</strong></a>(self, source, text)</dt><dd><tt>Sends an AWAY message from a PyLink client. <text> can be an empty string<br>
|
||||
to unset AWAY status.</tt></dd></dl>
|
||||
@ -135,8 +136,7 @@ servers.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-mode"><strong>mode</strong></a>(self, numeric, target, modes, ts=None)</dt><dd><tt>Sends mode changes from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt><dd><tt>Sends raw numerics from a server to a remote client, used for WHOIS<br>
|
||||
replies.</tt></dd></dl>
|
||||
<dl><dt><a name="InspIRCdProtocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-ping"><strong>ping</strong></a>(self, source=None, target=None)</dt><dd><tt>Sends a PING to a target server. Periodic PINGs are sent to our uplink<br>
|
||||
automatically by the Irc() internals; plugins shouldn't have to use this.</tt></dd></dl>
|
||||
@ -151,7 +151,7 @@ Example uses:<br>
|
||||
<a href="#Class-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('qo', 100AAABBB'), ('h', '100AAADDD')])<br>
|
||||
<a href="#Class-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a client with nick <nick> on the given IRC connection.<br>
|
||||
<dl><dt><a name="InspIRCdProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
@ -248,9 +248,7 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="InspIRCdProtocol">class <strong>InspIRCdProtocol</strong></a>(<a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base Protocol module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="inspircd.html#InspIRCdProtocol">InspIRCdProtocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
@ -259,7 +257,7 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="InspIRCdProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="InspIRCdProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-away"><strong>away</strong></a>(self, source, text)</dt><dd><tt>Sends an AWAY message from a PyLink client. <text> can be an empty string<br>
|
||||
to unset AWAY status.</tt></dd></dl>
|
||||
@ -334,8 +332,7 @@ servers.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-mode"><strong>mode</strong></a>(self, numeric, target, modes, ts=None)</dt><dd><tt>Sends mode changes from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt><dd><tt>Sends raw numerics from a server to a remote client, used for WHOIS<br>
|
||||
replies.</tt></dd></dl>
|
||||
<dl><dt><a name="InspIRCdProtocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-ping"><strong>ping</strong></a>(self, source=None, target=None)</dt><dd><tt>Sends a PING to a target server. Periodic PINGs are sent to our uplink<br>
|
||||
automatically by the Irc() internals; plugins shouldn't have to use this.</tt></dd></dl>
|
||||
@ -350,7 +347,7 @@ Example uses:<br>
|
||||
<a href="#InspIRCdProtocol-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('qo', 100AAABBB'), ('h', '100AAADDD')])<br>
|
||||
<a href="#InspIRCdProtocol-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="InspIRCdProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a client with nick <nick> on the given IRC connection.<br>
|
||||
<dl><dt><a name="InspIRCdProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
@ -448,13 +445,12 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f5f06e526a8>, {})}<br>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7fb165343f28>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_handler</strong> = <logging.StreamHandler object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
@ -24,7 +24,8 @@ access the global logger object by importing
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="logging.html">logging</a><br>
|
||||
</td><td width="25%" valign=top><a href="os.html">os</a><br>
|
||||
</td><td width="25%" valign=top><a href="sys.html">sys</a><br>
|
||||
</td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
|
||||
</td><td width="25%" valign=top><a href="world.html">world</a><br>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ee77aa">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
@ -56,8 +57,7 @@ access the global logger object by importing
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="PyLinkChannelLogger-__init__"><strong>__init__</strong></a>(self, irc, channel, level=None)</dt><dd><tt>Initializes the instance - basically setting the formatter to None<br>
|
||||
and the filter list to empty.</tt></dd></dl>
|
||||
<dl><dt><a name="PyLinkChannelLogger-__init__"><strong>__init__</strong></a>(self, irc, channel, level=None)</dt></dl>
|
||||
|
||||
<dl><dt><a name="PyLinkChannelLogger-emit"><strong>emit</strong></a>(self, record)</dt><dd><tt>Logs a record to the configured channels for the network given.</tt></dd></dl>
|
||||
|
||||
@ -125,7 +125,7 @@ The default is to allow the record to be
|
||||
this and the record is then dropped. Returns a zero value if a record<br>
|
||||
is to be dropped, else non-zero.<br>
|
||||
<br>
|
||||
.. versionchanged:: 3.2<br>
|
||||
.. versionchanged: 3.2<br>
|
||||
<br>
|
||||
Allow filters to be just callables.</tt></dd></dl>
|
||||
|
||||
@ -154,13 +154,12 @@ Data descriptors inherited from <a href="logging.html#Filterer">logging.Filterer
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7fdc93aefc80>, {})}<br>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f81857da950>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_handler</strong> = <logging.StreamHandler object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
471
docs/technical/autogen/nefarious.html
Normal file
471
docs/technical/autogen/nefarious.html
Normal file
@ -0,0 +1,471 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html><head><title>Python: module nefarious</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
</head><body bgcolor="#f0f0f8">
|
||||
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
|
||||
<tr bgcolor="#7799ee">
|
||||
<td valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong>nefarious</strong></big></big></font></td
|
||||
><td align=right valign=bottom
|
||||
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/gl/pylink/protocols/nefarious.py">/home/gl/pylink/protocols/nefarious.py</a></font></td></tr></table>
|
||||
<p><tt>nefarious.py: Nefarious IRCu protocol module for PyLink.</tt></p>
|
||||
<p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#aa55cc">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="base64.html">base64</a><br>
|
||||
<a href="hashlib.html">hashlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<a href="logging.html">logging</a><br>
|
||||
</td><td width="25%" valign=top><a href="os.html">os</a><br>
|
||||
<a href="socket.html">socket</a><br>
|
||||
<a href="ssl.html">ssl</a><br>
|
||||
<a href="struct.html">struct</a><br>
|
||||
</td><td width="25%" valign=top><a href="structures.html">structures</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
<a href="threading.html">threading</a><br>
|
||||
<a href="time.html">time</a><br>
|
||||
</td><td width="25%" valign=top><a href="utils.html">utils</a><br>
|
||||
<a href="world.html">world</a><br>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ee77aa">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl>
|
||||
<dt><font face="helvetica, arial"><a href="builtins.html#object">builtins.object</a>
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="nefarious.html#P10SIDGenerator">P10SIDGenerator</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
<dt><font face="helvetica, arial"><a href="classes.html#Protocol">classes.Protocol</a>(<a href="builtins.html#object">builtins.object</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="nefarious.html#P10Protocol">P10Protocol</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
<dt><font face="helvetica, arial"><a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>(<a href="builtins.html#object">builtins.object</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="nefarious.html#P10UIDGenerator">P10UIDGenerator</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
</dl>
|
||||
<p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><strong>Class</strong> = <a name="Class">class P10Protocol</a>(<a href="classes.html#Protocol">classes.Protocol</a>)</font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="nefarious.html#P10Protocol">P10Protocol</a></dd>
|
||||
<dd><a href="classes.html#Protocol">classes.Protocol</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="P10Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-away"><strong>away</strong></a>(self, source, text)</dt><dd><tt>Sends an AWAY message from a PyLink client. <text> can be an empty string<br>
|
||||
to unset AWAY status.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-checkCloakChange"><strong>checkCloakChange</strong></a>(self, uid)</dt><dd><tt>Checks for cloak changes on the given UID.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Initializes a connection to a server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_account"><strong>handle_account</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles services account changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_away"><strong>handle_away</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming AWAY messages.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_burst"><strong>handle_burst</strong></a>(self, source, command, args)</dt><dd><tt>Handles the BURST command, used for bursting channels on link.<br>
|
||||
<br>
|
||||
This is equivalent to SJOIN on most IRCds.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_clearmode"><strong>handle_clearmode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles CLEARMODE, which is used to clear a channel's modes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_create"><strong>handle_create</strong></a> = <a href="#P10Protocol-handle_join">handle_join</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_end_of_burst"><strong>handle_end_of_burst</strong></a>(self, source, command, args)</dt><dd><tt>Handles end of burst from our uplink.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_events"><strong>handle_events</strong></a>(self, data)</dt><dd><tt>Event handler for the P10 protocol.<br>
|
||||
<br>
|
||||
This passes most commands to the various handle_ABCD() functions defined elsewhere in the<br>
|
||||
protocol modules, coersing various sender prefixes from nicks and server names to P10<br>
|
||||
"numeric nicks", whenever possible.<br>
|
||||
<br>
|
||||
Commands sent without an explicit sender prefix are treated as originating from the uplink<br>
|
||||
server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_fake"><strong>handle_fake</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming FAKE hostmask changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_invite"><strong>handle_invite</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming INVITEs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_join"><strong>handle_join</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming JOINs and channel creations.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_kick"><strong>handle_kick</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KICKs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_kill"><strong>handle_kill</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_mode"><strong>handle_mode</strong></a>(self, source, command, args)</dt><dd><tt>Handles mode changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_nick"><strong>handle_nick</strong></a>(self, source, command, args)</dt><dd><tt>Handles the NICK command, used for user introductions and nick changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_notice"><strong>handle_notice</strong></a> = <a href="#P10Protocol-handle_privmsg">handle_privmsg</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_opmode"><strong>handle_opmode</strong></a> = <a href="#P10Protocol-handle_mode">handle_mode</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_part"><strong>handle_part</strong></a>(self, source, command, args)</dt><dd><tt>Handles user parts.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_pass"><strong>handle_pass</strong></a>(self, source, command, args)</dt><dd><tt>Handles authentication with our uplink.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_ping"><strong>handle_ping</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PING requests.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_pong"><strong>handle_pong</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PONGs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_quit"><strong>handle_quit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming QUITs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_server"><strong>handle_server</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming server introductions.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_squit"><strong>handle_squit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming SQUITs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_topic"><strong>handle_topic</strong></a>(self, source, command, args)</dt><dd><tt>Handles TOPIC changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_version"><strong>handle_version</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles requests for the PyLink server version.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_whois"><strong>handle_whois</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming WHOIS requests.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-invite"><strong>invite</strong></a>(self, numeric, target, channel)</dt><dd><tt>Sends INVITEs from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-join"><strong>join</strong></a>(self, client, channel)</dt><dd><tt>Joins a PyLink client to a channel.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-kick"><strong>kick</strong></a>(self, numeric, channel, target, reason=None)</dt><dd><tt>Sends kicks from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-kill"><strong>kill</strong></a>(self, numeric, target, reason)</dt><dd><tt>Sends a kill from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-knock"><strong>knock</strong></a>(self, numeric, target, text)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-message"><strong>message</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a PRIVMSG from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-mode"><strong>mode</strong></a>(self, numeric, target, modes, ts=None)</dt><dd><tt>Sends mode changes from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-nick"><strong>nick</strong></a>(self, numeric, newnick)</dt><dd><tt>Changes the nick of a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-notice"><strong>notice</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a NOTICE from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt><dd><tt>Sends raw numerics from a server to a remote client. This is used for WHOIS<br>
|
||||
replies.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-part"><strong>part</strong></a>(self, client, channel, reason=None)</dt><dd><tt>Sends a part from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-ping"><strong>ping</strong></a>(self, source=None, target=None)</dt><dd><tt>Sends a PING to a target server. Periodic PINGs are sent to our uplink<br>
|
||||
automatically by the Irc() internals; plugins shouldn't have to use this.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-quit"><strong>quit</strong></a>(self, numeric, reason)</dt><dd><tt>Quits a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-sjoin"><strong>sjoin</strong></a>(self, server, channel, users, ts=None)</dt><dd><tt>Sends an SJOIN for a group of users to a channel.<br>
|
||||
<br>
|
||||
The sender should always be a Server ID (SID). TS is optional, and defaults<br>
|
||||
to the one we've stored in the channel state if not given.<br>
|
||||
<users> is a list of (prefix mode, UID) pairs:<br>
|
||||
<br>
|
||||
Example uses:<br>
|
||||
<a href="#Class-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('o', 100AAABBB'), ('v', '100AAADDD')])<br>
|
||||
<a href="#Class-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-spawnServer"><strong>spawnServer</strong></a>(self, name, sid=None, uplink=None, desc=None, endburst_delay=0)</dt><dd><tt>Spawns a server off a PyLink server. desc (server description)<br>
|
||||
defaults to the one in the config. uplink defaults to the main PyLink<br>
|
||||
server, and sid (the server ID) is automatically generated if not<br>
|
||||
given.<br>
|
||||
<br>
|
||||
Note: TS6 doesn't use a specific ENDBURST command, so the endburst_delay<br>
|
||||
option will be ignored if given.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-squit"><strong>squit</strong></a>(self, source, target, text='No reason given')</dt><dd><tt>SQUITs a PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-topic"><strong>topic</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a TOPIC change from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-topicBurst"><strong>topicBurst</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a TOPIC change from a PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-updateClient"><strong>updateClient</strong></a>(self, target, field, text)</dt><dd><tt>Updates the ident or host of any connected client.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Static methods defined here:<br>
|
||||
<dl><dt><a name="P10Protocol-decode_p10_ip"><strong>decode_p10_ip</strong></a>(ip)</dt><dd><tt>Decodes a P10 IP.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><a name="P10Protocol-parseArgs"><strong>parseArgs</strong></a>(self, args)</dt><dd><tt>Parses a string of <a href="http://www.rfc-editor.org/rfc/rfc1459.txt">RFC1459</a>-style arguments split into a list, where ":" may<br>
|
||||
be used for multi-word arguments that last until the end of a line.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-removeClient"><strong>removeClient</strong></a>(self, numeric)</dt><dd><tt>Internal function to remove a client from our internal state.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-updateTS"><strong>updateTS</strong></a>(self, channel, their_ts)</dt><dd><tt>Compares the current TS of the channel given with the new TS, resetting<br>
|
||||
all modes we have if the one given is older.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="P10Protocol">class <strong>P10Protocol</strong></a>(<a href="classes.html#Protocol">classes.Protocol</a>)</font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="nefarious.html#P10Protocol">P10Protocol</a></dd>
|
||||
<dd><a href="classes.html#Protocol">classes.Protocol</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="P10Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-away"><strong>away</strong></a>(self, source, text)</dt><dd><tt>Sends an AWAY message from a PyLink client. <text> can be an empty string<br>
|
||||
to unset AWAY status.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-checkCloakChange"><strong>checkCloakChange</strong></a>(self, uid)</dt><dd><tt>Checks for cloak changes on the given UID.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Initializes a connection to a server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_account"><strong>handle_account</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles services account changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_away"><strong>handle_away</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming AWAY messages.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_burst"><strong>handle_burst</strong></a>(self, source, command, args)</dt><dd><tt>Handles the BURST command, used for bursting channels on link.<br>
|
||||
<br>
|
||||
This is equivalent to SJOIN on most IRCds.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_clearmode"><strong>handle_clearmode</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles CLEARMODE, which is used to clear a channel's modes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_create"><strong>handle_create</strong></a> = <a href="#P10Protocol-handle_join">handle_join</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_end_of_burst"><strong>handle_end_of_burst</strong></a>(self, source, command, args)</dt><dd><tt>Handles end of burst from our uplink.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_events"><strong>handle_events</strong></a>(self, data)</dt><dd><tt>Event handler for the P10 protocol.<br>
|
||||
<br>
|
||||
This passes most commands to the various handle_ABCD() functions defined elsewhere in the<br>
|
||||
protocol modules, coersing various sender prefixes from nicks and server names to P10<br>
|
||||
"numeric nicks", whenever possible.<br>
|
||||
<br>
|
||||
Commands sent without an explicit sender prefix are treated as originating from the uplink<br>
|
||||
server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_fake"><strong>handle_fake</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming FAKE hostmask changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_invite"><strong>handle_invite</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming INVITEs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_join"><strong>handle_join</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming JOINs and channel creations.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_kick"><strong>handle_kick</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KICKs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_kill"><strong>handle_kill</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_mode"><strong>handle_mode</strong></a>(self, source, command, args)</dt><dd><tt>Handles mode changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_nick"><strong>handle_nick</strong></a>(self, source, command, args)</dt><dd><tt>Handles the NICK command, used for user introductions and nick changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_notice"><strong>handle_notice</strong></a> = <a href="#P10Protocol-handle_privmsg">handle_privmsg</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_opmode"><strong>handle_opmode</strong></a> = <a href="#P10Protocol-handle_mode">handle_mode</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_part"><strong>handle_part</strong></a>(self, source, command, args)</dt><dd><tt>Handles user parts.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_pass"><strong>handle_pass</strong></a>(self, source, command, args)</dt><dd><tt>Handles authentication with our uplink.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_ping"><strong>handle_ping</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PING requests.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_pong"><strong>handle_pong</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PONGs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_quit"><strong>handle_quit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming QUITs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_server"><strong>handle_server</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming server introductions.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_squit"><strong>handle_squit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming SQUITs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_topic"><strong>handle_topic</strong></a>(self, source, command, args)</dt><dd><tt>Handles TOPIC changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_version"><strong>handle_version</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles requests for the PyLink server version.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-handle_whois"><strong>handle_whois</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming WHOIS requests.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-invite"><strong>invite</strong></a>(self, numeric, target, channel)</dt><dd><tt>Sends INVITEs from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-join"><strong>join</strong></a>(self, client, channel)</dt><dd><tt>Joins a PyLink client to a channel.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-kick"><strong>kick</strong></a>(self, numeric, channel, target, reason=None)</dt><dd><tt>Sends kicks from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-kill"><strong>kill</strong></a>(self, numeric, target, reason)</dt><dd><tt>Sends a kill from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-knock"><strong>knock</strong></a>(self, numeric, target, text)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-message"><strong>message</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a PRIVMSG from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-mode"><strong>mode</strong></a>(self, numeric, target, modes, ts=None)</dt><dd><tt>Sends mode changes from a PyLink client/server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-nick"><strong>nick</strong></a>(self, numeric, newnick)</dt><dd><tt>Changes the nick of a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-notice"><strong>notice</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a NOTICE from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-numeric"><strong>numeric</strong></a>(self, source, numeric, target, text)</dt><dd><tt>Sends raw numerics from a server to a remote client. This is used for WHOIS<br>
|
||||
replies.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-part"><strong>part</strong></a>(self, client, channel, reason=None)</dt><dd><tt>Sends a part from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-ping"><strong>ping</strong></a>(self, source=None, target=None)</dt><dd><tt>Sends a PING to a target server. Periodic PINGs are sent to our uplink<br>
|
||||
automatically by the Irc() internals; plugins shouldn't have to use this.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-quit"><strong>quit</strong></a>(self, numeric, reason)</dt><dd><tt>Quits a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-sjoin"><strong>sjoin</strong></a>(self, server, channel, users, ts=None)</dt><dd><tt>Sends an SJOIN for a group of users to a channel.<br>
|
||||
<br>
|
||||
The sender should always be a Server ID (SID). TS is optional, and defaults<br>
|
||||
to the one we've stored in the channel state if not given.<br>
|
||||
<users> is a list of (prefix mode, UID) pairs:<br>
|
||||
<br>
|
||||
Example uses:<br>
|
||||
<a href="#P10Protocol-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('o', 100AAABBB'), ('v', '100AAADDD')])<br>
|
||||
<a href="#P10Protocol-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-spawnServer"><strong>spawnServer</strong></a>(self, name, sid=None, uplink=None, desc=None, endburst_delay=0)</dt><dd><tt>Spawns a server off a PyLink server. desc (server description)<br>
|
||||
defaults to the one in the config. uplink defaults to the main PyLink<br>
|
||||
server, and sid (the server ID) is automatically generated if not<br>
|
||||
given.<br>
|
||||
<br>
|
||||
Note: TS6 doesn't use a specific ENDBURST command, so the endburst_delay<br>
|
||||
option will be ignored if given.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-squit"><strong>squit</strong></a>(self, source, target, text='No reason given')</dt><dd><tt>SQUITs a PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-topic"><strong>topic</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a TOPIC change from a PyLink client.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-topicBurst"><strong>topicBurst</strong></a>(self, numeric, target, text)</dt><dd><tt>Sends a TOPIC change from a PyLink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-updateClient"><strong>updateClient</strong></a>(self, target, field, text)</dt><dd><tt>Updates the ident or host of any connected client.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Static methods defined here:<br>
|
||||
<dl><dt><a name="P10Protocol-decode_p10_ip"><strong>decode_p10_ip</strong></a>(ip)</dt><dd><tt>Decodes a P10 IP.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><a name="P10Protocol-parseArgs"><strong>parseArgs</strong></a>(self, args)</dt><dd><tt>Parses a string of <a href="http://www.rfc-editor.org/rfc/rfc1459.txt">RFC1459</a>-style arguments split into a list, where ":" may<br>
|
||||
be used for multi-word arguments that last until the end of a line.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-removeClient"><strong>removeClient</strong></a>(self, numeric)</dt><dd><tt>Internal function to remove a client from our internal state.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10Protocol-updateTS"><strong>updateTS</strong></a>(self, channel, their_ts)</dt><dd><tt>Compares the current TS of the channel given with the new TS, resetting<br>
|
||||
all modes we have if the one given is older.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="P10SIDGenerator">class <strong>P10SIDGenerator</strong></a>(<a href="builtins.html#object">builtins.object</a>)</font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="P10SIDGenerator-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="P10SIDGenerator-next_sid"><strong>next_sid</strong></a>(self)</dt><dd><tt>Returns the next available SID.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="P10UIDGenerator">class <strong>P10UIDGenerator</strong></a>(<a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Implements an incremental P10 UID Generator.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="nefarious.html#P10UIDGenerator">P10UIDGenerator</a></dd>
|
||||
<dd><a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="P10UIDGenerator-__init__"><strong>__init__</strong></a>(self, sid)</dt></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>:<br>
|
||||
<dl><dt><a name="P10UIDGenerator-increment"><strong>increment</strong></a>(self, pos=None)</dt><dd><tt>Increments the UID generator to the next available UID.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="P10UIDGenerator-next_uid"><strong>next_uid</strong></a>(self)</dt><dd><tt>Returns the next unused UID for the server.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#eeaa77">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Functions</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#eeaa77"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt><a name="-p10b64encode"><strong>p10b64encode</strong></a>(num, length=2)</dt><dd><tt>Encodes a given numeric using P10 Base64 numeric nicks, as documented at<br>
|
||||
https://github.com/evilnet/nefarious2/blob/a29b63144/doc/p10.txt#L69-L92</tt></dd></dl>
|
||||
</td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#55aa55">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f4243176488>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
144
docs/technical/autogen/structures.html
Normal file
144
docs/technical/autogen/structures.html
Normal file
@ -0,0 +1,144 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html><head><title>Python: module structures</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
</head><body bgcolor="#f0f0f8">
|
||||
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="heading">
|
||||
<tr bgcolor="#7799ee">
|
||||
<td valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"> <br><big><big><strong>structures</strong></big></big></font></td
|
||||
><td align=right valign=bottom
|
||||
><font color="#ffffff" face="helvetica, arial"><a href=".">index</a><br><a href="file:/home/gl/pylink/structures.py">/home/gl/pylink/structures.py</a></font></td></tr></table>
|
||||
<p><tt>structures.py - PyLink data structures module.<br>
|
||||
<br>
|
||||
This module contains custom data structures that may be useful in various situations.</tt></p>
|
||||
<p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#aa55cc">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="collections.html">collections</a><br>
|
||||
</td><td width="25%" valign=top></td><td width="25%" valign=top></td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ee77aa">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Classes</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl>
|
||||
<dt><font face="helvetica, arial"><a href="collections.html#defaultdict">collections.defaultdict</a>(<a href="builtins.html#dict">builtins.dict</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="structures.html#KeyedDefaultdict">KeyedDefaultdict</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
</dl>
|
||||
<p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="KeyedDefaultdict">class <strong>KeyedDefaultdict</strong></a>(<a href="collections.html#defaultdict">collections.defaultdict</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Subclass of <a href="collections.html#defaultdict">defaultdict</a> allowing the key to be passed to the default factory.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="structures.html#KeyedDefaultdict">KeyedDefaultdict</a></dd>
|
||||
<dd><a href="collections.html#defaultdict">collections.defaultdict</a></dd>
|
||||
<dd><a href="builtins.html#dict">builtins.dict</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="KeyedDefaultdict-__missing__"><strong>__missing__</strong></a>(self, key)</dt></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods inherited from <a href="collections.html#defaultdict">collections.defaultdict</a>:<br>
|
||||
<dl><dt><a name="KeyedDefaultdict-__copy__"><strong>__copy__</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-copy">copy</a>() -> a shallow copy of D.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__getattribute__"><strong>__getattribute__</strong></a>(self, name, /)</dt><dd><tt>Return getattr(self, name).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__init__"><strong>__init__</strong></a>(self, /, *args, **kwargs)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__reduce__"><strong>__reduce__</strong></a>(...)</dt><dd><tt>Return state information for pickling.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__repr__"><strong>__repr__</strong></a>(self, /)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-copy"><strong>copy</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-copy">copy</a>() -> a shallow copy of D.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="collections.html#defaultdict">collections.defaultdict</a>:<br>
|
||||
<dl><dt><strong>default_factory</strong></dt>
|
||||
<dd><tt>Factory for default value called by __missing__().</tt></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods inherited from <a href="builtins.html#dict">builtins.dict</a>:<br>
|
||||
<dl><dt><a name="KeyedDefaultdict-__contains__"><strong>__contains__</strong></a>(self, key, /)</dt><dd><tt>True if D has a key k, else False.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__delitem__"><strong>__delitem__</strong></a>(self, key, /)</dt><dd><tt>Delete self[key].</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__eq__"><strong>__eq__</strong></a>(self, value, /)</dt><dd><tt>Return self==value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__ge__"><strong>__ge__</strong></a>(self, value, /)</dt><dd><tt>Return self>=value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__getitem__"><strong>__getitem__</strong></a>(...)</dt><dd><tt>x.<a href="#KeyedDefaultdict-__getitem__">__getitem__</a>(y) <==> x[y]</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__gt__"><strong>__gt__</strong></a>(self, value, /)</dt><dd><tt>Return self>value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__iter__"><strong>__iter__</strong></a>(self, /)</dt><dd><tt>Implement iter(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__le__"><strong>__le__</strong></a>(self, value, /)</dt><dd><tt>Return self<=value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__len__"><strong>__len__</strong></a>(self, /)</dt><dd><tt>Return len(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__lt__"><strong>__lt__</strong></a>(self, value, /)</dt><dd><tt>Return self<value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__ne__"><strong>__ne__</strong></a>(self, value, /)</dt><dd><tt>Return self!=value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__new__"><strong>__new__</strong></a>(*args, **kwargs)<font color="#909090"><font face="helvetica, arial"> from <a href="builtins.html#type">builtins.type</a></font></font></dt><dd><tt>Create and return a new object. See help(type) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__setitem__"><strong>__setitem__</strong></a>(self, key, value, /)</dt><dd><tt>Set self[key] to value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__sizeof__"><strong>__sizeof__</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-__sizeof__">__sizeof__</a>() -> size of D in memory, in bytes</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-clear"><strong>clear</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-clear">clear</a>() -> None. Remove all items from D.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-fromkeys"><strong>fromkeys</strong></a>(iterable, value=None, /)<font color="#909090"><font face="helvetica, arial"> from <a href="builtins.html#type">builtins.type</a></font></font></dt><dd><tt>Returns a new dict with keys from iterable and values equal to value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-get"><strong>get</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-get">get</a>(k[,d]) -> D[k] if k in D, else d. d defaults to None.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-items"><strong>items</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-items">items</a>() -> a set-like object providing a view on D's items</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-keys"><strong>keys</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-keys">keys</a>() -> a set-like object providing a view on D's keys</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-pop"><strong>pop</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-pop">pop</a>(k[,d]) -> v, remove specified key and return the corresponding value.<br>
|
||||
If key is not found, d is returned if given, otherwise KeyError is raised</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-popitem"><strong>popitem</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-popitem">popitem</a>() -> (k, v), remove and return some (key, value) pair as a<br>
|
||||
2-tuple; but raise KeyError if D is empty.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-setdefault"><strong>setdefault</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-setdefault">setdefault</a>(k[,d]) -> D.<a href="#KeyedDefaultdict-get">get</a>(k,d), also set D[k]=d if k not in D</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-update"><strong>update</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-update">update</a>([E, ]**F) -> None. Update D from dict/iterable E and F.<br>
|
||||
If E is present and has a .<a href="#KeyedDefaultdict-keys">keys</a>() method, then does: for k in E: D[k] = E[k]<br>
|
||||
If E is present and lacks a .<a href="#KeyedDefaultdict-keys">keys</a>() method, then does: for k, v in E: D[k] = v<br>
|
||||
In either case, this is followed by: for k in F: D[k] = F[k]</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-values"><strong>values</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-values">values</a>() -> an object providing a view on D's values</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data and other attributes inherited from <a href="builtins.html#dict">builtins.dict</a>:<br>
|
||||
<dl><dt><strong>__hash__</strong> = None</dl>
|
||||
|
||||
</td></tr></table></td></tr></table>
|
||||
</body></html>
|
@ -18,12 +18,15 @@
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="hashlib.html">hashlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<a href="logging.html">logging</a><br>
|
||||
<a href="os.html">os</a><br>
|
||||
</td><td width="25%" valign=top><a href="re.html">re</a><br>
|
||||
<a href="socket.html">socket</a><br>
|
||||
<a href="ssl.html">ssl</a><br>
|
||||
</td><td width="25%" valign=top><a href="sys.html">sys</a><br>
|
||||
<a href="string.html">string</a><br>
|
||||
</td><td width="25%" valign=top><a href="structures.html">structures</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
<a href="threading.html">threading</a><br>
|
||||
<a href="time.html">time</a><br>
|
||||
</td><td width="25%" valign=top><a href="utils.html">utils</a><br>
|
||||
@ -49,9 +52,7 @@
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><strong>Class</strong> = <a name="Class">class TS6Protocol</a>(<a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base Protocol module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="ts6.html#TS6Protocol">TS6Protocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
@ -60,7 +61,7 @@
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="TS6Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="TS6Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="TS6Protocol-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Initializes a connection to a server.</tt></dd></dl>
|
||||
|
||||
@ -136,7 +137,7 @@ Example uses:<br>
|
||||
<a href="#Class-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('o', 100AAABBB'), ('v', '100AAADDD')])<br>
|
||||
<a href="#Class-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6Protocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a client with nick <nick> on the given IRC connection.<br>
|
||||
<dl><dt><a name="TS6Protocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
@ -241,9 +242,7 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="TS6Protocol">class <strong>TS6Protocol</strong></a>(<a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base Protocol module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="ts6.html#TS6Protocol">TS6Protocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
@ -252,7 +251,7 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="TS6Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="TS6Protocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="TS6Protocol-connect"><strong>connect</strong></a>(self)</dt><dd><tt>Initializes a connection to a server.</tt></dd></dl>
|
||||
|
||||
@ -328,7 +327,7 @@ Example uses:<br>
|
||||
<a href="#TS6Protocol-sjoin">sjoin</a>('100', '#test', [('', '100AAABBC'), ('o', 100AAABBB'), ('v', '100AAADDD')])<br>
|
||||
<a href="#TS6Protocol-sjoin">sjoin</a>(self.<strong>irc</strong>.sid, '#test', [('o', self.<strong>irc</strong>.pseudoclient.uid)])</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6Protocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a client with nick <nick> on the given IRC connection.<br>
|
||||
<dl><dt><a name="TS6Protocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
@ -434,13 +433,12 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f7bc713a598>, {})}<br>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f8cbdc44c80>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_handler</strong> = <logging.StreamHandler object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
@ -18,12 +18,15 @@
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="hashlib.html">hashlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<a href="logging.html">logging</a><br>
|
||||
<a href="os.html">os</a><br>
|
||||
</td><td width="25%" valign=top><a href="socket.html">socket</a><br>
|
||||
<a href="ssl.html">ssl</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
</td><td width="25%" valign=top><a href="threading.html">threading</a><br>
|
||||
<a href="string.html">string</a><br>
|
||||
<a href="structures.html">structures</a><br>
|
||||
</td><td width="25%" valign=top><a href="sys.html">sys</a><br>
|
||||
<a href="threading.html">threading</a><br>
|
||||
<a href="time.html">time</a><br>
|
||||
<a href="utils.html">utils</a><br>
|
||||
</td><td width="25%" valign=top><a href="world.html">world</a><br>
|
||||
@ -35,12 +38,24 @@
|
||||
|
||||
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl>
|
||||
<dt><font face="helvetica, arial"><a href="builtins.html#object">builtins.object</a>
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="ts6_common.html#TS6SIDGenerator">TS6SIDGenerator</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
<dt><font face="helvetica, arial"><a href="classes.html#Protocol">classes.Protocol</a>(<a href="builtins.html#object">builtins.object</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="ts6_common.html#TS6BaseProtocol">TS6BaseProtocol</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
<dt><font face="helvetica, arial"><a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>(<a href="builtins.html#object">builtins.object</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="ts6_common.html#TS6UIDGenerator">TS6UIDGenerator</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
</dl>
|
||||
<p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
@ -48,9 +63,7 @@
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="TS6BaseProtocol">class <strong>TS6BaseProtocol</strong></a>(<a href="classes.html#Protocol">classes.Protocol</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base <a href="classes.html#Protocol">Protocol</a> module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">TS6BaseProtocol</a></dd>
|
||||
<dd><a href="classes.html#Protocol">classes.Protocol</a></dd>
|
||||
@ -58,6 +71,8 @@
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="TS6BaseProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="TS6BaseProtocol-away"><strong>away</strong></a>(self, source, text)</dt><dd><tt>Sends an AWAY message from a PyLink client. <text> can be an empty string<br>
|
||||
to unset AWAY status.</tt></dd></dl>
|
||||
|
||||
@ -130,8 +145,6 @@ option will be ignored if given.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="classes.html#Protocol">classes.Protocol</a>:<br>
|
||||
<dl><dt><a name="TS6BaseProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6BaseProtocol-parseArgs"><strong>parseArgs</strong></a>(self, args)</dt><dd><tt>Parses a string of <a href="http://www.rfc-editor.org/rfc/rfc1459.txt">RFC1459</a>-style arguments split into a list, where ":" may<br>
|
||||
be used for multi-word arguments that last until the end of a line.</tt></dd></dl>
|
||||
|
||||
@ -148,6 +161,74 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="TS6SIDGenerator">class <strong>TS6SIDGenerator</strong></a>(<a href="builtins.html#object">builtins.object</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>TS6 SID Generator. <query> is a 3 character string with any combination of<br>
|
||||
uppercase letters, digits, and #'s. it must contain at least one #,<br>
|
||||
which are used by the generator as a wildcard. On every <a href="#TS6SIDGenerator-next_sid">next_sid</a>() call,<br>
|
||||
the first available wildcard character (from the right) will be<br>
|
||||
incremented to generate the next SID.<br>
|
||||
<br>
|
||||
When there are no more available SIDs left (SIDs are not reused, only<br>
|
||||
incremented), RuntimeError is raised.<br>
|
||||
<br>
|
||||
Example queries:<br>
|
||||
"1#A" would give: 10A, 11A, 12A ... 19A, 1AA, 1BA ... 1ZA (36 total results)<br>
|
||||
"#BQ" would give: 0BQ, 1BQ, 2BQ ... 9BQ (10 total results)<br>
|
||||
"6##" would give: 600, 601, 602, ... 60Y, 60Z, 610, 611, ... 6ZZ (1296 total results)<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="TS6SIDGenerator-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="TS6SIDGenerator-increment"><strong>increment</strong></a>(self, pos=2)</dt><dd><tt>Increments the SID generator to the next available SID.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6SIDGenerator-next_sid"><strong>next_sid</strong></a>(self)</dt><dd><tt>Returns the next unused TS6 SID for the server.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="TS6UIDGenerator">class <strong>TS6UIDGenerator</strong></a>(<a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Implements an incremental TS6 UID Generator.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="ts6_common.html#TS6UIDGenerator">TS6UIDGenerator</a></dd>
|
||||
<dd><a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="TS6UIDGenerator-__init__"><strong>__init__</strong></a>(self, sid)</dt></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>:<br>
|
||||
<dl><dt><a name="TS6UIDGenerator-increment"><strong>increment</strong></a>(self, pos=None)</dt><dd><tt>Increments the UID generator to the next available UID.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6UIDGenerator-next_uid"><strong>next_uid</strong></a>(self)</dt><dd><tt>Returns the next unused UID for the server.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="utils.html#IncrementalUIDGenerator">utils.IncrementalUIDGenerator</a>:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#55aa55">
|
||||
@ -155,13 +236,12 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f2667895488>, {})}<br>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f683a0b9d90>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_handler</strong> = <logging.StreamHandler object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
@ -19,11 +19,14 @@
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="codecs.html">codecs</a><br>
|
||||
<a href="hashlib.html">hashlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<a href="logging.html">logging</a><br>
|
||||
</td><td width="25%" valign=top><a href="os.html">os</a><br>
|
||||
<a href="re.html">re</a><br>
|
||||
<a href="socket.html">socket</a><br>
|
||||
</td><td width="25%" valign=top><a href="ssl.html">ssl</a><br>
|
||||
<a href="ssl.html">ssl</a><br>
|
||||
</td><td width="25%" valign=top><a href="string.html">string</a><br>
|
||||
<a href="structures.html">structures</a><br>
|
||||
<a href="sys.html">sys</a><br>
|
||||
<a href="threading.html">threading</a><br>
|
||||
</td><td width="25%" valign=top><a href="time.html">time</a><br>
|
||||
@ -50,9 +53,7 @@
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><strong>Class</strong> = <a name="Class">class UnrealProtocol</a>(<a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base Protocol module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="unreal.html#UnrealProtocol">UnrealProtocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
@ -61,7 +62,7 @@
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="UnrealProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="UnrealProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-checkCloakChange"><strong>checkCloakChange</strong></a>(self, uid, parsedmodes)</dt><dd><tt>Checks whether +x/-x was set in the mode query, and changes the<br>
|
||||
hostname of the user given to or from their cloaked host if True.</tt></dd></dl>
|
||||
@ -80,8 +81,12 @@ hostname of the user given to or from th
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_join"><strong>handle_join</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the UnrealIRCd JOIN command.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_kill"><strong>handle_kill</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_mode"><strong>handle_mode</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_nick"><strong>handle_nick</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles NICK changes, and legacy NICK introductions from pre-4.0 servers.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_notice"><strong>handle_notice</strong></a> = <a href="#UnrealProtocol-handle_privmsg">handle_privmsg</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_pass"><strong>handle_pass</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
@ -90,9 +95,9 @@ hostname of the user given to or from th
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_pong"><strong>handle_pong</strong></a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
<dl><dt><a name="UnrealProtocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_protoctl"><strong>handle_protoctl</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
<dl><dt><a name="UnrealProtocol-handle_protoctl"><strong>handle_protoctl</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles protocol negotiation.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_server"><strong>handle_server</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the SERVER command, which is used for both authentication and<br>
|
||||
introducing legacy (non-SID) servers.</tt></dd></dl>
|
||||
@ -149,7 +154,7 @@ Example uses:<br>
|
||||
Note that for UnrealIRCd, no mode data is sent in an SJOIN command, only<br>
|
||||
The channel name, TS, and user list.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a client with nick <nick> on the given IRC connection.<br>
|
||||
<dl><dt><a name="UnrealProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
@ -179,10 +184,6 @@ the SID of the uplink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_kick"><strong>handle_kick</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KICKs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_kill"><strong>handle_kill</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_nick"><strong>handle_nick</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming NICK changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_part"><strong>handle_part</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PART commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_quit"><strong>handle_quit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming QUIT commands.</tt></dd></dl>
|
||||
@ -245,9 +246,7 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="UnrealProtocol">class <strong>UnrealProtocol</strong></a>(<a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Base Protocol module class for PyLink.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<tr><td bgcolor="#ffc8d8"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="unreal.html#UnrealProtocol">UnrealProtocol</a></dd>
|
||||
<dd><a href="ts6_common.html#TS6BaseProtocol">ts6_common.TS6BaseProtocol</a></dd>
|
||||
@ -256,7 +255,7 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="UnrealProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="UnrealProtocol-__init__"><strong>__init__</strong></a>(self, irc)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-checkCloakChange"><strong>checkCloakChange</strong></a>(self, uid, parsedmodes)</dt><dd><tt>Checks whether +x/-x was set in the mode query, and changes the<br>
|
||||
hostname of the user given to or from their cloaked host if True.</tt></dd></dl>
|
||||
@ -275,8 +274,12 @@ hostname of the user given to or from th
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_join"><strong>handle_join</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the UnrealIRCd JOIN command.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_kill"><strong>handle_kill</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_mode"><strong>handle_mode</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_nick"><strong>handle_nick</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles NICK changes, and legacy NICK introductions from pre-4.0 servers.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_notice"><strong>handle_notice</strong></a> = <a href="#UnrealProtocol-handle_privmsg">handle_privmsg</a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_pass"><strong>handle_pass</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
@ -285,9 +288,9 @@ hostname of the user given to or from th
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_pong"><strong>handle_pong</strong></a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PRIVMSG/NOTICE.</tt></dd></dl>
|
||||
<dl><dt><a name="UnrealProtocol-handle_privmsg"><strong>handle_privmsg</strong></a>(self, source, command, args)</dt></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_protoctl"><strong>handle_protoctl</strong></a>(self, numeric, command, args)</dt></dl>
|
||||
<dl><dt><a name="UnrealProtocol-handle_protoctl"><strong>handle_protoctl</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles protocol negotiation.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_server"><strong>handle_server</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles the SERVER command, which is used for both authentication and<br>
|
||||
introducing legacy (non-SID) servers.</tt></dd></dl>
|
||||
@ -344,7 +347,7 @@ Example uses:<br>
|
||||
Note that for UnrealIRCd, no mode data is sent in an SJOIN command, only<br>
|
||||
The channel name, TS, and user list.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype=None, manipulatable=False)</dt><dd><tt>Spawns a client with nick <nick> on the given IRC connection.<br>
|
||||
<dl><dt><a name="UnrealProtocol-spawnClient"><strong>spawnClient</strong></a>(self, nick, ident='null', host='null', realhost=None, modes=set(), server=None, ip='0.0.0.0', realname=None, ts=None, opertype='IRC Operator', manipulatable=False)</dt><dd><tt>Spawns a new client with the given options.<br>
|
||||
<br>
|
||||
Note: No nick collision / valid nickname checks are done here; it is<br>
|
||||
up to plugins to make sure they don't introduce anything invalid.</tt></dd></dl>
|
||||
@ -374,10 +377,6 @@ the SID of the uplink server.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_kick"><strong>handle_kick</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KICKs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_kill"><strong>handle_kill</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming KILLs.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_nick"><strong>handle_nick</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming NICK changes.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_part"><strong>handle_part</strong></a>(self, source, command, args)</dt><dd><tt>Handles incoming PART commands.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="UnrealProtocol-handle_quit"><strong>handle_quit</strong></a>(self, numeric, command, args)</dt><dd><tt>Handles incoming QUIT commands.</tt></dd></dl>
|
||||
@ -441,13 +440,12 @@ Data descriptors inherited from <a href="classes.html#Protocol">classes.Protocol
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Data</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#55aa55"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7f0f1f40fc80>, {})}<br>
|
||||
<td width="100%"><strong>conf</strong> = {'bot': {'nick': 'PyLink', 'realname': 'PyLink Service Client', 'serverdesc': 'PyLink unit tests', 'user': 'pylink'}, 'logging': {'stdout': 'CRITICAL'}, 'servers': defaultdict(<function <lambda> at 0x7fcbbf211620>, {})}<br>
|
||||
<strong>confname</strong> = 'testconf'<br>
|
||||
<strong>curdir</strong> = '/home/gl/pylink'<br>
|
||||
<strong>files</strong> = None<br>
|
||||
<strong>log</strong> = <logging.RootLogger object><br>
|
||||
<strong>logdir</strong> = '/home/gl/pylink/log'<br>
|
||||
<strong>logformatter</strong> = <logging.Formatter object><br>
|
||||
<strong>stdout_handler</strong> = <logging.StreamHandler object><br>
|
||||
<strong>stdout_level</strong> = 'CRITICAL'</td></tr></table>
|
||||
</body></html>
|
@ -20,15 +20,13 @@ framework.</tt></p>
|
||||
<font color="#ffffff" face="helvetica, arial"><big><strong>Modules</strong></big></font></td></tr>
|
||||
|
||||
<tr><td bgcolor="#aa55cc"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="collections.html">collections</a><br>
|
||||
<a href="conf.html">conf</a><br>
|
||||
</td><td width="25%" valign=top><a href="importlib.html">importlib</a><br>
|
||||
<a href="inspect.html">inspect</a><br>
|
||||
<td width="100%"><table width="100%" summary="list"><tr><td width="25%" valign=top><a href="conf.html">conf</a><br>
|
||||
<a href="importlib.html">importlib</a><br>
|
||||
</td><td width="25%" valign=top><a href="os.html">os</a><br>
|
||||
<a href="re.html">re</a><br>
|
||||
</td><td width="25%" valign=top><a href="string.html">string</a><br>
|
||||
<a href="world.html">world</a><br>
|
||||
</td></tr></table></td></tr></table><p>
|
||||
</td><td width="25%" valign=top></td></tr></table></td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ee77aa">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
@ -36,23 +34,10 @@ framework.</tt></p>
|
||||
|
||||
<tr><td bgcolor="#ee77aa"><tt> </tt></td><td> </td>
|
||||
<td width="100%"><dl>
|
||||
<dt><font face="helvetica, arial"><a href="builtins.html#Exception">builtins.Exception</a>(<a href="builtins.html#BaseException">builtins.BaseException</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="utils.html#NotAuthenticatedError">NotAuthenticatedError</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
<dt><font face="helvetica, arial"><a href="builtins.html#object">builtins.object</a>
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="utils.html#TS6SIDGenerator">TS6SIDGenerator</a>
|
||||
</font></dt><dt><font face="helvetica, arial"><a href="utils.html#TS6UIDGenerator">TS6UIDGenerator</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
<dt><font face="helvetica, arial"><a href="collections.html#defaultdict">collections.defaultdict</a>(<a href="builtins.html#dict">builtins.dict</a>)
|
||||
</font></dt><dd>
|
||||
<dl>
|
||||
<dt><font face="helvetica, arial"><a href="utils.html#KeyedDefaultdict">KeyedDefaultdict</a>
|
||||
<dt><font face="helvetica, arial"><a href="utils.html#IncrementalUIDGenerator">IncrementalUIDGenerator</a>
|
||||
</font></dt></dl>
|
||||
</dd>
|
||||
</dl>
|
||||
@ -60,224 +45,18 @@ framework.</tt></p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="KeyedDefaultdict">class <strong>KeyedDefaultdict</strong></a>(<a href="collections.html#defaultdict">collections.defaultdict</a>)</font></td></tr>
|
||||
<font color="#000000" face="helvetica, arial"><a name="IncrementalUIDGenerator">class <strong>IncrementalUIDGenerator</strong></a>(<a href="builtins.html#object">builtins.object</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>Subclass of <a href="collections.html#defaultdict">defaultdict</a> allowing the key to be passed to the default factory.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="utils.html#KeyedDefaultdict">KeyedDefaultdict</a></dd>
|
||||
<dd><a href="collections.html#defaultdict">collections.defaultdict</a></dd>
|
||||
<dd><a href="builtins.html#dict">builtins.dict</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods defined here:<br>
|
||||
<dl><dt><a name="KeyedDefaultdict-__missing__"><strong>__missing__</strong></a>(self, key)</dt><dd><tt><a href="#KeyedDefaultdict-__missing__">__missing__</a>(key) # Called by __getitem__ for missing key; pseudo-code:<br>
|
||||
if self.<strong>default_factory</strong> is None: raise KeyError((key,))<br>
|
||||
self[key] = value = self.<a href="#KeyedDefaultdict-default_factory">default_factory</a>()<br>
|
||||
return value</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods inherited from <a href="collections.html#defaultdict">collections.defaultdict</a>:<br>
|
||||
<dl><dt><a name="KeyedDefaultdict-__copy__"><strong>__copy__</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-copy">copy</a>() -> a shallow copy of D.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__getattribute__"><strong>__getattribute__</strong></a>(self, name, /)</dt><dd><tt>Return getattr(self, name).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__init__"><strong>__init__</strong></a>(self, /, *args, **kwargs)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__reduce__"><strong>__reduce__</strong></a>(...)</dt><dd><tt>Return state information for pickling.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__repr__"><strong>__repr__</strong></a>(self, /)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-copy"><strong>copy</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-copy">copy</a>() -> a shallow copy of D.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="collections.html#defaultdict">collections.defaultdict</a>:<br>
|
||||
<dl><dt><strong>default_factory</strong></dt>
|
||||
<dd><tt>Factory for default value called by __missing__().</tt></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods inherited from <a href="builtins.html#dict">builtins.dict</a>:<br>
|
||||
<dl><dt><a name="KeyedDefaultdict-__contains__"><strong>__contains__</strong></a>(self, key, /)</dt><dd><tt>True if D has a key k, else False.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__delitem__"><strong>__delitem__</strong></a>(self, key, /)</dt><dd><tt>Delete self[key].</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__eq__"><strong>__eq__</strong></a>(self, value, /)</dt><dd><tt>Return self==value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__ge__"><strong>__ge__</strong></a>(self, value, /)</dt><dd><tt>Return self>=value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__getitem__"><strong>__getitem__</strong></a>(...)</dt><dd><tt>x.<a href="#KeyedDefaultdict-__getitem__">__getitem__</a>(y) <==> x[y]</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__gt__"><strong>__gt__</strong></a>(self, value, /)</dt><dd><tt>Return self>value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__iter__"><strong>__iter__</strong></a>(self, /)</dt><dd><tt>Implement iter(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__le__"><strong>__le__</strong></a>(self, value, /)</dt><dd><tt>Return self<=value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__len__"><strong>__len__</strong></a>(self, /)</dt><dd><tt>Return len(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__lt__"><strong>__lt__</strong></a>(self, value, /)</dt><dd><tt>Return self<value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__ne__"><strong>__ne__</strong></a>(self, value, /)</dt><dd><tt>Return self!=value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__new__"><strong>__new__</strong></a>(*args, **kwargs)<font color="#909090"><font face="helvetica, arial"> from <a href="builtins.html#type">builtins.type</a></font></font></dt><dd><tt>Create and return a new <a href="builtins.html#object">object</a>. See help(type) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__setitem__"><strong>__setitem__</strong></a>(self, key, value, /)</dt><dd><tt>Set self[key] to value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-__sizeof__"><strong>__sizeof__</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-__sizeof__">__sizeof__</a>() -> size of D in memory, in bytes</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-clear"><strong>clear</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-clear">clear</a>() -> None. Remove all items from D.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-fromkeys"><strong>fromkeys</strong></a>(iterable, value=None, /)<font color="#909090"><font face="helvetica, arial"> from <a href="builtins.html#type">builtins.type</a></font></font></dt><dd><tt>Returns a new dict with keys from iterable and values equal to value.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-get"><strong>get</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-get">get</a>(k[,d]) -> D[k] if k in D, else d. d defaults to None.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-items"><strong>items</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-items">items</a>() -> a set-like <a href="builtins.html#object">object</a> providing a view on D's items</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-keys"><strong>keys</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-keys">keys</a>() -> a set-like <a href="builtins.html#object">object</a> providing a view on D's keys</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-pop"><strong>pop</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-pop">pop</a>(k[,d]) -> v, remove specified key and return the corresponding value.<br>
|
||||
If key is not found, d is returned if given, otherwise KeyError is raised</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-popitem"><strong>popitem</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-popitem">popitem</a>() -> (k, v), remove and return some (key, value) pair as a<br>
|
||||
2-tuple; but raise KeyError if D is empty.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-setdefault"><strong>setdefault</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-setdefault">setdefault</a>(k[,d]) -> D.<a href="#KeyedDefaultdict-get">get</a>(k,d), also set D[k]=d if k not in D</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-update"><strong>update</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-update">update</a>([E, ]**F) -> None. Update D from dict/iterable E and F.<br>
|
||||
If E is present and has a .<a href="#KeyedDefaultdict-keys">keys</a>() method, then does: for k in E: D[k] = E[k]<br>
|
||||
If E is present and lacks a .<a href="#KeyedDefaultdict-keys">keys</a>() method, then does: for k, v in E: D[k] = v<br>
|
||||
In either case, this is followed by: for k in F: D[k] = F[k]</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="KeyedDefaultdict-values"><strong>values</strong></a>(...)</dt><dd><tt>D.<a href="#KeyedDefaultdict-values">values</a>() -> an <a href="builtins.html#object">object</a> providing a view on D's values</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data and other attributes inherited from <a href="builtins.html#dict">builtins.dict</a>:<br>
|
||||
<dl><dt><strong>__hash__</strong> = None</dl>
|
||||
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="NotAuthenticatedError">class <strong>NotAuthenticatedError</strong></a>(<a href="builtins.html#Exception">builtins.Exception</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt><a href="builtins.html#Exception">Exception</a> raised by <a href="#-checkAuthenticated">checkAuthenticated</a>() when a user fails authentication<br>
|
||||
requirements.<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%"><dl><dt>Method resolution order:</dt>
|
||||
<dd><a href="utils.html#NotAuthenticatedError">NotAuthenticatedError</a></dd>
|
||||
<dd><a href="builtins.html#Exception">builtins.Exception</a></dd>
|
||||
<dd><a href="builtins.html#BaseException">builtins.BaseException</a></dd>
|
||||
<dd><a href="builtins.html#object">builtins.object</a></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
<hr>
|
||||
Methods inherited from <a href="builtins.html#Exception">builtins.Exception</a>:<br>
|
||||
<dl><dt><a name="NotAuthenticatedError-__init__"><strong>__init__</strong></a>(self, /, *args, **kwargs)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__new__"><strong>__new__</strong></a>(*args, **kwargs)<font color="#909090"><font face="helvetica, arial"> from <a href="builtins.html#type">builtins.type</a></font></font></dt><dd><tt>Create and return a new <a href="builtins.html#object">object</a>. See help(type) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Methods inherited from <a href="builtins.html#BaseException">builtins.BaseException</a>:<br>
|
||||
<dl><dt><a name="NotAuthenticatedError-__delattr__"><strong>__delattr__</strong></a>(self, name, /)</dt><dd><tt>Implement delattr(self, name).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__getattribute__"><strong>__getattribute__</strong></a>(self, name, /)</dt><dd><tt>Return getattr(self, name).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__reduce__"><strong>__reduce__</strong></a>(...)</dt><dd><tt>helper for pickle</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__repr__"><strong>__repr__</strong></a>(self, /)</dt><dd><tt>Return repr(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__setattr__"><strong>__setattr__</strong></a>(self, name, value, /)</dt><dd><tt>Implement setattr(self, name, value).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__setstate__"><strong>__setstate__</strong></a>(...)</dt></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-__str__"><strong>__str__</strong></a>(self, /)</dt><dd><tt>Return str(self).</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="NotAuthenticatedError-with_traceback"><strong>with_traceback</strong></a>(...)</dt><dd><tt><a href="builtins.html#Exception">Exception</a>.<a href="#NotAuthenticatedError-with_traceback">with_traceback</a>(tb) --<br>
|
||||
set self.<strong>__traceback__</strong> to tb and return self.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors inherited from <a href="builtins.html#BaseException">builtins.BaseException</a>:<br>
|
||||
<dl><dt><strong>__cause__</strong></dt>
|
||||
<dd><tt>exception cause</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__context__</strong></dt>
|
||||
<dd><tt>exception context</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
</dl>
|
||||
<dl><dt><strong>__suppress_context__</strong></dt>
|
||||
</dl>
|
||||
<dl><dt><strong>__traceback__</strong></dt>
|
||||
</dl>
|
||||
<dl><dt><strong>args</strong></dt>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="TS6SIDGenerator">class <strong>TS6SIDGenerator</strong></a>(<a href="builtins.html#object">builtins.object</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>TS6 SID Generator. <query> is a 3 character string with any combination of<br>
|
||||
uppercase letters, digits, and #'s. it must contain at least one #,<br>
|
||||
which are used by the generator as a wildcard. On every <a href="#TS6SIDGenerator-next_sid">next_sid</a>() call,<br>
|
||||
the first available wildcard character (from the right) will be<br>
|
||||
incremented to generate the next SID.<br>
|
||||
<br>
|
||||
When there are no more available SIDs left (SIDs are not reused, only<br>
|
||||
incremented), RuntimeError is raised.<br>
|
||||
<br>
|
||||
Example queries:<br>
|
||||
"1#A" would give: 10A, 11A, 12A ... 19A, 1AA, 1BA ... 1ZA (36 total results)<br>
|
||||
"#BQ" would give: 0BQ, 1BQ, 2BQ ... 9BQ (10 total results)<br>
|
||||
"6##" would give: 600, 601, 602, ... 60Y, 60Z, 610, 611, ... 6ZZ (1296 total results)<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="TS6SIDGenerator-__init__"><strong>__init__</strong></a>(self, irc)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6SIDGenerator-increment"><strong>increment</strong></a>(self, pos=2)</dt><dd><tt>Increments the SID generator to the next available SID.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6SIDGenerator-next_sid"><strong>next_sid</strong></a>(self)</dt><dd><tt>Returns the next unused TS6 SID for the server.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
<dl><dt><strong>__dict__</strong></dt>
|
||||
<dd><tt>dictionary for instance variables (if defined)</tt></dd>
|
||||
</dl>
|
||||
<dl><dt><strong>__weakref__</strong></dt>
|
||||
<dd><tt>list of weak references to the object (if defined)</tt></dd>
|
||||
</dl>
|
||||
</td></tr></table> <p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#ffc8d8">
|
||||
<td colspan=3 valign=bottom> <br>
|
||||
<font color="#000000" face="helvetica, arial"><a name="TS6UIDGenerator">class <strong>TS6UIDGenerator</strong></a>(<a href="builtins.html#object">builtins.object</a>)</font></td></tr>
|
||||
|
||||
<tr bgcolor="#ffc8d8"><td rowspan=2><tt> </tt></td>
|
||||
<td colspan=2><tt>TS6 UID Generator module, adapted from InspIRCd source:<br>
|
||||
<td colspan=2><tt>Incremental UID Generator module, adapted from InspIRCd source:<br>
|
||||
https://github.com/inspircd/inspircd/blob/f449c6b296ab/src/server.cpp#L85-L156<br> </tt></td></tr>
|
||||
<tr><td> </td>
|
||||
<td width="100%">Methods defined here:<br>
|
||||
<dl><dt><a name="TS6UIDGenerator-__init__"><strong>__init__</strong></a>(self, sid)</dt><dd><tt>Initialize self. See help(type(self)) for accurate signature.</tt></dd></dl>
|
||||
<dl><dt><a name="IncrementalUIDGenerator-__init__"><strong>__init__</strong></a>(self, sid)</dt></dl>
|
||||
|
||||
<dl><dt><a name="TS6UIDGenerator-increment"><strong>increment</strong></a>(self, pos=5)</dt><dd><tt>Increments the SID generator to the next available SID.</tt></dd></dl>
|
||||
<dl><dt><a name="IncrementalUIDGenerator-increment"><strong>increment</strong></a>(self, pos=None)</dt><dd><tt>Increments the UID generator to the next available UID.</tt></dd></dl>
|
||||
|
||||
<dl><dt><a name="TS6UIDGenerator-next_uid"><strong>next_uid</strong></a>(self)</dt><dd><tt>Returns the next unused TS6 UID for the server.</tt></dd></dl>
|
||||
<dl><dt><a name="IncrementalUIDGenerator-next_uid"><strong>next_uid</strong></a>(self)</dt><dd><tt>Returns the next unused UID for the server.</tt></dd></dl>
|
||||
|
||||
<hr>
|
||||
Data descriptors defined here:<br>
|
||||
@ -298,11 +77,9 @@ Data descriptors defined here:<br>
|
||||
<dl><dt><a name="-add_hook"><strong>add_hook</strong></a>(func, command)</dt><dd><tt>Binds a hook function to the given command name.</tt></dd></dl>
|
||||
<dl><dt><a name="-applyModes"><strong>applyModes</strong></a>(irc, target, changedmodes)</dt><dd><tt>Takes a list of parsed IRC modes, and applies them on the given target.<br>
|
||||
<br>
|
||||
The target can be either a channel or a user; this is handled automatically.</tt></dd></dl>
|
||||
<dl><dt><a name="-checkAuthenticated"><strong>checkAuthenticated</strong></a>(irc, uid, allowAuthed=True, allowOper=True)</dt><dd><tt>Checks whether the given user has operator status on PyLink, raising<br>
|
||||
<a href="#NotAuthenticatedError">NotAuthenticatedError</a> and logging the access denial if not.</tt></dd></dl>
|
||||
<dl><dt><a name="-fullVersion"><strong>fullVersion</strong></a>(irc)</dt><dd><tt>Returns a detailed version string including the PyLink daemon version,<br>
|
||||
the protocol module in use, and the server hostname.</tt></dd></dl>
|
||||
The target can be either a channel or a user; this is handled automatically.<br>
|
||||
<br>
|
||||
This method is deprecated. Use irc.<a href="#-applyModes">applyModes</a>() instead.</tt></dd></dl>
|
||||
<dl><dt><a name="-getDatabaseName"><strong>getDatabaseName</strong></a>(dbname)</dt><dd><tt>Returns a database filename with the given base DB name appropriate for the<br>
|
||||
current PyLink instance.<br>
|
||||
<br>
|
||||
@ -310,45 +87,16 @@ This returns '<dbname>.db' if the running co
|
||||
(config.yml), and '<dbname>-<config name>.db' for anything else. For example,<br>
|
||||
if this is called from an instance running as './pylink testing.yml', it<br>
|
||||
would return '<dbname>-testing.db'.</tt></dd></dl>
|
||||
<dl><dt><a name="-getHostmask"><strong>getHostmask</strong></a>(irc, user, realhost=False, ip=False)</dt><dd><tt>Returns the hostmask of the given user, if present. If the realhost option<br>
|
||||
is given, return the real host of the user instead of the displayed host.<br>
|
||||
If the ip option is given, return the IP address of the user (this overrides<br>
|
||||
realhost).</tt></dd></dl>
|
||||
<dl><dt><a name="-getProtocolModule"><strong>getProtocolModule</strong></a>(protoname)</dt><dd><tt>Imports and returns the protocol module requested.</tt></dd></dl>
|
||||
<dl><dt><a name="-isChannel"><strong>isChannel</strong></a>(s)</dt><dd><tt>Returns whether the string given is a valid channel name.</tt></dd></dl>
|
||||
<dl><dt><a name="-isHostmask"><strong>isHostmask</strong></a>(text)</dt><dd><tt>Returns whether the given text is a valid hostmask.</tt></dd></dl>
|
||||
<dl><dt><a name="-isManipulatableClient"><strong>isManipulatableClient</strong></a>(irc, uid)</dt><dd><tt>Returns whether the given user is marked as an internal, manipulatable<br>
|
||||
client. Usually, automatically spawned services clients should have this<br>
|
||||
set True to prevent interactions with opers (like mode changes) from<br>
|
||||
causing desyncs.</tt></dd></dl>
|
||||
<dl><dt><a name="-isNick"><strong>isNick</strong></a>(s, nicklen=None)</dt><dd><tt>Returns whether the string given is a valid nick.</tt></dd></dl>
|
||||
<dl><dt><a name="-isOper"><strong>isOper</strong></a>(irc, uid, allowAuthed=True, allowOper=True)</dt><dd><tt>Returns whether the given user has operator status on PyLink. This can be achieved<br>
|
||||
by either identifying to PyLink as admin (if allowAuthed is True),<br>
|
||||
or having user mode +o set (if allowOper is True). At least one of<br>
|
||||
allowAuthed or allowOper must be True for this to give any meaningful<br>
|
||||
results.</tt></dd></dl>
|
||||
<dl><dt><a name="-isServerName"><strong>isServerName</strong></a>(s)</dt><dd><tt>Returns whether the string given is a valid IRC server name.</tt></dd></dl>
|
||||
<dl><dt><a name="-joinModes"><strong>joinModes</strong></a>(modes)</dt><dd><tt>Takes a list of (mode, arg) tuples in <a href="#-parseModes">parseModes</a>() format, and<br>
|
||||
joins them into a string.<br>
|
||||
<br>
|
||||
See testJoinModes in tests/test_utils.py for some examples.</tt></dd></dl>
|
||||
<dl><dt><a name="-loadModuleFromFolder"><strong>loadModuleFromFolder</strong></a>(name, folder)</dt><dd><tt>Imports and returns a module, if existing, from a specific folder.</tt></dd></dl>
|
||||
<dl><dt><a name="-parseModes"><strong>parseModes</strong></a>(irc, target, args)</dt><dd><tt>Parses a modestring list into a list of (mode, argument) tuples.<br>
|
||||
['+mitl-o', '3', 'person'] => [('+m', None), ('+i', None), ('+t', None), ('+l', '3'), ('-o', 'person')]</tt></dd></dl>
|
||||
<dl><dt><a name="-reverseModes"><strong>reverseModes</strong></a>(irc, target, modes, oldobj=None)</dt><dd><tt>Reverses/Inverts the mode string or mode list given.<br>
|
||||
['+mitl-o', '3', 'person'] => [('+m', None), ('+i', None), ('+t', None), ('+l', '3'), ('-o', 'person')]<br>
|
||||
<br>
|
||||
Optionally, an oldobj argument can be given to look at an earlier state of<br>
|
||||
a channel/user <a href="builtins.html#object">object</a>, e.g. for checking the op status of a mode setter<br>
|
||||
before their modes are processed and added to the channel state.<br>
|
||||
<br>
|
||||
This function allows both mode strings or mode lists. Example uses:<br>
|
||||
"+mi-lk test => "-mi+lk test"<br>
|
||||
"mi-k test => "-mi+k test"<br>
|
||||
[('+m', None), ('+r', None), ('+l', '3'), ('-o', 'person')<br>
|
||||
=> {('-m', None), ('-r', None), ('-l', None), ('+o', 'person')})<br>
|
||||
{('s', None), ('+o', 'whoever') => {('-s', None), ('-o', 'whoever')})</tt></dd></dl>
|
||||
<dl><dt><a name="-toLower"><strong>toLower</strong></a>(irc, text)</dt><dd><tt>Returns a lowercase representation of text based on the IRC <a href="builtins.html#object">object</a>'s<br>
|
||||
casemapping (rfc1459 or ascii).</tt></dd></dl>
|
||||
This method is deprecated. Use irc.<a href="#-parseModes">parseModes</a>() instead.</tt></dd></dl>
|
||||
</td></tr></table><p>
|
||||
<table width="100%" cellspacing=0 cellpadding=2 border=0 summary="section">
|
||||
<tr bgcolor="#55aa55">
|
||||
|
@ -37,6 +37,6 @@
|
||||
<strong>started</strong> = <threading.Event object><br>
|
||||
<strong>testing</strong> = True<br>
|
||||
<strong>testing_ircd</strong> = 'inspircd'<br>
|
||||
<strong>version</strong> = 'v0.7.0-dev-29-gc8a3514'<br>
|
||||
<strong>version</strong> = 'v0.8-alpha2-5-g6b40c97'<br>
|
||||
<strong>whois_handlers</strong> = []</td></tr></table>
|
||||
</body></html>
|
Loading…
Reference in New Issue
Block a user