|
| __construct (private readonly array $map=[],) |
|
| add (string $name, $item) |
|
| set (string $name, string $key, $item) |
|
| has (string $name, string $key) |
|
| append (self $other) |
|
| value () |
|
|
| map (string $key, Closure $proc) |
|
Definition at line 26 of file Map.php.
◆ __construct()
ILIAS\LegalDocuments\Map::__construct |
( |
private readonly array |
$map = [] | ) |
|
- Parameters
-
array<string,list|array<string,mixed>> | $map |
Definition at line 31 of file Map.php.
◆ add()
ILIAS\LegalDocuments\Map::add |
( |
string |
$name, |
|
|
|
$item |
|
) |
| |
◆ append()
ILIAS\LegalDocuments\Map::append |
( |
self |
$other | ) |
|
Definition at line 51 of file Map.php.
References ILIAS\LegalDocuments\Map\map().
56 if (count($mine) + count($other) !== count(array_merge($mine, $other))) {
57 throw new Exception(
'Cannot append maps. Keys must be distinct.');
59 }, $this->map, $other->value());
60 return new self(array_merge_recursive($this->
map, $other->value()));
map(string $key, Closure $proc)
◆ has()
ILIAS\LegalDocuments\Map::has |
( |
string |
$name, |
|
|
string |
$key |
|
) |
| |
◆ map()
ILIAS\LegalDocuments\Map::map |
( |
string |
$key, |
|
|
Closure |
$proc |
|
) |
| |
|
private |
◆ set()
ILIAS\LegalDocuments\Map::set |
( |
string |
$name, |
|
|
string |
$key, |
|
|
|
$item |
|
) |
| |
◆ value()
ILIAS\LegalDocuments\Map::value |
( |
| ) |
|
The documentation for this class was generated from the following file:
- components/ILIAS/LegalDocuments/classes/Map.php