@param array $event_config

@return array
554592
protected function setEventConfig(array $event_config)
  {
    foreach ($event_config['listeners'] as $key => $listener)
    {
      $event_config['listeners'][$key]['class'] = $this->classBuilder->getObjectInstance($listener['class']);
    }

    return $event_config;
  }
743755
public function getEventLogInfo(Event $event, $eventName)
    {
        $this->default = array(
            'type' => $eventName,
            'description' => $eventName,
        );

        if (!isset($this->commands[$eventName])) {
            return $this->default;
        }

        return $this->getEventLogDetails($event, $this->commands[$eventName]);
    }
1241990
private function getEventTags(Event $event)
    {
        return array_map(function ($value) {
            if (is_bool($value)) {
                $value = $value ? 'true' : 'false';
            }
            return $value;
        }, $event->getTags());
    }
689198
public function addEvents(array $events = array())
    {
        $events['projectId'] = $this->getConfig('projectId');
        $events['writeKey'] = $this->getKeyForWriting();

        $command = parent::getCommand('addEvents', $events);

        return $this->execute($command);
    }
731471
public function getEventLogInfo(Event $event, $eventName)
    {
        if (!$event instanceof DoctrineObjectEvent) {
            return null;
        }

        $this->initialize($event, $eventName);

        if ($this->isUpdateEvent() && null === $this->getChangeSets($this->entity)) {
            return null;
        }

        $reflectionClass = $this->getReflectionClassFromObject($this->entity);

        return array(
            'description' => $this->getDescription($reflectionClass->getShortName()),
            'type' => $this->getEventType($reflectionClass->getShortName()),
        );
    }
546247
public static function config($config = []) {
		if (!$config) {
			return ['classes' => static::$_classes, 'unicode' => static::$_unicode];
		}
		if (isset($config['classes'])) {
			static::$_classes = $config['classes'] + static::$_classes;
		}
		if (isset($config['unicode'])) {
			static::$_unicode = $config['unicode'];
		}
	}
115466
public function postProcessConfiguration(array $config): array
    {
        $config = $this->fixUpViewConfig($config);

        $processor = new ConfigurationProcessor($this->container, $this->extension->getAlias());
        foreach (array_keys($config) as $key) {
            if ($key === 'system' || !in_array($key, self::SITEACCCESS_AWARE_SETTINGS, true)) {
                continue;
            }

            is_array($config[$key]) ?
                $processor->mapConfigArray($key, $config, ContextualizerInterface::MERGE_FROM_SECOND_LEVEL) :
                $processor->mapSetting($key, $config);
        }

        $designList = array_keys($config['design_list']);
        foreach ($config['system'] as $scopeConfig) {
            $this->validateCurrentDesign($scopeConfig['design'], $designList);
        }

        return $config;
    }
18273
public function getConfigByName($config_name)
    {
        if ($this->isSingle()) {
            if (isset($this->containers['config'])) {
                return $this->containers['config']->get($config_name);
            }
        }
        return [];
    }
109616
public static function create(array $config = [])
    {
        $config        = self::mergeDefaults($config);
        $metricFactory = new MetricFactory($config['default_tags'], $config['prefix']);
        $eventFactory  = new EventFactory($config['hostname']);
        $logger        = $config['logger']['instance'] instanceof LoggerInterface ? $config['logger']['instance'] : null;
        $debug         = $config['logger']['debug'];
        $monitor       = new Monitor($metricFactory, $eventFactory, $debug ? $logger : null);

        if (!empty($config['datadog']['metrics'])) {
            $monitor->pushMetricSender(DataDogMetrics::create($config['datadog']['host'], $config['datadog']['port']));
        }

        if (!empty($config['datadog']['events'])) {
            $monitor->pushEventSender(DataDogEvents::create($config['datadog']['host'], $config['datadog']['port']));
        }

        if ($logger && $config['logger']['metrics']) {
            $monitor->pushMetricSender(new PsrLoggerMetrics($logger), $config['logger']['level']);
        }

        if ($logger && $config['logger']['events']) {
            $monitor->pushEventSender(new PsrLoggerEvents($logger), $config['logger']['level']);
        }

        return $monitor;
    }
693271
public function exportEventMessages($eventName) {
        $exports = array();
        $items = $this->getEventMessages($eventName);
        foreach ($items as $item) {
            $exports[] = $this->prepareExportEventMessage($item);
        }
        return $exports;
    }
1211825
public function trigger($event_name, array $arguments = [])
    {
        // Read in our config/events file so that we have them all!
        if (! $this->have_read_from_file)
        {
            $this->readConfigFile();
        }

        foreach ($this->listeners($event_name) as $listener)
        {
            if (! is_callable($listener)) continue;

            $result = call_user_func_array($listener, $arguments);

            if ($result === false)
            {
                return false;
            }
        }

        return true;
    }
1235138
public function getListeners(string $eventName) : array
    {
        if (!isset($this->events[$eventName])) {
            return [];
        }

        return $this->events[$eventName];
    }
1144867
public function getListeners(string ...$eventNames) : array
    {
        if (empty($eventNames)) return [];

        $key = implode('|', $eventNames);
        return $this->combinationListeners[$key] ?? [];
    }
1322728
public function getListeners(string $eventName = ''): array
    {
        $this->sortListeners($eventName);
        if ('' !== $eventName) {
            return \array_key_exists($eventName, $this->listeners) ? $this->listeners[$eventName] : [];
        }
        return $this->listeners;
    }
1345418
public function getListeners($event): array
    {
        $event = $this->getEventName($event);

        if (! $this->hasListener($event)) {
            return [];
        }

        if (! array_key_exists($event, $this->sortedListeners)) {
            $listeners = $this->listeners[$event];

            krsort($listeners);

            $listeners = call_user_func_array(
                'array_merge',
                $listeners
            );
            $this->sortedListeners[$event] = $listeners;

            unset($listeners);
        }

        return $this->sortedListeners[$event];
    }
637460
def get_event_list(config):
    """"""
    eventinstances = session_request(
        config.session.post, device_event_url.format(
            proto=config.web_proto, host=config.host, port=config.port),
        auth=config.session.auth, headers=headers, data=request_xml)

    raw_event_list = _prepare_event(eventinstances)

    event_list = {}
    for entry in MAP + METAMAP:
        instance = raw_event_list
        try:
            for item in sum(entry[MAP_BASE].values(), []):
                instance = instance[item]
        except KeyError:
            continue
        event_list[entry[MAP_TYPE]] = instance

    return event_list
794754
private function _getEventsConfig()
    {
        $content = array(self:: MAIN_EVENTS_FILE => array());

        $configPath = $this->_configPath;
        if (! is_dir($configPath)) {
            return $content;
        }

        $files = DirData::listFilesRecursive($configPath, self:: MAIN_EVENTS_FILE . self::EXT);
        foreach ($files as $file) {
            $content[self:: MAIN_EVENTS_FILE] = array_merge_recursive(require($file), $content[self:: MAIN_EVENTS_FILE]);
        }

        return $content;
    }