ILIAS  trunk Revision v11.0_alpha-1769-g99a433fe2dc
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
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;
36 
38 {
39  private \ILIAS\DI\Container $DIC;
40 
41  protected function initDomainServices(\ILIAS\DI\Container $DIC): void
42  {
43  $this->DIC = $DIC;
44  }
45 
46  public function repositoryTree(): \ilTree
47  {
48  return $this->DIC->repositoryTree();
49  }
50 
51  public function access(): \ilAccessHandler
52  {
53  return $this->DIC->access();
54  }
55 
56  public function rbac(): RBACServices
57  {
58  return $this->DIC->rbac();
59  }
60 
61  public function lng(): \ilLanguage
62  {
63  return $this->DIC->language();
64  }
65 
66  public function user(): \ilObjUser
67  {
68  return $this->DIC->user();
69  }
70 
71  public function logger(): LoggingServices
72  {
73  return $this->DIC->logger();
74  }
75 
76  public function refinery(): Refinery\Factory
77  {
78  return $this->DIC->refinery();
79  }
80 
81  public function filesystem(): Filesystems
82  {
83  return $this->DIC->filesystem();
84  }
85 
87  {
88  return $this->DIC->resourceStorage();
89  }
90 
91  public function event(): \ilAppEventHandler
92  {
93  return $this->DIC->event();
94  }
95 
96  public function settings(): \ilSetting
97  {
98  return $this->DIC->settings();
99  }
100 
102  {
103  return $this->DIC["objDefinition"];
104  }
105 
106  public function object(): ObjectAdapterInterface
107  {
108  return new ObjectAdapter();
109  }
110 
111  public function profile(): ProfileAdapter
112  {
113  return new ProfileAdapter(
114  $this->lng()
115  );
116  }
117 
118  public function objectDataCache(): \ilObjectDataCache
119  {
120  return $this->DIC["ilObjDataCache"];
121  }
122 
123  public function backgroundTasks(): \ILIAS\BackgroundTasks\BackgroundTaskServices
124  {
125  return $this->DIC->backgroundTasks();
126  }
127 
129  {
130  return $this->DIC->learningObjectMetadata();
131  }
132 
133  public function resources(): DomainService
134  {
135  return new DomainService(
136  $this->DIC->archives(),
137  $this->DIC->legacyArchives()
138  );
139  }
140 
141  public function staticUrl(): StaticUrl
142  {
143  return $this->DIC['static_url'];
144  }
145 }
Global event handler.
Provides fluid interface to LoggingServices.
Interface Observer Contains several chained tasks and infos about them.
initDomainServices(\ILIAS\DI\Container $DIC)
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:35
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.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
global $DIC
Definition: shib_login.php:22
Provides fluid interface to RBAC services.
Builds data types.
Definition: Factory.php:35
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