The mod_forum discussion pinned event.
More...
◆ __get()
core\event\base::__get |
( |
|
$name | ) |
|
|
inherited |
Magic getter for read only access.
- Parameters
-
- Return values
-
◆ __isset()
core\event\base::__isset |
( |
|
$name | ) |
|
|
inherited |
Is data property set?
- Parameters
-
- Return values
-
◆ __set()
core\event\base::__set |
( |
|
$name, |
|
|
|
$value |
|
) |
| |
|
inherited |
Magic setter.
Note: we must not allow modification of data from outside, after trigger() the data MUST NOT CHANGE!!!
- Parameters
-
- Exceptions
-
◆ add_record_snapshot()
core\event\base::add_record_snapshot |
( |
|
$tablename, |
|
|
|
$record |
|
) |
| |
|
finalinherited |
Add cached data that will be most probably used in event observers.
This is used to improve performance, but it is required for data that was just deleted.
- Parameters
-
string | $tablename | |
stdClass | $record | |
- Exceptions
-
◆ can_view()
core\event\base::can_view |
( |
|
$user_or_id = null | ) |
|
|
inherited |
◆ create()
static core\event\base::create |
( |
array |
$data = null | ) |
|
|
staticfinalinherited |
Create new event.
The optional data keys as: 1/ objectid - the id of the object specified in class name 2/ context - the context of this event 3/ other - the other data describing the event, can not contain objects 4/ relateduserid - the id of user which is somehow related to this event
- Parameters
-
- Return values
-
◆ get_context()
core\event\base::get_context |
( |
| ) |
|
|
inherited |
Returns event context.
- Return values
-
◆ get_data()
core\event\base::get_data |
( |
| ) |
|
|
inherited |
Return standardised event data as array.
- Return values
-
array | All elements are scalars except the 'other' field which is array. |
◆ get_description()
mod_forum\event\discussion_pinned::get_description |
( |
| ) |
|
Returns description of what happened.
- Return values
-
Reimplemented from core\event\base.
◆ get_explanation()
static core\event\base::get_explanation |
( |
| ) |
|
|
staticinherited |
Get an explanation of what the class does.
By default returns the phpdocs from the child event class. Ideally this should be overridden to return a translatable get_string style markdown. e.g. return new lang_string('eventyourspecialevent', 'plugin_type');
- Return values
-
string | An explanation of the event formatted in markdown style. |
◆ get_legacy_eventdata()
core\event\base::get_legacy_eventdata |
( |
| ) |
|
|
protectedinherited |
Legacy event data if get_legacy_eventname() is not empty.
Note: do not use directly!
- Return values
-
Reimplemented in mod_workshop\event\course_module_viewed, mod_workshop\event\assessable_uploaded, mod_quiz\event\attempt_submitted, mod_quiz\event\attempt_started, mod_quiz\event\attempt_becameoverdue, mod_quiz\event\attempt_abandoned, mod_lti\event\unknown_service_api_called, mod_forum\event\assessable_uploaded, assignsubmission_onlinetext\event\assessable_uploaded, assignsubmission_file\event\assessable_uploaded, mod_assign\event\assessable_submitted, core\event\user_updated, core\event\user_loggedout, core\event\user_enrolment_updated, core\event\user_enrolment_deleted, core\event\user_enrolment_created, core\event\user_deleted, core\event\user_created, core\event\role_unassigned, core\event\role_assigned, core\event\grouping_updated, core\event\grouping_deleted, core\event\grouping_created, core\event\group_updated, core\event\group_member_removed, core\event\group_member_added, core\event\group_deleted, core\event\group_created, core\event\course_updated, core\event\course_restored, core\event\course_module_updated, core\event\course_module_deleted, core\event\course_module_created, core\event\course_module_completion_updated, core\event\course_deleted, core\event\course_created, core\event\course_content_deleted, core\event\course_completed, core\event\course_category_deleted, core\event\cohort_updated, core\event\cohort_member_removed, core\event\cohort_member_added, core\event\cohort_deleted, core\event\cohort_created, core\event\blog_entry_updated, core\event\blog_entry_deleted, and core\event\blog_entry_created.
◆ get_legacy_eventname()
static core\event\base::get_legacy_eventname |
( |
| ) |
|
|
staticinherited |
Does this event replace legacy event?
Note: do not use directly!
- Return values
-
null|string | legacy event name |
Reimplemented in mod_workshop\event\course_module_viewed, mod_workshop\event\assessable_uploaded, mod_quiz\event\attempt_submitted, mod_quiz\event\attempt_started, mod_quiz\event\attempt_becameoverdue, mod_quiz\event\attempt_abandoned, mod_lti\event\unknown_service_api_called, mod_forum\event\assessable_uploaded, assignsubmission_onlinetext\event\assessable_uploaded, assignsubmission_file\event\assessable_uploaded, mod_assign\event\assessable_submitted, core\event\user_updated, core\event\user_loggedout, core\event\user_enrolment_updated, core\event\user_enrolment_deleted, core\event\user_enrolment_created, core\event\user_deleted, core\event\user_created, core\event\role_unassigned, core\event\role_assigned, core\event\grouping_updated, core\event\grouping_deleted, core\event\grouping_created, core\event\group_updated, core\event\group_member_removed, core\event\group_member_added, core\event\group_deleted, core\event\group_created, core\event\course_updated, core\event\course_restored, core\event\course_module_updated, core\event\course_module_deleted, core\event\course_module_created, core\event\course_module_completion_updated, core\event\course_deleted, core\event\course_created, core\event\course_content_deleted, core\event\course_completed, core\event\course_category_deleted, core\event\cohort_updated, core\event\cohort_member_removed, core\event\cohort_member_added, core\event\cohort_deleted, core\event\cohort_created, core\event\blog_entry_updated, core\event\blog_entry_deleted, core\event\blog_entry_created, core_h5p\event\h5p_viewed, and core_h5p\event\h5p_deleted.
◆ get_legacy_logdata()
mod_forum\event\discussion_pinned::get_legacy_logdata |
( |
| ) |
|
|
protected |
Return the legacy event log data.
- Return values
-
Reimplemented from core\event\base.
◆ get_logextra()
core\event\base::get_logextra |
( |
| ) |
|
|
inherited |
Return auxiliary data that was stored in logs.
List of standard properties:
- origin: IP number, cli,cron
- realuserid: id of the user when logged-in-as
- Return values
-
array | the format is standardised by logging API |
◆ get_name()
static mod_forum\event\discussion_pinned::get_name |
( |
| ) |
|
|
static |
Return localised event name.
- Return values
-
Reimplemented from core\event\base.
◆ get_name_with_info()
static core\event\base::get_name_with_info |
( |
| ) |
|
|
staticinherited |
Returns the event name complete with metadata information.
This includes information about whether the event has been deprecated so should not be used in all situations - for example within reports themselves.
If overriding this function, please ensure that you call the parent version too.
- Return values
-
◆ get_objectid_mapping()
static mod_forum\event\discussion_pinned::get_objectid_mapping |
( |
| ) |
|
|
static |
Forum discussion object id mappings.
- Return values
-
Reimplemented from core\event\base.
◆ get_other_mapping()
static mod_forum\event\discussion_pinned::get_other_mapping |
( |
| ) |
|
|
static |
◆ get_record_snapshot()
core\event\base::get_record_snapshot |
( |
|
$tablename, |
|
|
|
$id |
|
) |
| |
|
finalinherited |
Returns cached record or fetches data from database if not cached.
- Parameters
-
- Return values
-
- Exceptions
-
◆ get_static_info()
static core\event\base::get_static_info |
( |
| ) |
|
|
staticfinalinherited |
Get static information about an event.
This is used in reports and is not for general use.
- Return values
-
array | Static information about the event. |
◆ get_url()
mod_forum\event\discussion_pinned::get_url |
( |
| ) |
|
Get URL related to the action.
- Return values
-
Reimplemented from core\event\base.
◆ getIterator()
core\event\base::getIterator |
( |
| ) |
|
|
inherited |
Create an iterator because magic vars can't be seen by 'foreach'.
- Return values
-
◆ init()
mod_forum\event\discussion_pinned::init |
( |
| ) |
|
|
protected |
◆ is_deprecated()
static core\event\base::is_deprecated |
( |
| ) |
|
|
staticinherited |
◆ is_dispatched()
core\event\base::is_dispatched |
( |
| ) |
|
|
finalinherited |
Used from event manager to prevent direct access.
- Return values
-
◆ is_restored()
core\event\base::is_restored |
( |
| ) |
|
|
finalinherited |
Was this event restored?
- Return values
-
◆ is_triggered()
core\event\base::is_triggered |
( |
| ) |
|
|
finalinherited |
Was this event already triggered?
- Return values
-
◆ restore()
static core\event\base::restore |
( |
array |
$data, |
|
|
array |
$logextra |
|
) |
| |
|
staticfinalinherited |
Restore event from existing historic data.
- Parameters
-
array | $data | |
array | $logextra | the format is standardised by logging API |
- Return values
-
◆ restore_legacy()
static core\event\base::restore_legacy |
( |
|
$legacy | ) |
|
|
staticfinalinherited |
Create fake event from legacy log data.
- Parameters
-
- Return values
-
◆ restore_unknown()
static core\event\base::restore_unknown |
( |
array |
$data, |
|
|
array |
$logextra |
|
) |
| |
|
staticfinalprotectedinherited |
Restore unknown event.
- Parameters
-
array | $data | |
array | $logextra | |
- Return values
-
◆ validate_before_trigger()
core\event\base::validate_before_trigger |
( |
| ) |
|
|
finalprotectedinherited |
Validate all properties right before triggering the event.
This throws coding exceptions for fatal problems and debugging for minor problems.
- Exceptions
-
◆ validate_data()
mod_forum\event\discussion_pinned::validate_data |
( |
| ) |
|
|
protected |
Custom validation.
- Exceptions
-
- Return values
-
Reimplemented from core\event\base.
◆ LEVEL_PARTICIPATING
const core\event\base::LEVEL_PARTICIPATING = 2 |
|
inherited |
Participating level.
Any event that is performed by a user, and is related (or could be related) to his learning experience.
◆ LEVEL_TEACHING
const core\event\base::LEVEL_TEACHING = 1 |
|
inherited |
Teaching level.
Any event that is performed by someone (typically a teacher) and has a teaching value, anything that is affecting the learning experience/environment of the students.
The documentation for this class was generated from the following file: