CollectionService

class \TYPO3\CMS\Workspaces\Service\Dependency\CollectionService

Service to collect dependent elements.

Table of Contents

Properties

$dataArray  : array
$dependencyResolver  : DependencyResolver|null
$eventDispatcher  : EventDispatcherInterface
$nestedDataArray  : array
$visitedContexts  : array<string, true>
Contexts elements have already been resolved in, see resolveDataArrayChildDependencies() for details.

Methods

__construct()  : mixed
getDependencyResolver()  : DependencyResolver
process()  : array
Processes the data array
finalize()  : array
Applies structures to instance data array and ensures children are added below accordant parent
getBackendUser()  : BackendUserAuthentication
getCollectionChildrenCount()  : int
Return count of children, present in the data array
resolveDataArrayChildDependencies()  : void
Resolves nested child dependencies.

Properties

$eventDispatcher read-only

protected EventDispatcherInterface $eventDispatcher

$nestedDataArray

protected array $nestedDataArray

$visitedContexts

Contexts elements have already been resolved in, see resolveDataArrayChildDependencies() for details.

protected array<string, true> $visitedContexts

Methods

__construct()

public __construct(EventDispatcherInterface $eventDispatcher) : mixed

Parameters

$eventDispatcher : EventDispatcherInterface

process()

Processes the data array

public process(array $dataArray) : array

Parameters

$dataArray : array

Return values

array

finalize()

Applies structures to instance data array and ensures children are added below accordant parent

protected finalize(array $dataArray) : array

Parameters

$dataArray : array

Return values

array

getCollectionChildrenCount()

Return count of children, present in the data array

protected getCollectionChildrenCount(ReferenceEntity[] $children, array<string, true> $entryPath) : int

Parameters

$children : ReferenceEntity[]
$entryPath : array<string, true>

Elements of the branch that is currently traversed

Return values

int

resolveDataArrayChildDependencies()

Resolves nested child dependencies.

protected resolveDataArrayChildDependencies(ElementEntity $parent, int $collection[, string $nextParentIdentifier = '' ][, int $collectionLevel = 0 ][, array<string, true> $entryPath = [] ]) : void

Parameters

$parent : ElementEntity
$collection : int
$nextParentIdentifier : string = ''
$collectionLevel : int = 0
$entryPath : array<string, true> = []

Elements of the branch that is currently traversed

On this page