ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ILIAS\Repository\Profile\ProfileAdapter Class Reference
+ Collaboration diagram for ILIAS\Repository\Profile\ProfileAdapter:

Public Member Functions

 __construct (\ilLanguage $lng)
 
 exists (int $user_id)
 
 getDeletedUserAvatarText ()
 
 getDeletedUserNamePresentation ()
 
 getNamePresentation (int $user_id, bool $force=false)
 

Protected Attributes

ilLanguage $lng
 

Detailed Description

Definition at line 23 of file ProfileAdapter.php.

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Repository\Profile\ProfileAdapter::__construct ( \ilLanguage  $lng)

Definition at line 27 of file ProfileAdapter.php.

29 {
30 $this->lng = $lng;
31 $this->lng->loadLanguageModule("rep");
32 }

References ILIAS\Repository\Profile\ProfileAdapter\$lng, and ILIAS\Repository\lng().

+ Here is the call graph for this function:

Member Function Documentation

◆ exists()

ILIAS\Repository\Profile\ProfileAdapter::exists ( int  $user_id)

Definition at line 34 of file ProfileAdapter.php.

34 : bool
35 {
36 return \ilObjUser::userExists([$user_id]);
37 }

References $user_id.

Referenced by ILIAS\Repository\Profile\ProfileAdapter\getNamePresentation().

+ Here is the caller graph for this function:

◆ getDeletedUserAvatarText()

ILIAS\Repository\Profile\ProfileAdapter::getDeletedUserAvatarText ( )

Definition at line 39 of file ProfileAdapter.php.

39 : string
40 {
41 return $this->lng->txt("deleted");
42 }

References ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ getDeletedUserNamePresentation()

ILIAS\Repository\Profile\ProfileAdapter::getDeletedUserNamePresentation ( )

Definition at line 44 of file ProfileAdapter.php.

44 : string
45 {
46 return $this->lng->txt("rep_deleted_account");
47 }

References ILIAS\Repository\lng().

Referenced by ILIAS\Repository\Profile\ProfileAdapter\getNamePresentation().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getNamePresentation()

ILIAS\Repository\Profile\ProfileAdapter::getNamePresentation ( int  $user_id,
bool  $force = false 
)

Definition at line 49 of file ProfileAdapter.php.

49 : string
50 {
51 if (!$this->exists($user_id)) {
52 return $this->getDeletedUserNamePresentation();
53 }
54 return \ilUserUtil::getNamePresentation($user_id, false, false, "", $force);
55 }

References $user_id, ILIAS\Repository\Profile\ProfileAdapter\exists(), and ILIAS\Repository\Profile\ProfileAdapter\getDeletedUserNamePresentation().

+ Here is the call graph for this function:

Field Documentation

◆ $lng

ilLanguage ILIAS\Repository\Profile\ProfileAdapter::$lng
protected

The documentation for this class was generated from the following file: