TYPO3 API  SVNRelease
SmtpAgent.php
Go to the documentation of this file.
00001 <?php
00002 
00003 /*
00004  * This file is part of SwiftMailer.
00005  * (c) 2004-2009 Chris Corbyn
00006  *
00007  * For the full copyright and license information, please view the LICENSE
00008  * file that was distributed with this source code.
00009  */
00010 
00011 /**
00012  * Wraps an IoBuffer to send/receive SMTP commands/responses.
00013  * @package Swift
00014  * @subpackage Transport
00015  * @author Chris Corbyn
00016  */
00017 interface Swift_Transport_SmtpAgent
00018 {
00019 
00020   /**
00021    * Get the IoBuffer where read/writes are occurring.
00022    * @return Swift_Transport_IoBuffer
00023    */
00024   public function getBuffer();
00025 
00026   /**
00027    * Run a command against the buffer, expecting the given response codes.
00028    * If no response codes are given, the response will not be validated.
00029    * If codes are given, an exception will be thrown on an invalid response.
00030    * @param string $command
00031    * @param int[] $codes
00032    * @param string[] &$failures
00033    */
00034   public function executeCommand($command, $codes = array(), &$failures = null);
00035 
00036 }