Sockets carry bytes. This is the only thing they carry. Any two TCP connection endpoints can only transmit bytes to each other.
Bytes are not the most useful data structure for each form of communication. Thus, in addition to this byte transport, we invent formatting and interpretation schemes for bytes. These are the protocols.
Twisted , almsot twisted.internet.protocol.Protocol, .
-, , , . , twisted.protocols.basic.NetstringReceiver netstring. , , . , , - , .
, , dataReceived , , . NetstringReceiver , , stringReceived Python str.
, NetstringReceiver. , twisted.protocols.ftp FTP. FTP - , ( ). twisted.mail.pop3 POP3, .
, , , , . , , , , , ( ). , . " ", , , , , , , , , ..
, , . , .
, Python, , Twisted Spread .
- , , , , XML-RPC (Twisted How-To) .
, , XML-RPC, , AMP .
.:)