private function collectBusinessEvent(array &
$eventsDoc): void
{ $context = Context::
createDefaultContext();
$businessEvents =
$this->businessEventCollector->
collect($context);
$eventDoc =
new ArrayWriter(self::EVENT_DESCRIPTIONS
);
foreach ($businessEvents as $event) { $eventDoc->
ensure($event->
getName());
$eventsDoc[] = HookableEventDoc::
fromBusinessEvent( $event,
$this->hookableEventCollector->
getPrivilegesFromBusinessEventDefinition($event),
$eventDoc->
get($event->
getName()) );
} } /**
* @param list<HookableEventDoc> $eventsDoc
*/
private function collectEntityWrittenEvent(array &
$eventsDoc): void
{ $entityWrittenEvents =
$this->hookableEventCollector->
getEntityWrittenEventNamesWithPrivileges();