ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
trait.GlobalDICDomainServices.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
21 namespace ILIAS\Repository;
22 
27 use ILIAS\Refinery;
33 
35 {
36  private \ILIAS\DI\Container $DIC;
37 
38  protected function initDomainServices(\ILIAS\DI\Container $DIC): void
39  {
40  $this->DIC = $DIC;
41  }
42 
43  public function repositoryTree(): \ilTree
44  {
45  return $this->DIC->repositoryTree();
46  }
47 
48  public function access(): \ilAccessHandler
49  {
50  return $this->DIC->access();
51  }
52 
53  public function rbac(): RBACServices
54  {
55  return $this->DIC->rbac();
56  }
57 
58  public function lng(): \ilLanguage
59  {
60  return $this->DIC->language();
61  }
62 
63  public function user(): \ilObjUser
64  {
65  return $this->DIC->user();
66  }
67 
68  public function logger(): LoggingServices
69  {
70  return $this->DIC->logger();
71  }
72 
73  public function refinery(): Refinery\Factory
74  {
75  return $this->DIC->refinery();
76  }
77 
78  public function filesystem(): Filesystems
79  {
80  return $this->DIC->filesystem();
81  }
82 
84  {
85  return $this->DIC->resourceStorage();
86  }
87 
88  public function event(): \ilAppEventHandler
89  {
90  return $this->DIC->event();
91  }
92 
93  public function settings(): \ilSetting
94  {
95  return $this->DIC->settings();
96  }
97 
99  {
100  return $this->DIC["objDefinition"];
101  }
102 
103  public function object(): ObjectAdapterInterface
104  {
105  return new ObjectAdapter();
106  }
107 
108  public function profile(): ProfileAdapter
109  {
110  return new ProfileAdapter(
111  $this->lng()
112  );
113  }
114 
115  public function objectDataCache(): \ilObjectDataCache
116  {
117  return $this->DIC["ilObjDataCache"];
118  }
119 
120  public function backgroundTasks(): \ILIAS\BackgroundTasks\BackgroundTaskServices
121  {
122  return $this->DIC->backgroundTasks();
123  }
124 
125  public function resources(): DomainService
126  {
127  return new DomainService(
128  $this->DIC->archives(),
129  $this->DIC->legacyArchives()
130  );
131  }
132 
133  public function staticUrl(): StaticUrl
134  {
135  return $this->DIC['static_url'];
136  }
137 }
Global event handler.
Provides fluid interface to LoggingServices.
Class ChatMainBarProvider .
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
initDomainServices(\ILIAS\DI\Container $DIC)
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:35
global $DIC
Definition: feed.php:28
parses the objects.xml it handles the xml-description of all ilias objects
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class HTTPServicesTest.
Provides fluid interface to RBAC services.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
The Filesystems interface defines the access methods which can be used to fetch the different filesys...
Definition: Filesystems.php:29