ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
Factory.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=0);
20
21namespace ILIAS\Tracking\View;
22
25use ILIAS\Tracking\View\DataRetrieval\Factory as DataRetrievalFactory;
26use ILIAS\Tracking\View\DataRetrieval\FactoryInterface as DataRetrievalFactoryInterface;
27use ILIAS\Tracking\View\FactoryInterface as ViewFactoryInterface;
28use ILIAS\Tracking\View\PropertyList\FactoryInterface as PropertyListFactoryInterface;
29use ILIAS\Tracking\View\PropertyList\Factory as PropertyListFactory;
30use ILIAS\Tracking\View\Renderer\FactoryInterface as RendererFactoryInterface;
31use ILIAS\Tracking\View\Renderer\Factory as RendererFactory;
32use ILIAS\Tracking\View\ProgressBlock\FactoryInterface as ProgressBlockFactoryInterface;
33use ILIAS\Tracking\View\ProgressBlock\Factory as ProgressBlockFactory;
34
35class Factory implements ViewFactoryInterface
36{
37 protected UIServices $ui;
38 protected ilDBInterface $db;
39
40 public function __construct()
41 {
42 global $DIC;
43 $this->ui = $DIC->ui();
44 $this->db = $DIC->database();
45 }
46
47 public function renderer(): RendererFactoryInterface
48 {
49 return new RendererFactory(
50 $this->ui
51 );
52 }
53
54 public function dataRetrieval(): DataRetrievalFactoryInterface
55 {
56 return new DataRetrievalFactory(
57 $this->db
58 );
59 }
60
61 public function propertyList(): PropertyListFactoryInterface
62 {
63 return new PropertyListFactory();
64 }
65
66 public function progressBlock(): ProgressBlockFactory
67 {
68 return new ProgressBlockFactory($this->db);
69 }
70}
Provides fluid interface to RBAC services.
Definition: UIServices.php:25
Interface ilDBInterface.
global $DIC
Definition: shib_login.php:26