ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
AbstractBaseCollector.php
Go to the documentation of this file.
1<?php declare(strict_types=1);
2
4
10abstract class AbstractBaseCollector implements Collector
11{
12
16 private $has_been_collected = false;
17
18
19 private function setCollected() : void
20 {
21 $this->has_been_collected = true;
22 }
23
24
28 public function hasBeenCollected() : bool
29 {
31 }
32
33
34 public function collectOnce() : void
35 {
36 if (!$this->hasBeenCollected()) {
37 $this->collectStructure();
38 $this->prepareItemsForUIRepresentation();
39 $this->filterItemsByVisibilty(false);
40 $this->cleanupItemsForUIRepresentation();
41 $this->sortItemsForUIRepresentation();
42 $this->setCollected();
43 }
44 }
45}
An exception for terminatinating execution or to throw for unit testing.
collectOnce()
Runs the Collection of all items from the providers.