Moodle PHP Documentation 4.3
Moodle 4.3.5 (Build: 20240610) (7dcfaa79f78)
|
Forum class. More...
Public Member Functions | |
__construct (context $context, stdClass $coursemodule, stdClass $course, int $effectivegroupmode, int $id, int $courseid, string $type, string $name, string $intro, int $introformat, int $assessed, int $assesstimestart, int $assesstimefinish, int $scale, int $gradeforum, bool $gradeforumnotify, int $maxbytes, int $maxattachments, int $forcesubscribe, int $trackingtype, int $rsstype, int $rssarticles, int $timemodified, int $warnafter, int $blockafter, int $blockperiod, int $completiondiscussions, int $completionreplies, int $completionposts, bool $displaywordcount, int $lockdiscussionafter, int $duedate, int $cutoffdate) | |
Constructor. | |
get_assess_time_finish () | |
Get the timestamp for when the assessment period ends. | |
get_assess_time_start () | |
Get the timestamp for when the assessment period begins. | |
get_block_after () | |
Get block after. | |
get_block_period () | |
Get the block period. | |
get_completion_discussions () | |
Get the completion discussions. | |
get_completion_posts () | |
Get the completion posts. | |
get_completion_replies () | |
Get the completion replies. | |
get_context () | |
Get the forum module context. | |
get_course_id () | |
Get the id of the course that the forum belongs to. | |
get_course_module_record () | |
Get the forum course module record. | |
get_course_record () | |
Get the course record. | |
get_cutoff_date () | |
Get the cutoff date. | |
get_due_date () | |
Get the due date. | |
get_effective_group_mode () | |
Get the effective group mode. | |
get_grade_for_forum () | |
Get the grade for the forum when grading holistically. | |
get_id () | |
Get the forum id. | |
get_intro () | |
Get the forum intro text. | |
get_intro_format () | |
Get the forum intro text format. | |
get_lock_discussions_after () | |
Get the timestamp after which the discussion should be locked. | |
get_max_attachments () | |
Get the maximum number of attachments. | |
get_max_bytes () | |
Get the maximum bytes. | |
get_name () | |
Get the forum name. | |
get_rating_aggregate () | |
Get the rating aggregate. | |
get_rss_articles () | |
Get the RSS articles. | |
get_rss_type () | |
Get the RSS type. | |
get_scale () | |
Get the rating scale. | |
get_subscription_mode () | |
Get the subscription mode. | |
get_time_modified () | |
Get the timestamp for when the forum was last modified. | |
get_tracking_type () | |
Get the tracking type. | |
get_type () | |
Get the forum type. | |
get_warn_after () | |
Get warn after. | |
has_blocking_enabled () | |
Does the forum have blocking enabled? | |
has_cutoff_date () | |
Does the forum have a cutoff date? | |
has_due_date () | |
Does the forum have a due date? | |
has_lock_discussions_after () | |
Does the forum have a discussion locking timestamp? | |
has_rating_aggregate () | |
Does the forum have a rating aggregate? | |
is_cutoff_date_reached () | |
Is the cutoff date for the forum reached? | |
is_discussion_locked (discussion_entity $discussion) | |
Is the discussion locked? - Takes into account both discussion settings AND forum's criteria. | |
is_discussion_time_locked (discussion_entity $discussion) | |
Check whether the discussion is locked based on forum's time based locking criteria. | |
is_due_date_reached () | |
Is the due date for the forum reached? | |
is_grading_enabled () | |
Whether grading is enabled for this item. | |
is_in_group_mode () | |
Check if the forum is set to group mode. | |
is_subscription_automatic () | |
Is the subscription mode set to automatic. | |
is_subscription_disabled () | |
Is the subscription mode set to disabled. | |
is_subscription_forced () | |
Is the subscription mode set to forced. | |
is_subscription_optional () | |
Is the subscription mode set to optional. | |
should_display_word_count () | |
Should the word counts be shown in the posts? | |
should_notify_students_default_when_grade_for_forum () | |
Get the default for whether the students should be notified when grading holistically. | |
Forum class.
mod_forum\local\entities\forum::__construct | ( | context | $context, |
stdClass | $coursemodule, | ||
stdClass | $course, | ||
int | $effectivegroupmode, | ||
int | $id, | ||
int | $courseid, | ||
string | $type, | ||
string | $name, | ||
string | $intro, | ||
int | $introformat, | ||
int | $assessed, | ||
int | $assesstimestart, | ||
int | $assesstimefinish, | ||
int | $scale, | ||
int | $gradeforum, | ||
bool | $gradeforumnotify, | ||
int | $maxbytes, | ||
int | $maxattachments, | ||
int | $forcesubscribe, | ||
int | $trackingtype, | ||
int | $rsstype, | ||
int | $rssarticles, | ||
int | $timemodified, | ||
int | $warnafter, | ||
int | $blockafter, | ||
int | $blockperiod, | ||
int | $completiondiscussions, | ||
int | $completionreplies, | ||
int | $completionposts, | ||
bool | $displaywordcount, | ||
int | $lockdiscussionafter, | ||
int | $duedate, | ||
int | $cutoffdate ) |
Constructor.
context | $context | The forum module context |
stdClass | $coursemodule | The forum course module record |
stdClass | $course | The forum course record |
int | $effectivegroupmode | The effective group mode |
int | $id | ID |
int | $courseid | Id of the course this forum is in |
string | $type | The forum type, e.g. single, qanda, etc |
string | $name | Name of the forum |
string | $intro | Intro text |
int | $introformat | Format of the intro text |
int | $assessed | The forum rating aggregate |
int | $assesstimestart | Timestamp to begin assessment |
int | $assesstimefinish | Timestamp to end assessment |
int | $scale | The rating scale |
int | $gradeforum | The holistic grade |
bool | $gradeforumnotify | Default for whether to notify students when grade holistically |
int | $maxbytes | Maximum attachment size |
int | $maxattachments | Maximum number of attachments |
int | $forcesubscribe | Does the forum force users to subscribe? |
int | $trackingtype | Tracking type |
int | $rsstype | RSS type |
int | $rssarticles | RSS articles |
int | $timemodified | Timestamp when the forum was last modified |
int | $warnafter | Warn after |
int | $blockafter | Block after |
int | $blockperiod | Block period |
int | $completiondiscussions | Completion discussions |
int | $completionreplies | Completion replies |
int | $completionposts | Completion posts |
bool | $displaywordcount | Should display word counts in posts |
int | $lockdiscussionafter | Timestamp after which discussions should be locked |
int | $duedate | Timestamp that represents the due date for forum posts |
int | $cutoffdate | Timestamp after which forum posts will no longer be accepted |
mod_forum\local\entities\forum::get_assess_time_finish | ( | ) |
Get the timestamp for when the assessment period ends.
int |
mod_forum\local\entities\forum::get_assess_time_start | ( | ) |
Get the timestamp for when the assessment period begins.
int |
mod_forum\local\entities\forum::get_block_after | ( | ) |
Get block after.
int |
mod_forum\local\entities\forum::get_block_period | ( | ) |
Get the block period.
int |
mod_forum\local\entities\forum::get_completion_discussions | ( | ) |
Get the completion discussions.
int |
mod_forum\local\entities\forum::get_completion_posts | ( | ) |
Get the completion posts.
int |
mod_forum\local\entities\forum::get_completion_replies | ( | ) |
Get the completion replies.
int |
mod_forum\local\entities\forum::get_context | ( | ) |
Get the forum module context.
context |
mod_forum\local\entities\forum::get_course_id | ( | ) |
Get the id of the course that the forum belongs to.
int |
mod_forum\local\entities\forum::get_course_module_record | ( | ) |
Get the forum course module record.
stdClass |
mod_forum\local\entities\forum::get_course_record | ( | ) |
Get the course record.
stdClass |
mod_forum\local\entities\forum::get_cutoff_date | ( | ) |
Get the cutoff date.
int |
mod_forum\local\entities\forum::get_due_date | ( | ) |
Get the due date.
int |
mod_forum\local\entities\forum::get_effective_group_mode | ( | ) |
Get the effective group mode.
int |
mod_forum\local\entities\forum::get_grade_for_forum | ( | ) |
Get the grade for the forum when grading holistically.
int |
mod_forum\local\entities\forum::get_id | ( | ) |
Get the forum id.
int |
mod_forum\local\entities\forum::get_intro | ( | ) |
Get the forum intro text.
string |
mod_forum\local\entities\forum::get_intro_format | ( | ) |
Get the forum intro text format.
int |
mod_forum\local\entities\forum::get_lock_discussions_after | ( | ) |
Get the timestamp after which the discussion should be locked.
int |
mod_forum\local\entities\forum::get_max_attachments | ( | ) |
Get the maximum number of attachments.
int |
mod_forum\local\entities\forum::get_max_bytes | ( | ) |
Get the maximum bytes.
int |
mod_forum\local\entities\forum::get_name | ( | ) |
Get the forum name.
string |
mod_forum\local\entities\forum::get_rating_aggregate | ( | ) |
Get the rating aggregate.
int |
mod_forum\local\entities\forum::get_rss_articles | ( | ) |
Get the RSS articles.
int |
mod_forum\local\entities\forum::get_rss_type | ( | ) |
Get the RSS type.
int |
mod_forum\local\entities\forum::get_scale | ( | ) |
Get the rating scale.
int |
mod_forum\local\entities\forum::get_subscription_mode | ( | ) |
Get the subscription mode.
int |
mod_forum\local\entities\forum::get_time_modified | ( | ) |
Get the timestamp for when the forum was last modified.
int |
mod_forum\local\entities\forum::get_tracking_type | ( | ) |
Get the tracking type.
int |
mod_forum\local\entities\forum::get_type | ( | ) |
Get the forum type.
string |
mod_forum\local\entities\forum::get_warn_after | ( | ) |
Get warn after.
int |
mod_forum\local\entities\forum::has_blocking_enabled | ( | ) |
Does the forum have blocking enabled?
bool |
mod_forum\local\entities\forum::has_cutoff_date | ( | ) |
Does the forum have a cutoff date?
bool |
mod_forum\local\entities\forum::has_due_date | ( | ) |
Does the forum have a due date?
bool |
mod_forum\local\entities\forum::has_lock_discussions_after | ( | ) |
Does the forum have a discussion locking timestamp?
bool |
mod_forum\local\entities\forum::has_rating_aggregate | ( | ) |
Does the forum have a rating aggregate?
bool |
mod_forum\local\entities\forum::is_cutoff_date_reached | ( | ) |
Is the cutoff date for the forum reached?
bool |
mod_forum\local\entities\forum::is_discussion_locked | ( | discussion_entity | $discussion | ) |
Is the discussion locked? - Takes into account both discussion settings AND forum's criteria.
discussion_entity | $discussion | The discussion to check |
bool |
mod_forum\local\entities\forum::is_discussion_time_locked | ( | discussion_entity | $discussion | ) |
Check whether the discussion is locked based on forum's time based locking criteria.
discussion_entity | $discussion |
bool |
mod_forum\local\entities\forum::is_due_date_reached | ( | ) |
Is the due date for the forum reached?
bool |
mod_forum\local\entities\forum::is_grading_enabled | ( | ) |
Whether grading is enabled for this item.
bool |
mod_forum\local\entities\forum::is_in_group_mode | ( | ) |
Check if the forum is set to group mode.
bool |
mod_forum\local\entities\forum::is_subscription_automatic | ( | ) |
Is the subscription mode set to automatic.
bool |
mod_forum\local\entities\forum::is_subscription_disabled | ( | ) |
Is the subscription mode set to disabled.
bool |
mod_forum\local\entities\forum::is_subscription_forced | ( | ) |
Is the subscription mode set to forced.
bool |
mod_forum\local\entities\forum::is_subscription_optional | ( | ) |
Is the subscription mode set to optional.
bool |
mod_forum\local\entities\forum::should_display_word_count | ( | ) |
Should the word counts be shown in the posts?
bool |
mod_forum\local\entities\forum::should_notify_students_default_when_grade_for_forum | ( | ) |
Get the default for whether the students should be notified when grading holistically.
bool |