Adapter.php in Mail System 8.4
File
src/Adapter.php
View source
<?php
namespace Drupal\mailsystem;
use Drupal\Core\Mail\MailInterface;
class Adapter implements MailInterface {
protected $instanceFormatter;
protected $instanceSender;
public function __construct(MailInterface $formatter, MailInterface $sender) {
$this->instanceFormatter = $formatter;
$this->instanceSender = $sender;
}
public function format(array $message) {
return $this->instanceFormatter
->format($message);
}
public function mail(array $message) {
return $this->instanceSender
->mail($message);
}
}
Classes
Name |
Description |
Adapter |
Provides an adapter to send emails. |