You are here

function CourseEnrollment::getUser in Course 8.3

Same name and namespace in other branches
  1. 8.2 src/Entity/CourseEnrollment.php \Drupal\course\Entity\CourseEnrollment::getUser()
  2. 3.x 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).

File

src/Entity/CourseEnrollment.php, line 197

Class

CourseEnrollment
Defines the profile entity class.

Namespace

Drupal\course\Entity

Code

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