Moodle PHP Documentation 5.1
Moodle 5.1dev (Build: 20250711) (9addea9f0ac)
message_email\output\email_digest Class Reference

Email digest renderable. More...

Inheritance diagram for message_email\output\email_digest:

Public Member Functions

 __construct (\stdClass $userto)
 The email_digest constructor.
 
 add_conversation (\stdClass $conversation)
 Adds another conversation to this digest.
 
 add_message (\stdClass $message)
 Adds another message to this digest, using the conversation id it belongs to as a key.
 
 export_for_template (\renderer_base $renderer)
 Export this data so it can be used as the context for a mustache template.
 

Protected Attributes

array $conversations = array()
 The conversations.
 
array $messages = array()
 The messages.
 
stdClass $userto
 The user we want to send the digest email to.
 

Detailed Description

Email digest renderable.

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

Constructor & Destructor Documentation

◆ __construct()

message_email\output\email_digest::__construct ( \stdClass $userto)

The email_digest constructor.

Parameters
stdClass$userto

Member Function Documentation

◆ add_conversation()

message_email\output\email_digest::add_conversation ( \stdClass $conversation)

Adds another conversation to this digest.

Parameters
stdClass$conversationThe conversation from the 'message_conversations' table.

◆ add_message()

message_email\output\email_digest::add_message ( \stdClass $message)

Adds another message to this digest, using the conversation id it belongs to as a key.

Parameters
stdClass$messageThe message from the 'messages' table.

◆ export_for_template()

message_email\output\email_digest::export_for_template ( \renderer_base $renderer)

Export this data so it can be used as the context for a mustache template.

Parameters
renderer_base$rendererThe render to be used for formatting the email
Return values
stdClassThe data ready for use in a mustache template

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