Moodle PHP Documentation 4.2
Moodle 4.2.8 (Build: 20240610) (2d41ac46f45)
|
phpmailer message sink. More...
Public Member Functions | |
add_message ($message) | |
To be called from phpunit_util only! | |
clear () | |
Removes all previously stored messages. | |
close () | |
Stop message redirection. | |
count () | |
Return number of messages redirected to this sink. | |
get_messages () | |
Returns all redirected messages. | |
Protected Attributes | |
array | $messages = array() |
of records which would have been sent by phpmailer. | |
phpmailer message sink.
phpunit_phpmailer_sink::add_message | ( | $message | ) |
To be called from phpunit_util only!
stdClass | $message | record from messages table |
phpunit_phpmailer_sink::close | ( | ) |
Stop message redirection.
Use if you do not want message redirected any more.
phpunit_phpmailer_sink::count | ( | ) |
Return number of messages redirected to this sink.
int |
phpunit_phpmailer_sink::get_messages | ( | ) |
Returns all redirected messages.
The instances are records from the messages table. The array indexes are numbered from 0 and the order is matching the creation of events.
array |