| Home | Trees | Index | Help |
|
|---|
| Package twisted :: Package protocols :: Module irc :: Class DccChat |
|
Ephemeral --+
|
BaseProtocol --+ |
| |
Protocol --+ |
| |
LineReceiver --+
|
DccChat
Direct Client Connection protocol type CHAT.
DCC CHAT is really just your run o' the mill basic.LineReceiver protocol. This class only varies from that slightly, accepting either LF or CR LF for a line delimeter for incoming messages while always using CR LF for outgoing.
The lineReceived method implemented here uses the DCC connection's 'client' attribute (provided upon construction) to deliver incoming lines from the DCC chat via IRCClient's normal privmsg interface. That's something of a spoof, which you may well want to override.| Method Summary | |
|---|---|
Initialize a new DCC CHAT session. | |
Protocol.dataReceived. | |
Override this for when each line is received. | |
| Inherited from LineReceiver | |
Clear buffered data. | |
Called when the maximum line length has been reached. | |
Override this for when raw data is received. | |
Sends a line to the other end of the connection. | |
Sets the line-mode of this receiver. | |
Sets the raw mode of this receiver. | |
| Inherited from Protocol | |
(Deprecated) | |
Called when the connection is shut down. | |
| Inherited from BaseProtocol | |
Called when a connection is made. | |
Make a connection to a transport and a server. | |
| Inherited from Ephemeral | |
| |
| |
| Class Variable Summary | |
|---|---|
str |
buffer = ''
|
NoneType |
client = None |
str |
delimiter: The line-ending delimiter to use. |
NoneType |
queryData = None |
NoneType |
remoteParty = None |
| Inherited from LineReceiver | |
str |
_LineReceiver__buffer = ''
|
int |
line_mode = 1 |
int |
MAX_LENGTH: The maximum length of a line to allow (If a sent line is longer than
this, the connection is dropped). |
| Inherited from Protocol | |
tuple |
__implements__ = (<class twisted.internet.interfaces.IPr...
|
| Inherited from BaseProtocol | |
int |
connected = 0 |
NoneType |
transport = None |
| Method Details |
|---|
__init__(self,
client,
queryData=None)
|
dataReceived(self, data)Protocol.dataReceived. Translates bytes into lines, and calls lineReceived (or rawDataReceived, depending on mode.)
|
lineReceived(self, line)Override this for when each line is received.
|
| Class Variable Details |
|---|
buffer
|
client
|
delimiterThe line-ending delimiter to use. By default this is '\r\n'.
|
queryData
|
remoteParty
|
| Home | Trees | Index | Help |
|
|---|
| Generated by Epydoc 2.0 on Sat May 15 20:08:19 2004 | http://epydoc.sf.net |