You are here

function CourseEnrollment::getUser in Course 3.x

Same name and namespace in other branches
  1. 8.3 src/Entity/CourseEnrollment.php \Drupal\course\Entity\CourseEnrollment::getUser()
  2. 8.2 src/Entity/CourseEnrollment.php \Drupal\course\Entity\CourseEnrollment::getUser()

Get the User for this enrollment.

Return value

AccountInterface

1 call to CourseEnrollment::getUser()
CourseEnrollment::evaluate in src/Entity/CourseEnrollment.php
Track the course (scan required objects, update progress, completion, etc.) and mark progress/completion.

File

src/Entity/CourseEnrollment.php, line 269

Class

CourseEnrollment
Defines the profile entity class.

Namespace

Drupal\course\Entity

Code

function getUser() {
  return User::load($this
    ->get('uid')
    ->getString());
}