/framework/vendor/swift/lib/classes/Swift/Transport/EsmtpHandler.php

http://zoop.googlecode.com/ · PHP · 82 lines · 14 code · 13 blank · 55 comment · 0 complexity · 389ca2abb830f019d77d2de056294dfc MD5 · raw file

  1. <?php
  2. /*
  3. * This file is part of SwiftMailer.
  4. * (c) 2004-2009 Chris Corbyn
  5. *
  6. * For the full copyright and license information, please view the LICENSE
  7. * file that was distributed with this source code.
  8. */
  9. //@require 'Swift/Transport/EsmtpBufferWrapper.php';
  10. /**
  11. * An ESMTP handler.
  12. * @package Swift
  13. * @subpackage Transport
  14. * @author Chris Corbyn
  15. */
  16. interface Swift_Transport_EsmtpHandler
  17. {
  18. /**
  19. * Get the name of the ESMTP extension this handles.
  20. * @return boolean
  21. */
  22. public function getHandledKeyword();
  23. /**
  24. * Set the parameters which the EHLO greeting indicated.
  25. * @param string[] $parameters
  26. */
  27. public function setKeywordParams(array $parameters);
  28. /**
  29. * Runs immediately after a EHLO has been issued.
  30. * @param Swift_Transport_SmtpAgent $agent to read/write
  31. */
  32. public function afterEhlo(Swift_Transport_SmtpAgent $agent);
  33. /**
  34. * Get params which are appended to MAIL FROM:<>.
  35. * @return string[]
  36. */
  37. public function getMailParams();
  38. /**
  39. * Get params which are appended to RCPT TO:<>.
  40. * @return string[]
  41. */
  42. public function getRcptParams();
  43. /**
  44. * Runs when a command is due to be sent.
  45. * @param Swift_Transport_SmtpAgent $agent to read/write
  46. * @param string $command to send
  47. * @param int[] $codes expected in response
  48. * @param string[] &$failedRecipients
  49. * @param boolean &$stop to be set true if the command is now sent
  50. */
  51. public function onCommand(Swift_Transport_SmtpAgent $agent,
  52. $command, $codes = array(), &$failedRecipients = null, &$stop = false);
  53. /**
  54. * Returns +1, -1 or 0 according to the rules for usort().
  55. * This method is called to ensure extensions can be execute in an appropriate order.
  56. * @param string $esmtpKeyword to compare with
  57. * @return int
  58. */
  59. public function getPriorityOver($esmtpKeyword);
  60. /**
  61. * Returns an array of method names which are exposed to the Esmtp class.
  62. * @return string[]
  63. */
  64. public function exposeMixinMethods();
  65. /**
  66. * Tells this handler to clear any buffers and reset its state.
  67. */
  68. public function resetState();
  69. }