Makes sure a connection to a POP3 host has been established prior to connecting to SMTP.

package Swift
subpackage Plugins
author Chris Corbyn

 Methods

Create a new PopBeforeSmtpPlugin for $host and $port.

__construct(string $host, int $port, $crypto) 

Parameters

$host

string

$port

int

$crypto

Invoked just before a Transport is started.

beforeTransportStarted(\Swift_Events_TransportChangeEvent $evt) 

Not used.

beforeTransportStopped(\Swift_Events_TransportChangeEvent $evt) 

Bind this plugin to a specific SMTP transport instance.

bindSmtp(\Swift_Transport $smtp) 

Parameters

Connect to the POP3 host and authenticate.

connect() 

Exceptions

\Swift_Plugins_Pop_Pop3Exception if connection fails

Disconnect from the POP3 host.

disconnect() 

Create a new PopBeforeSmtpPlugin for $host and $port.

newInstance(string $host, int $port, $crypto) : \Swift_Plugins_PopBeforeSmtpPlugin
Static

Parameters

$host

string

$port

int

$crypto

Returns

Set a Pop3Connection to delegate to instead of connecting directly.

setConnection(\Swift_Plugins_Pop_Pop3Connection $connection) 

Parameters

Set the password to use when connecting (if needed).

setPassword(string $password) 

Parameters

$password

string

Set the connection timeout in seconds (default 10).

setTimeout(int $timeout) 

Parameters

$timeout

int

Set the username to use when connecting (if needed).

setUsername(string $username) 

Parameters

$username

string

Not used.

transportStarted(\Swift_Events_TransportChangeEvent $evt) 

Not used.

transportStopped(\Swift_Events_TransportChangeEvent $evt) 

_assertOk()

_assertOk($response) 

Parameters

$response

_command()

_command($command) 

Parameters

$command

_getHostString()

_getHostString() 

 Properties

 

$_connection 
 

$_crypto 
 

$_host 
 

$_password 
 

$_port 
 

$_socket 
 

$_timeout 
 

$_transport 
 

$_username