class AbstractDatagramProtocol: (source)
Known subclasses: twisted.internet.protocol.DatagramProtocol
, twisted.pair.ethernet.EthernetProtocol
, twisted.pair.ip.IPProtocol
, twisted.pair.rawudp.RawUDPProtocol
, twisted.pair.test.test_tuntap.IPRecordingProtocol
Abstract protocol for datagram-oriented transports, e.g. IP, ICMP, ARP, UDP.
Method | __getstate__ |
Undocumented |
Method | datagram |
Called when a datagram is received. |
Method | do |
Make sure startProtocol is called. |
Method | do |
Make sure stopProtocol is called. |
Method | make |
Make a connection to a transport and a server. |
Method | start |
Called when a transport is connected to this protocol. |
Method | stop |
Called when the transport is disconnected. |
Class Variable | noisy |
Undocumented |
Instance Variable | num |
Undocumented |
Instance Variable | transport |
Undocumented |
twisted.internet.protocol.ConnectedDatagramProtocol
, twisted.internet.test.test_udp_internals.KeepReads
, twisted.names.dns.DNSDatagramProtocol
, twisted.pair.ethernet.EthernetProtocol
, twisted.pair.ip.IPProtocol
, twisted.pair.rawudp.RawUDPProtocol
, twisted.pair.test.test_rawudp.MyProtocol
, twisted.pair.test.test_tuntap.IPRecordingProtocol
, twisted.protocols.sip.Base
, twisted.test.test_udp.BadClient
, twisted.test.test_udp.Server
, twisted.test.test_unix.ServerProto
Called when a datagram is received.
Parameters | |
datagram:bytes | the bytes received from the transport. |
addr | tuple of source of datagram. |
Make sure startProtocol is called.
This will be called by makeConnection(), users should not call it.
Make a connection to a transport and a server.
This sets the 'transport' attribute of this DatagramProtocol, and calls the doStart() callback.
twisted.names.dns.DNSDatagramProtocol
, twisted.pair.test.test_tuntap.EthernetRecordingProtocol
, twisted.pair.test.test_tuntap.IPRecordingProtocol
, twisted.test.test_unix.ClientProto
, twisted.test.test_unix.ServerProto
Called when a transport is connected to this protocol.
Will only be called once, even if multiple ports are connected.
twisted.names.dns.DNSDatagramProtocol
, twisted.test.test_unix.ClientProto
, twisted.test.test_unix.ServerProto
Called when the transport is disconnected.
Will only be called once, after all ports are disconnected.