‪TYPO3CMS  10.4
TYPO3\CMS\Core\Mail\TransportFactory Class Reference
Inheritance diagram for TYPO3\CMS\Core\Mail\TransportFactory:
TYPO3\CMS\Core\SingletonInterface

Public Member Functions

 __construct (EventDispatcherInterface $dispatcher, LogManagerInterface $logManager)
 
TransportInterface get (array $mailSettings)
 

Public Attributes

const SPOOL_MEMORY = 'memory'
 
const SPOOL_FILE = 'file'
 

Protected Member Functions

DelayedTransportInterface createSpool (array $mailSettings)
 

Protected Attributes

EventDispatcherInterface $dispatcher
 
LogManagerInterface $logManager
 

Detailed Description

TransportFactory

Definition at line 36 of file TransportFactory.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Core\Mail\TransportFactory::__construct ( EventDispatcherInterface  $dispatcher,
LogManagerInterface  $logManager 
)

Member Function Documentation

◆ createSpool()

DelayedTransportInterface TYPO3\CMS\Core\Mail\TransportFactory::createSpool ( array  $mailSettings)
protected

Creates a spool from mail settings.

Parameters
array$mailSettings
Returns
DelayedTransportInterface
Exceptions

Definition at line 185 of file TransportFactory.php.

References TYPO3\CMS\Core\Mail\TransportFactory\SPOOL_FILE, and TYPO3\CMS\Core\Mail\TransportFactory\SPOOL_MEMORY.

Referenced by TYPO3\CMS\Core\Mail\TransportFactory\get().

◆ get()

TransportInterface TYPO3\CMS\Core\Mail\TransportFactory::get ( array  $mailSettings)

Gets a transport from settings.

Parameters
array$mailSettings‪from $GLOBALS['TYPO3_CONF_VARS']['MAIL']
Returns
‪TransportInterface
Exceptions
Exception

Definition at line 65 of file TransportFactory.php.

References TYPO3\CMS\Core\Mail\TransportFactory\createSpool(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Core\Mail\Mailer\getRealTransport(), and TYPO3\CMS\Core\Mail\Mailer\initializeTransport().

Member Data Documentation

◆ $dispatcher

EventDispatcherInterface TYPO3\CMS\Core\Mail\TransportFactory::$dispatcher
protected

◆ $logManager

LogManagerInterface TYPO3\CMS\Core\Mail\TransportFactory::$logManager
protected

◆ SPOOL_FILE

const TYPO3\CMS\Core\Mail\TransportFactory::SPOOL_FILE = 'file'

◆ SPOOL_MEMORY

const TYPO3\CMS\Core\Mail\TransportFactory::SPOOL_MEMORY = 'memory'