mirror of
https://github.com/jlu5/PyLink.git
synced 2024-12-02 15:59:26 +01:00
clientbot: document some functions
This commit is contained in:
parent
d2a3a64293
commit
75d88224f1
@ -152,6 +152,8 @@ class ClientbotWrapperProtocol(Protocol):
|
|||||||
|
|
||||||
def sjoin(self, server, channel, users, ts=None, modes=set()):
|
def sjoin(self, server, channel, users, ts=None, modes=set()):
|
||||||
"""STUB: bursts joins from a server."""
|
"""STUB: bursts joins from a server."""
|
||||||
|
# This stub only updates the state internally with the users
|
||||||
|
# given. modes and TS are currently ignored.
|
||||||
puids = {u[-1] for u in users}
|
puids = {u[-1] for u in users}
|
||||||
for user in puids:
|
for user in puids:
|
||||||
self.irc.users[user].channels.add(channel)
|
self.irc.users[user].channels.add(channel)
|
||||||
@ -159,9 +161,13 @@ class ClientbotWrapperProtocol(Protocol):
|
|||||||
self.irc.channels[channel].users |= puids
|
self.irc.channels[channel].users |= puids
|
||||||
|
|
||||||
def squit(self, source, target, text):
|
def squit(self, source, target, text):
|
||||||
|
"""STUB: SQUITs a server."""
|
||||||
|
# What this actually does is just handle the SQUIT internally: i.e.
|
||||||
|
# Removing pseudoclients and pseudoservers.
|
||||||
self._squit(source, target, text)
|
self._squit(source, target, text)
|
||||||
|
|
||||||
def _stub(self, *args):
|
def _stub(self, *args):
|
||||||
|
"""Stub outgoing command function (does nothing)."""
|
||||||
return
|
return
|
||||||
away = mode = topic = topicBurst = invite = knock = _stub
|
away = mode = topic = topicBurst = invite = knock = _stub
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user