ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ObjectModes.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22
26
28{
29 protected Container $dic;
30
31 protected string $type;
32 protected int $ref_id;
33 protected string $sub_type;
34 protected int $sub_id;
35
36 public function __construct(
38 string $type,
39 int $ref_id,
40 string $sub_type = '',
41 int $sub_id = 0
42 ) {
43 $this->dic = $dic;
44 $this->type = $type;
45 $this->ref_id = $ref_id;
46 $this->sub_type = $sub_type;
47 $this->sub_id = $sub_id;
48 }
49
50 public function custom(): CustomInterface
51 {
52 return new Custom(
53 $this->dic->user(),
54 $this->type,
55 $this->ref_id,
56 $this->sub_type,
57 $this->sub_id
58 );
59 }
60}
__construct(Container $dic, string $type, int $ref_id, string $sub_type='', int $sub_id=0)
Definition: ObjectModes.php:36
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:36