Class Swift_Transport_EsmtpTransport
Inheritance | Swift_Transport_EsmtpTransport » Swift_Transport_AbstractSmtpTransport |
---|---|
Implements | Swift_Transport, Swift_Transport_SmtpAgent |
Subclasses | Swift_SmtpTransport |
Sends Messages over SMTP with ESMTP support.
Protected Properties
Property | Type | Description | Defined By |
---|---|---|---|
$_buffer | Input-Output buffer for sending/receiving SMTP commands and responses | Swift_Transport_AbstractSmtpTransport | |
$_domain | The domain name to use in HELO command | Swift_Transport_AbstractSmtpTransport | |
$_eventDispatcher | The event dispatching layer | Swift_Transport_AbstractSmtpTransport | |
$_sourceIp | Source Ip | Swift_Transport_AbstractSmtpTransport | |
$_started | Connection status | Swift_Transport_AbstractSmtpTransport |
Public Methods
Protected Methods
Method Details
Mixin handling method for ESMTP handlers
public void __call ( $method, $args ) | ||
$method | ||
$args |
Creates a new EsmtpTransport using the given I/O buffer.
public void __construct ( Swift_Transport_IoBuffer $buf, array $extensionHandlers, Swift_Events_EventDispatcher $dispatcher ) | ||
$buf | Swift_Transport_IoBuffer | |
$extensionHandlers | Swift_Transport_EsmtpHandler[] | |
$dispatcher | Swift_Events_EventDispatcher |
Overridden to perform EHLO instead
protected void _doHeloCommand ( ) |
Overridden to add Extension support
protected void _doMailFromCommand ( $address ) | ||
$address |
Overridden to add Extension support
protected void _doRcptToCommand ( $address ) | ||
$address |
Get the params to initialize the buffer
protected void _getBufferParams ( ) |
Run a command against the buffer, expecting the given response codes.
If no response codes are given, the response will not be validated. If codes are given, an exception will be thrown on an invalid response.
public string executeCommand ( $command, $codes = [], <b>&</b>$failures = null ) | ||
$command | string | |
$codes | int | |
$failures | string[] | An array of failures by-reference |
Get the encryption type.
public string getEncryption ( ) |
Get ESMTP extension handlers.
public Swift_Transport_EsmtpHandler[] getExtensionHandlers ( ) |
Get the host to connect to.
public string getHost ( ) |
Get the port to connect to.
public int getPort ( ) |
Returns the IP used to connect to the destination.
public string getSourceIp ( ) |
Get the connection timeout.
public int getTimeout ( ) |
Set the encryption type (tls or ssl).
public Swift_Transport_EsmtpTransport setEncryption ( $encryption ) | ||
$encryption | string |
Set ESMTP extension handlers.
public Swift_Transport_EsmtpTransport setExtensionHandlers ( array $handlers ) | ||
$handlers | Swift_Transport_EsmtpHandler[] |
Set the host to connect to.
public Swift_Transport_EsmtpTransport setHost ( $host ) | ||
$host | string |
Set the port to connect to.
public Swift_Transport_EsmtpTransport setPort ( $port ) | ||
$port | int |
Sets the source IP.
public Swift_Transport_EsmtpTransport setSourceIp ( $source ) | ||
$source | string |
Set the connection timeout.
public Swift_Transport_EsmtpTransport setTimeout ( $timeout ) | ||
$timeout | int | Seconds |