\Swift_Plugins_PopBeforeSmtpPlugin
Makes sure a connection to a POP3 host has been established prior to connecting to SMTP.
- Author: Chris Corbyn
Synopsis
class Swift_Plugins_PopBeforeSmtpPlugin
implements
Swift_Events_TransportChangeListener,Swift_Plugins_Pop_Pop3Connection
{
- // members
- private $_connection;
- private $_host;
- private $_port;
- private $_crypto;
- private $_username;
- private $_password;
- private $_socket;
- private integer $_timeout;
- private $_transport;
- // methods
- public void __construct()
- public static Swift_Plugins_PopBeforeSmtpPlugin newInstance()
- public Swift_Plugins_PopBeforeSmtpPlugin setConnection()
- public void bindSmtp()
- public Swift_Plugins_PopBeforeSmtpPlugin setTimeout()
- public Swift_Plugins_PopBeforeSmtpPlugin setUsername()
- public Swift_Plugins_PopBeforeSmtpPlugin setPassword()
- public void connect()
- public void disconnect()
- public void beforeTransportStarted()
- public void transportStarted()
- public void beforeTransportStopped()
- public void transportStopped()
- private void _command()
- private void _assertOk()
- private void _getHostString()
Hierarchy
Members
private
-
$_connection
A delegate connection to use (mostly a test hook) -
$_crypto
Encryption type to use (if any) -
$_host
Hostname of the POP3 server -
$_password
Password to use (if any) -
$_port
Port number to connect on -
$_socket
Established connection via TCP socket -
$_timeout
Connect timeout in seconds -
$_transport
SMTP Transport to bind to -
$_username
Username to use (if any)
Methods
private
public
- __construct() — Create a new PopBeforeSmtpPlugin for $host and $port.
- beforeTransportStarted() — Invoked just before a Transport is started.
- beforeTransportStopped() — Not used.
- bindSmtp() — Bind this plugin to a specific SMTP transport instance.
- connect() — Connect to the POP3 host and authenticate.
- disconnect() — Disconnect from the POP3 host.
- newInstance() — Create a new PopBeforeSmtpPlugin for $host and $port.
- setConnection() — Set a Pop3Connection to delegate to instead of connecting directly.
- setPassword() — Set the password to use when connecting (if needed).
- setTimeout() — Set the connection timeout in seconds (default 10).
- setUsername() — Set the username to use when connecting (if needed).
- transportStarted() — Not used.
- transportStopped() — Not used.