1 <?php
2 /* --------------------------------------------------------------
3 AttachmentNotFoundException.inc.php 2015-06-02 gm
4 Gambio GmbH
5 http://www.gambio.de
6 Copyright (c) 2015 Gambio GmbH
7 Released under the GNU General Public License (Version 2)
8 [http://www.gnu.org/licenses/gpl-2.0.html]
9 --------------------------------------------------------------
10 */
11
12 /**
13 * Class AttachmentNotFoundException
14 *
15 * Is thrown whenever an email attachment file could not be found on the server.
16 *
17 * @category System
18 * @package Email
19 * @subpackage Exceptions
20 */
21 class AttachmentNotFoundException extends Exception
22 {
23 /**
24 * Attachment path.
25 * @var string
26 */
27 protected $attachmentPath;
28
29
30 /**
31 * Class Constructor
32 *
33 * @param string $message (optional) Message of the exception instance.
34 * @param string $attachmentPath (optional) The attachment path that could not be found.
35 */
36 public function __construct($message = '', $attachmentPath = '')
37 {
38 parent::__construct($message);
39 $this->attachmentPath = $attachmentPath;
40 }
41
42
43 /**
44 * Get attachment path that could not be found.
45 *
46 * @return string Attachment path.
47 */
48 public function getAttachmentPath()
49 {
50 return (string)$this->attachmentPath;
51 }
52 }