19declare(strict_types=1);
56 foreach ($this->providers as $provider) {
57 $items_to_merge[] = $provider->getMetaBarItems();
59 $this->items = array_merge([], ...$items_to_merge);
64 $this->items = array_filter($this->items, $this->
getVisibleFilter() ??
function ($v, $k) :
bool {
95 return count($this->items) > 0;
111 return $a->getPosition() -
$b->getPosition();
117 return function (
isItem &$item) :
void {
119 $children = $item->getChildren();
121 $item = $item->withChildren($children);
128 return static function (
isItem $item) :
bool {
129 return ($item->isAvailable() && $item->isVisible());
An exception for terminatinating execution or to throw for unit testing.
Class AbstractBaseCollector.
Class MetaBarMainCollector.
__construct(array $providers)
MetaBarMainCollector constructor.
sortItemsForUIRepresentation()
prepareItemsForUIRepresentation()
filterItemsByVisibilty(bool $async_only=false)
cleanupItemsForUIRepresentation()
getItemsForUIRepresentation()
$a
thx to https://mlocati.github.io/php-cs-fixer-configurator for the examples