ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
class.ilUserAvatarFactory.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (c) 1998-2017 ILIAS open source, Extended GPL, see docs/LICENSE */
3 
10 {
14  protected $dic;
15 
20  public function __construct(\ILIAS\DI\Container $dic)
21  {
22  $this->dic = $dic;
23  }
24 
29  public function avatar($size)
30  {
31  if ((int) $this->dic->settings()->get('letter_avatars')) {
32  return $this->letter();
33  }
34 
35  return $this->file($size);
36  }
37 
41  public function letter()
42  {
43  return new ilUserAvatarLetter();
44  }
45 
50  public function file($size)
51  {
52  return new ilUserAvatarFile($size);
53  }
54 }
Class ilUserAvatarFactory.
$size
Definition: RandomTest.php:84
__construct(\ILIAS\DI\Container $dic)
ilUserAvatarFactory constructor.
Class BaseForm.
Class ilUserAvatarFile.
Class HTTPServicesTest.
Class ilUserAvatarLetter.