Class s.i.Bot(pluginSupport, irc.IRCClient):

Part of services.ircClient View Source View In Hierarchy

The Protocol of our IRC-Bot
Instance Variablespluginscontains references to all plugins, which are loaded (type: list )
userscontains a dict of all users in the channels we are in (type: dict )
channelsall channels we are currently in (type: list )
networkthe name of the network we are connected to (type: string )
loggera instance of the standard python logger
nicknamethe nick of the bot
Method __init__ Undocumented
Method register_ctl_command Undocumented
Method register_my_commands Undocumented
Method startPlugins initializes all known plugins
Method startPlugin Undocumented
Method getChannelUserDict Get a dict with userslists
Method getUsers Get a list of users in channel
Method getFactory get the factory
Method auth call this, to see which rights user has
Method depends raise an Exception, if the dependency is not active
Method encode_line Undocumented
Method sendmsg call only this to send messages to channels or users
Method sendme call only this to send actions (/me) to channels
Method connectionMade this is called by twisted
Method connectionLost this is called by twisted,
Method signedOn called by twisted,
Method joined called by twisted,
Method left called by twisted,
Method isupport Called with various information about what the server supports.
Method command callback for !commands
Method privmsg called by twisted,
Method irc_unknown called by twisted
Method noticed called by twisted,
Method action called by twisted,
Method modeChanged called by twisted
Method kickedFrom called by twisted,
Method userKicked called by twisted,
Method userJoined called by twisted,
Method userLeft called by twisted,
Method userQuit called by twisted,
Method yourHost called by twisted
Method ctcpUnknownQuery called by twisted,
Method userRenamed called by twisted,
Method topicUpdated called by twisted
Method irc_RPL_ENDOFNAMES Undocumented
Method irc_RPL_NAMREPLY Undocumented
Method irc_RPL_USERHOST Undocumented
Method irc_INVITE called by twisted,
Method irc_RPL_BOUNCE Overridden to get isupport work correctly
Method irc_JOIN Overridden to get the full hostmask
Method irc_PART Overridden to get the full hostmask
Method irc_QUIT Overridden to get the full hostmask
Method lineReceived called by twisted
Method sendLine Sends a line to the other end of the connection.
Method ping Measure round-trip delay to another IRC client.
Method disconnect disconnects cleanly from the current network

Inherited from pluginSupport:

Method register_pluginsupport_commands Undocumented
Method depends_on_module Undocumented
Method depends_on_service Undocumented
Method depends_on_plugin Undocumented
Method importPlugin Undocumented
Method callbackRegistered Undocumented
Method registerCallback Undocumented
Method unregisterCallback Undocumented
Method reloadPluginClass Undocumented
Method restartPlugin Undocumented
Method reloadPlugins call this to reload all plugins
Method stopPlugins stop all Plugins
Method stopPlugin Undocumented
Class WontStart Undocumented
Class DependencyMissing Undocumented
Class ModuleMissing Undocumented
Class ServiceMissing Undocumented
Class PluginMissing Undocumented
Method logerror format a exception nicely and pass it to the logger
Method _getClassName Undocumented
Method _apirunner Pass all calls to plugin callbacks through this method, they

Inherited from IRCClient:

Method created Called with creation date information about the server, usually at logon.
Method myInfo Called with information about the server, usually at logon.
Method luserClient Called with information about the number of connections, usually at logon.
Method bounce Called with information about where the client should reconnect.
Method luserChannels Called with the number of channels existant on the server.
Method luserOp Called with the number of ops logged on to the server.
Method luserMe Called with information about the server connected to.
Method pong Called with the results of a CTCP PING query.
Method nickChanged Called when my nick has been changed.
Method receivedMOTD I received a message-of-the-day banner from the server.
Method join Join a channel.
Method leave Leave a channel.
Method kick Attempt to kick a user from a channel.
Method topic Attempt to set the topic of the given channel, or ask what it is.
Method mode Change the modes on a user or channel.
Method say Send a message to a channel
Method msg Send a message to a user or channel.
Method notice Send a notice to a user.
Method away Mark this client as away.
Method back Clear the away status.
Method whois Retrieve user information about the given nick name.
Method register Login to the server.
Method setNick Set this client's nickname.
Method quit Disconnect from the server
Method describe Strike a pose.
Method me Strike a pose.
Method dccSend Undocumented
Method dccResume Send a DCC RESUME request to another user.
Method dccAcceptResume Send a DCC ACCEPT response to clients who have requested a resume.
Method irc_ERR_NICKNAMEINUSE Called when we try to register or change to a nickname that is already
Method alterCollidedNick Generate an altered version of a nickname that caused a collision in an
Method irc_ERR_ERRONEUSNICKNAME Called when we try to register or change to an illegal nickname.
Method irc_ERR_PASSWDMISMATCH Called when the login was incorrect.
Method irc_RPL_WELCOME Called when we have received the welcome from the server.
Method irc_MODE Parse a server mode change message.
Method irc_PING Called when some has pinged us.
Method irc_PRIVMSG Called when we get a message.
Method irc_NOTICE Called when a user gets a notice.
Method irc_NICK Called when a user changes their nickname.
Method irc_KICK Called when a user is kicked from a channel.
Method irc_TOPIC Someone in the channel set the topic.
Method irc_RPL_TOPIC Called when the topic for a channel is initially reported or when it
Method irc_RPL_NOTOPIC Undocumented
Method irc_RPL_MOTDSTART Undocumented
Method irc_RPL_MOTD Undocumented
Method irc_RPL_ENDOFMOTD RPL_ENDOFMOTD indicates the end of the message of the day
Method irc_RPL_CREATED Undocumented
Method irc_RPL_YOURHOST Undocumented
Method irc_RPL_MYINFO Undocumented
Method irc_RPL_ISUPPORT Undocumented
Method irc_RPL_LUSERCLIENT Undocumented
Method irc_RPL_LUSEROP Undocumented
Method irc_RPL_LUSERCHANNELS Undocumented
Method irc_RPL_LUSERME Undocumented
Method ctcpQuery Dispatch method for any CTCP queries received.
Method ctcpQuery_ACTION Undocumented
Method ctcpQuery_PING Undocumented
Method ctcpQuery_FINGER Undocumented
Method ctcpQuery_VERSION Undocumented
Method ctcpQuery_SOURCE Undocumented
Method ctcpQuery_USERINFO Undocumented
Method ctcpQuery_CLIENTINFO A master index of what CTCP tags this client knows.
Method ctcpQuery_ERRMSG Undocumented
Method ctcpQuery_TIME Undocumented
Method ctcpQuery_DCC Initiate a Direct Client Connection
Method dcc_SEND Undocumented
Method dcc_ACCEPT Undocumented
Method dcc_RESUME Undocumented
Method dcc_CHAT Undocumented
Method dccDoSend Called when I receive a DCC SEND offer from a client.
Method dccDoResume Called when a client is trying to resume an offered file
Method dccDoAcceptResume Called when a client has verified and accepted a DCC resume
Method dccDoChat Undocumented
Method ctcpMakeReply Send one or more extended messages as a CTCP reply.
Method ctcpMakeQuery Send one or more extended messages as a CTCP query.
Method ctcpReply Dispatch method for any CTCP replies received.
Method ctcpReply_PING Undocumented
Method ctcpUnknownReply Called when a fitting ctcpReply_ method is not found.
Method badMessage When I get a message that's so broken I can't use it.
Method quirkyMessage This is called when I receive a message which is peculiar,
Method dataReceived Protocol.dataReceived.
Method getUserModeParams Get user modes that require parameters for correct parsing.
Method getChannelModeParams Get channel modes that require parameters for correct parsing.
Method handleCommand Determine the function to call for the given command and call
Method __getstate__ Undocumented
Method _reallySendLine Undocumented
Method _sendLine Undocumented

Inherited from LineReceiver (via IRCClient):

Method clearLineBuffer Clear buffered data.
Method setLineMode Sets the line-mode of this receiver.
Method setRawMode Sets the raw mode of this receiver.
Method rawDataReceived Override this for when raw data is received.
Method lineLengthExceeded Called when the maximum line length has been reached.

Inherited from BaseProtocol (via IRCClient, LineReceiver, Protocol):

Method makeConnection Make a connection to a transport and a server.

Inherited from _PauseableMixin (via IRCClient, LineReceiver):

Method pauseProducing Undocumented
Method resumeProducing Undocumented
Method stopProducing Undocumented
def __init__(self, root, parent): (source)
Undocumented
def register_ctl_command(self, f, namespace=None, name=None): (source)
Undocumented
def register_my_commands(self): (source)
Undocumented
def startPlugins(self): (source)
initializes all known plugins
def startPlugin(self, pluginName): (source)
Undocumented
def getChannelUserDict(self): (source)
Get a dict with userslists
Returnsa dict with the channelnames as keys (type: dict )
def getUsers(self, channel): (source)
Get a list of users in channel
Returnsa list of users (type: dict )
def getFactory(self): (source)
get the factory
Returnsthe current factory (type: BotFactory )
def auth(self, user): (source)
call this, to see which rights user has
Parametersuserthe full hostmask of the user (type: string )
Returnsthe level of access rights (0 = nothing, 10 = everything) (type: int )
def depends(self, dependency): (source)
raise an Exception, if the dependency is not active
def encode_line(self, line, encoding, fallback): (source)
Undocumented
def sendmsg(self, channel, msg, encoding='UTF-8', fallback='iso-8859-15'): (source)
call only this to send messages to channels or users it converts the message from iso-8859-15 to a encoding given in the config
Parameterschannelsend the message to this channel or user (type: string )
msgthe message to send (type: string )
encodingthe encoding of msg (type: string )
fallbacktry this one as encoding for msg, if encoding doesn't work (type: string )
def sendme(self, channel, action, encoding='UTF-8', fallback='iso-8859-15'): (source)
call only this to send actions (/me) to channels it converts the message from iso-8859-15 to a encoding given in the config
Parameterschannelsend the message to this channel or user (type: string )
actionthe message to send (type: string )
encodingthe encoding of msg (type: string )
fallbackthe encoding of msg
def connectionMade(self): (source)
this is called by twisted , when the connection to the irc-server was made
def connectionLost(self, reason): (source)
this is called by twisted, if the connection to the IRC-Server was lost
Parametersreason (type: twisted.python.failure.Failure )
def signedOn(self): (source)
called by twisted, when we signed on the IRC-Server
def joined(self, channel): (source)
called by twisted, if we joined a channel
Parameterschannelthe channel we joined (type: string )
def left(self, channel): (source)
called by twisted, if we left a channel
Parameterschannelthe channel we left (type: string )
def isupport(self, options): (source)
Called with various information about what the server supports.
ParametersoptionsDescriptions of features or limits of the server, possibly in the form "NAME=VALUE". (type: list of str )
def command(self, user, channel, command, options): (source)
callback for !commands
Parametersuserthe user, which issues the command (type: string )
channelthe channel to which the message was sent or my nickname if it was a private message (type: string )
commandthe !command without the ! (type: string )
optionseventual options specified after !command (e.g. "!command foo") (type: string )
def privmsg(self, user, channel, msg): (source)
called by twisted, if we received a message
Parametersuserthe user, which send the message (type: string )
channelthe channel to which the message was sent or my nickname if it was a private message (type: string )
msgthe message (type: string )
def irc_unknown(self, prefix, command, params): (source)
called by twisted for every line that has no own callback
def noticed(self, user, channel, msg): (source)
called by twisted, if we got a notice
Parametersuserthe user which send the notice (type: string )
channelthe channel to which the notice was sent (could be our nick, if the message was only sent to us) (type: string )
msgthe message (type: string )
def action(self, user, channel, message): (source)
called by twisted, if we received a action
Parametersuserthe user which send the action (type: string )
channelthe channel to which the action was sent (could be our nick, if the message was only sent to us) (type: string )
msgthe message (type: string )
def modeChanged(self, user, channel, set, modes, args): (source)
called by twisted if a usermode was changed
def kickedFrom(self, channel, kicker, message): (source)
called by twisted, if the bot was kicked
def userKicked(self, kickee, channel, kicker, message): (source)
called by twisted, if a user was kicked
def userJoined(self, user, channel): (source)
called by twisted, if a user joined the channel
def userLeft(self, user, channel): (source)
called by twisted, if a user left the channel
def userQuit(self, user, quitMessage): (source)
called by twisted, of a user quits
def yourHost(self, info): (source)
called by twisted with information about the IRC-Server we are connected to
def ctcpUnknownQuery(self, user, channel, messages): (source)
called by twisted, if a user sent a ctcp query
def userRenamed(self, oldname, newname): (source)
called by twisted, if a user changed his nick
def topicUpdated(self, user, channel, newTopic): (source)
called by twisted if the topic was updated
def irc_RPL_ENDOFNAMES(self, prefix, params): (source)
Undocumented
def irc_RPL_NAMREPLY(self, prefix, params): (source)
Undocumented
def irc_RPL_USERHOST(self, prefix, params): (source)
Undocumented
def irc_INVITE(self, prefix, params): (source)
called by twisted, if the bot was invited
def irc_RPL_BOUNCE(self, prefix, params): (source)
Overridden to get isupport work correctly
def irc_JOIN(self, prefix, params): (source)
Overridden to get the full hostmask
def irc_PART(self, prefix, params): (source)
Overridden to get the full hostmask
def irc_QUIT(self, prefix, params): (source)
Overridden to get the full hostmask
def lineReceived(self, line): (source)
called by twisted for every line which was received from the IRC-Server
def sendLine(self, line): (source)
Sends a line to the other end of the connection.
def ping(self): (source)
Measure round-trip delay to another IRC client.
def disconnect(self): (source)
disconnects cleanly from the current network
API Documentation for OtfBot - the friendly Bot, generated by pydoctor at 2010-01-04 01:40:56.