NerdsAndCompany\Schematic\Console\App::_attachEventListeners PHP Метод

_attachEventListeners() приватный Метод

Attaches any pending event listeners to the newly-initialized component.
private _attachEventListeners ( string $componentId )
$componentId string
    private function _attachEventListeners($componentId)
    {
        if (isset($this->_pendingEvents[$componentId])) {
            $component = $this->getComponent($componentId, false);
            if ($component) {
                foreach ($this->_pendingEvents[$componentId] as $eventName => $handlers) {
                    foreach ($handlers as $handler) {
                        $component->{$eventName} = $handler;
                    }
                }
            }
        }
    }