Moodle  2.2.1
http://www.collinsharper.com
enrol_cohort_plugin Class Reference
Inheritance diagram for enrol_cohort_plugin:
Collaboration diagram for enrol_cohort_plugin:

Public Member Functions

 get_instance_name ($instance)
 get_newinstance_link ($courseid)
 cron ()
 course_updated ($inserted, $course, $data)
 get_manual_enrol_button (course_enrolment_manager $manager)

Protected Member Functions

 can_add_new_instances ($courseid)

Detailed Description

Cohort enrolment plugin implementation.

Author:
Petr Skoda http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Definition at line 34 of file lib.php.


Member Function Documentation

can_add_new_instances ( courseid) [protected]

Given a courseid this function returns true if the user is able to enrol or configure cohorts AND there are cohorts that the user can view.

Parameters:
int$courseid
Returns:
bool

Definition at line 81 of file lib.php.

Here is the call graph for this function:

Here is the caller graph for this function:

course_updated ( inserted,
course,
data 
)

Called after updating/inserting course.

Parameters:
bool$insertedtrue if course just inserted
object$course
object$dataform data
Returns:
void

Reimplemented from enrol_plugin.

Definition at line 128 of file lib.php.

Here is the call graph for this function:

cron ( )

Called for all enabled enrol plugins that returned true from is_cron_required().

Returns:
void

Reimplemented from enrol_plugin.

Definition at line 107 of file lib.php.

Here is the call graph for this function:

get_instance_name ( instance)

Returns localised name of enrol instance

Parameters:
object$instance(null is accepted too)
Returns:
string

Reimplemented from enrol_plugin.

Definition at line 41 of file lib.php.

Here is the call graph for this function:

Returns a button to enrol a cohort or its users through the manual enrolment plugin.

This function also adds a quickenrolment JS ui to the page so that users can be enrolled via AJAX.

Parameters:
course_enrolment_manager$manager
Returns:
enrol_user_button

Reimplemented from enrol_plugin.

Definition at line 150 of file lib.php.

Here is the call graph for this function:

get_newinstance_link ( courseid)

Returns link to page which may be used to add new instance of enrolment plugin in course.

Parameters:
int$courseid
Returns:
moodle_url page url

Reimplemented from enrol_plugin.

Definition at line 66 of file lib.php.

Here is the call graph for this function:


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations