1 | <?php |
||
9 | class Email |
||
10 | { |
||
11 | /** |
||
12 | * Application Object |
||
13 | * |
||
14 | * @var \System\Application |
||
15 | */ |
||
16 | private $app; |
||
17 | |||
18 | /** |
||
19 | * PHPMailer Object |
||
20 | * |
||
21 | * @var PHPMailer |
||
22 | */ |
||
23 | private $mail; |
||
24 | |||
25 | /** |
||
26 | * Constructor |
||
27 | * |
||
28 | * @param \System\Application $app |
||
29 | */ |
||
30 | public function __construct(Application $app) |
||
38 | |||
39 | /** |
||
40 | * Set up the configrations |
||
41 | * |
||
42 | * @property object $error |
||
43 | * @return void |
||
44 | */ |
||
45 | private function setUp() |
||
57 | |||
58 | /** |
||
59 | * To add addresses or attachments easily to the object |
||
60 | * |
||
61 | * @param string|array $input |
||
62 | * @param string $method |
||
63 | * @return void |
||
64 | */ |
||
65 | private function add($input, $method) |
||
79 | |||
80 | /** |
||
81 | * Add addresses |
||
82 | * |
||
83 | * @param string|array $addresses |
||
84 | * @return object $this |
||
85 | */ |
||
86 | public function address($addresses) |
||
92 | |||
93 | /** |
||
94 | * Add addresses |
||
95 | * |
||
96 | * @param array $replayTo |
||
97 | * @return object $this |
||
98 | */ |
||
99 | public function replayTo(array $replayTo = []) |
||
105 | |||
106 | /** |
||
107 | * Add attachments to email |
||
108 | * |
||
109 | * @param string|array $attachments |
||
110 | * @return object $this |
||
111 | */ |
||
112 | public function attachments($attachments) |
||
118 | |||
119 | /** |
||
120 | * Add bcc to email |
||
121 | * |
||
122 | * @param string|array $bcc |
||
123 | * @return object $this |
||
124 | */ |
||
125 | public function bcc($bcc) |
||
131 | |||
132 | /** |
||
133 | * Add cc to email |
||
134 | * |
||
135 | * @param string|array $cc |
||
136 | * @return object $this |
||
137 | */ |
||
138 | public function cc($cc) |
||
144 | |||
145 | /** |
||
146 | * Add content to email |
||
147 | * |
||
148 | * @param string $html |
||
149 | * @param string $subject |
||
150 | * @param string $body |
||
151 | * @param string $altBody |
||
152 | * @return object $this |
||
153 | */ |
||
154 | public function content(string $html, string $subject, string $body, string $altBody) |
||
163 | |||
164 | /** |
||
165 | * Send email |
||
166 | * |
||
167 | * @return void |
||
168 | */ |
||
169 | public function send() |
||
177 | } |
||
178 |
Since your code implements the magic getter
_get
, this function will be called for any read access on an undefined variable. You can add the@property
annotation to your class or interface to document the existence of this variable.If the property has read access only, you can use the @property-read annotation instead.
Of course, you may also just have mistyped another name, in which case you should fix the error.
See also the PhpDoc documentation for @property.