XOOPS RMCommon Utilities
2.1.8.91RC
|
Public Member Functions | |
__construct (Swift_Transport $transport) | |
batchSend (Swift_Mime_Message $message, &$failedRecipients=null, Swift_Mailer_RecipientIterator $it=null) | |
getTransport () | |
registerPlugin (Swift_Events_EventListener $plugin) | |
send (Swift_Mime_Message $message, &$failedRecipients=null) | |
Static Public Member Functions | |
static | newInstance (Swift_Transport $transport) |
Private Attributes | |
$_transport | |
Definition at line 22 of file Mailer.php.
Swift_Mailer::__construct | ( | Swift_Transport | $transport | ) |
Create a new Mailer using $transport for delivery.
Swift_Transport | $transport |
Definition at line 33 of file Mailer.php.
Swift_Mailer::batchSend | ( | Swift_Mime_Message | $message, |
& | $failedRecipients = null , |
||
Swift_Mailer_RecipientIterator | $it = null |
||
) |
Send the given Message to all recipients individually.
This differs from send() in the way headers are presented to the recipient. The only recipient in the "To:" field will be the individual recipient it was sent to.
If an iterator is provided, recipients will be read from the iterator one-by-one, otherwise recipient data will be retreived from the Message object.
Sender information is always read from the Message object.
The return value is the number of recipients who were accepted for delivery.
Swift_Mime_Message | $message | |
array | &$failedRecipients,optional | |
Swift_Mailer_RecipientIterator | $it,optional |
Definition at line 102 of file Mailer.php.
References Swift_Mime_Message\getBcc(), Swift_Mime_Message\getCc(), Swift_Mime_Message\getTo(), send(), Swift_Mime_Message\setBcc(), Swift_Mime_Message\setCc(), and Swift_Mime_Message\setTo().
Swift_Mailer::getTransport | ( | ) |
The Transport used to send messages.
Definition at line 169 of file Mailer.php.
References $_transport.
|
static |
Create a new Mailer instance.
Swift_Transport | $transport |
Definition at line 44 of file Mailer.php.
Referenced by RMMailer\batchSend(), and RMMailer\send().
Swift_Mailer::registerPlugin | ( | Swift_Events_EventListener | $plugin | ) |
Register a plugin using a known unique key (e.g. myPlugin).
Swift_Events_EventListener | $plugin | |
string | $key |
Definition at line 160 of file Mailer.php.
Swift_Mailer::send | ( | Swift_Mime_Message | $message, |
& | $failedRecipients = null |
||
) |
Send the given Message like it would be sent in a mail client.
All recipients (with the exception of Bcc) will be able to see the other recipients this message was sent to.
If you need to send to each recipient without disclosing details about the other recipients see batchSend().
Recipient/sender data will be retreived from the Message object.
The return value is the number of recipients who were accepted for delivery.
Swift_Mime_Message | $message | |
array | &$failedRecipients,optional |
Definition at line 68 of file Mailer.php.
Referenced by batchSend().
|
private |
The Transport used to send messages
Definition at line 26 of file Mailer.php.
Referenced by getTransport().