class documentation
class SimpleDelivery: (source)
Implements interfaces: twisted.mail.interfaces.IMessageDelivery
SimpleDelivery
is a message delivery factory with no interesting behavior.
Method | __init__ |
Undocumented |
Method | received |
Generate the Received header for a message. |
Method | validate |
Validate the address from which the message originates. |
Method | validate |
Validate the address for which the message is destined. |
Instance Variable | _message |
Undocumented |
Generate the Received header for a message.
Parameters | |
helo:2-tuple of bytes and bytes . | The argument to the HELO command and the client's IP address. |
origin:Address | The address the message is from |
recipients:list of User | A list of the addresses for which this message is bound. |
Returns | |
bytes | The full "Received" header string. |
Validate the address from which the message originates.
Parameters | |
helo:2-tuple of bytes and bytes . | The argument to the HELO command and the client's IP address. |
origin:Address | The address the message is from |
Returns | |
Deferred or Address | origin or a Deferred whose callback will be passed origin. |
Raises | |
SMTPBadSender | Raised of messages from this address are not to be accepted. |
Validate the address for which the message is destined.
Parameters | |
user:User | The address to validate. |
Returns | |
no-argument callable | A Deferred which becomes, or a callable which takes no arguments and returns an object implementing IMessageSMTP . This will be called and the returned object used to deliver the message when it arrives. |
Raises | |
SMTPBadRcpt | Raised if messages to the address are not to be accepted. |