Grants a group access to a training programme, or to a single course within a programme, on one website. Enrolements are always held against a group, never directly against a profile, so a person is enroled by being a member of an enroled group and a profile's enrolements are found by walking its group memberships. The programme and course are stored as their codes rather than as foreign keys, and leaving the course code null enrols the group in the whole programme. The completable flag decides whether members can actually complete modules and earn certification and rewards, or only view the content. Enrolements are audited, so changes are recorded and can be restored.

Group: Database Entities

Implements: Serializable, Auditable


Properties

PropertyReturnsDescription
auditOrgOrganisationThe organisation this enrolement's audit records are written against, taken from the enroled group. Throws if the enroled group has not been set.
completablebooleanWhether members of the enroled group can complete the material rather than just read it. When true they can complete modules, sit any assessment, and be issued certification and rewards. When false they may view the content but cannot be issued any certification or other completion status.
createdDateDateWhen the enrolement was created. Mandatory, and stored as a date with no time component.
enroledCourseStringCode of the single course the group is enroled in. Optional: when it is set the group has access only to that course, and when it is null the group is enroled in the whole programme.
enroledGroupGroupThe group being granted access. Required. Enrolements are never held directly against a profile, so a person gains access by being a member of this group.
enroledProgramStringCode of the programme the group is enroled in. Mandatory, and stored as the code rather than as a foreign key, so renaming a programme does not update existing enrolements.
idlongDatabase generated primary key for this enrolement.
modifiedDateDateWhen the enrolement was last changed. Mandatory, and stored as a date with no time component, so it does not distinguish two changes made on the same day.
promotionRewardThe promotion that granted this enrolement, or null if it was granted directly. Set when access to training comes from taking part in a promotion rather than from an administrator enroling the group.
websiteWebsiteThe website the enrolement applies to. Required, so the same group can be enroled in the same programme on two websites as two separate rows.

Methods

getWebsite() · setWebsite(Website website) · getEnroledGroup() · setEnroledGroup(Group enroledEntity) · getEnroledCourse() · setEnroledCourse(String enroledCourse) · getEnroledProgram() · setEnroledProgram(String enroledProgram) · getId() · getCreatedDate() · setCreatedDate(Date createdDate) · getModifiedDate() · setModifiedDate(Date modifiedDate) · isCompletable() · setCompletable(boolean completable) · getPromotion() · setPromotion(Reward promotion) · getAuditOrg()

getWebsite()

Returns: Website

The website the enrolement applies to. Required, so the same group can be enroled in the same programme on two websites as two separate rows.

setWebsite(Website website)

Returns: void

Sets the website this enrolement applies to. Required.

ParameterDescription
websitethe website the enrolement applies to

getEnroledGroup()

Returns: Group

The group being granted access. Required. Enrolements are never held directly against a profile, so a person gains access by being a member of this group.

setEnroledGroup(Group enroledEntity)

Returns: void

Sets the group being granted access. Required.

ParameterDescription
enroledEntitythe group to enrol

getEnroledCourse()

Returns: String

Code of the single course the group is enroled in. Optional: when it is set the group has access only to that course, and when it is null the group is enroled in the whole programme.

setEnroledCourse(String enroledCourse)

Returns: void

Sets the course the group is enroled in, or clears it to enrol the group in the whole programme.

ParameterDescription
enroledCoursethe course code, or null for a whole programme enrolement

getEnroledProgram()

Returns: String

Code of the programme the group is enroled in. Mandatory, and stored as the code rather than as a foreign key, so renaming a programme does not update existing enrolements.

setEnroledProgram(String enroledProgram)

Returns: void

Sets the code of the programme the group is enroled in. Required.

ParameterDescription
enroledProgramthe programme code

getId()

Returns: long

Database generated primary key for this enrolement.

getCreatedDate()

Returns: Date

When the enrolement was created. Mandatory, and stored as a date with no time component.

setCreatedDate(Date createdDate)

Returns: void

Sets the date the enrolement was created. Required.

ParameterDescription
createdDatethe creation date

getModifiedDate()

Returns: Date

When the enrolement was last changed. Mandatory, and stored as a date with no time component, so it does not distinguish two changes made on the same day.

setModifiedDate(Date modifiedDate)

Returns: void

Sets the date the enrolement was last changed. Required, and not updated automatically, so set it yourself when you change an enrolement.

ParameterDescription
modifiedDatethe modification date

isCompletable()

Returns: boolean

Whether members of the enroled group can complete the material rather than just read it. When true they can complete modules, sit any assessment, and be issued certification and rewards. When false they may view the content but cannot be issued any certification or other completion status.

setCompletable(boolean completable)

Returns: void

Sets whether members of the group can complete the material and earn certification, as opposed to only viewing it.

ParameterDescription
completabletrue to allow completion, certification and rewards

getPromotion()

Returns: Reward

The promotion that granted this enrolement, or null if it was granted directly. Set when access to training comes from taking part in a promotion rather than from an administrator enroling the group.

setPromotion(Reward promotion)

Returns: void

Links this enrolement to the promotion that granted it.

ParameterDescription
promotionthe granting promotion, or null if the enrolement was granted directly

getAuditOrg()

Returns: Organisation

The organisation this enrolement's audit records are written against, taken from the enroled group. Throws if the enroled group has not been set.

To get full access to the Kademi Hub existing customers can login here, or new customers can register here.