ILIAS
release_7 Revision v7.30-3-g800a261c036
◀ ilDoc Overview
RowFactory.php
Go to the documentation of this file.
1
<?
php
declare(strict_types=1);
2
3
/* Copyright (c) 2020 Nils Haagen <nils.haagen@concepts-and-training.de> Extended GPL, see docs/LICENSE */
4
5
namespace
ILIAS\UI\Implementation\Component\Table
;
6
7
use
ILIAS\UI\Component\Table
as
T
;
8
9
class
RowFactory
implements
T\RowFactory
10
{
14
protected
$cell_transformations
;
15
16
public
function
__construct
(array
$cell_transformations
)
17
{
18
$this->cell_transformations =
$cell_transformations
;
19
}
20
21
public
function
map
(array
$record
) : array
22
{
23
$row = [];
24
foreach
(array_keys($this->cell_transformations) as
$id
) {
25
$row[
$id
] =
''
;
26
if
(array_key_exists(
$id
,
$record
)) {
27
foreach
($this->cell_transformations[
$id
] as $trafo) {
28
$row[
$id
] = $trafo(
$record
[
$id
]);
29
}
30
}
31
}
32
return
$row;
33
}
34
}
php
An exception for terminatinating execution or to throw for unit testing.
ILIAS\UI\Implementation\Component\Table\RowFactory
Definition:
RowFactory.php:10
ILIAS\UI\Implementation\Component\Table\RowFactory\__construct
__construct(array $cell_transformations)
Definition:
RowFactory.php:16
ILIAS\UI\Implementation\Component\Table\RowFactory\$cell_transformations
$cell_transformations
Definition:
RowFactory.php:14
ILIAS\UI\Implementation\Component\Table\RowFactory\map
map(array $record)
Definition:
RowFactory.php:21
ilDclRecordEditGUI\$record
$record
Definition:
class.ilDclRecordEditGUI.php:47
ilGeoLocation\$id
$id
Definition:
ilGeoLocation.php:6
ILIAS\UI\Component\Table
ILIAS\UI\Implementation\Component\Table
src
UI
Implementation
Component
Table
RowFactory.php
Generated on Sat Oct 4 2025 21:01:15 for ILIAS by
1.9.4 (using
Doxyfile
)