Moodle PHP Documentation 4.2
Moodle 4.2.8 (Build: 20240610) (2d41ac46f45)
message_output_email Class Reference

The email message processor. More...

Inheritance diagram for message_output_email:
message_output

Public Member Functions

 can_send_to_any_users ()
 Returns true as message can be sent to internal support user.
 
 cleanup_all_notifications (int $notificationdeletetime)
 Allow processors to perform cleanup tasks for all notifications by overriding this method.
 
 cleanup_read_notifications (int $notificationdeletetime)
 Allow processors to perform cleanup tasks for read notifications by overriding this method.
 
 config_form ($preferences)
 Creates necessary fields in the messaging config form.
 
 force_process_messages ()
 Determines if this processor should process a message regardless of user preferences or site settings.
 
 get_default_messaging_settings ()
 Returns the default message output settings for this output.
 
 has_message_preferences ()
 Returns true if this processor has configurable message preferences.
 
 is_system_configured ()
 Are the message processor's system settings configured?
 
 is_user_configured ($user=null)
 Are the message processor's user specific settings configured?
 
 load_data (&$preferences, $userid)
 Loads the config data from database to put on the form during initial form display.
 
 process_form ($form, &$preferences)
 Parses the submitted form data and saves it into preferences array.
 
 send_message ($eventdata)
 Processes the message (sends by email).
 

Detailed Description

The email message processor.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Member Function Documentation

◆ can_send_to_any_users()

message_output_email::can_send_to_any_users ( )

Returns true as message can be sent to internal support user.

Return values
bool

Reimplemented from message_output.

◆ cleanup_all_notifications()

message_output::cleanup_all_notifications ( int $notificationdeletetime)
inherited

Allow processors to perform cleanup tasks for all notifications by overriding this method.

Since
Moodle 3.9
Parameters
int$notificationdeletetime
Return values
void

◆ cleanup_read_notifications()

message_output::cleanup_read_notifications ( int $notificationdeletetime)
inherited

Allow processors to perform cleanup tasks for read notifications by overriding this method.

Since
Moodle 3.9
Parameters
int$notificationdeletetime
Return values
void

◆ config_form()

message_output_email::config_form ( $preferences)

Creates necessary fields in the messaging config form.

Parameters
array$preferencesAn array of user preferences

Reimplemented from message_output.

◆ force_process_messages()

message_output::force_process_messages ( )
inherited

Determines if this processor should process a message regardless of user preferences or site settings.

Return values
bool

◆ get_default_messaging_settings()

message_output_email::get_default_messaging_settings ( )

Returns the default message output settings for this output.

Return values
intThe default settings

Reimplemented from message_output.

◆ has_message_preferences()

message_output::has_message_preferences ( )
inherited

Returns true if this processor has configurable message preferences.

This is distinct from notification preferences.

Return values
bool

◆ is_system_configured()

message_output::is_system_configured ( )
inherited

Are the message processor's system settings configured?

Return values
boolTrue if all necessary config settings been entered

Reimplemented in message_output_airnotifier.

◆ is_user_configured()

message_output::is_user_configured ( $user = null)
inherited

Are the message processor's user specific settings configured?

Parameters
stdClass$userthe user object, defaults to $USER.
Return values
boolTrue if the user has all necessary settings in their messaging preferences

◆ load_data()

message_output_email::load_data ( & $preferences,
$userid )

Loads the config data from database to put on the form during initial form display.

Parameters
array$preferencespreferences array
int$useridthe user id

Reimplemented from message_output.

◆ process_form()

message_output_email::process_form ( $form,
& $preferences )

Parses the submitted form data and saves it into preferences array.

Parameters
stdClass$formpreferences form class
array$preferencespreferences array

Reimplemented from message_output.

◆ send_message()

message_output_email::send_message ( $eventdata)

Processes the message (sends by email).

Parameters
object$eventdatathe event data submitted by the message sender plus $eventdata->savedmessageid

Reimplemented from message_output.


The documentation for this class was generated from the following file: