Embera\Providers::findServices PHP Метод

findServices() защищенный Метод

Finds services for the given $urls.
protected findServices ( array $urls = [] ) : array
$urls array An array with all the available urls
Результат array An Array with loaded services
    protected function findServices(array $urls = array())
    {
        $return = array();
        $this->extractCustomParams($this->config['custom_params']);
        foreach (array_unique($urls) as $u) {
            try {
                $host = $this->getHost($u);
                if (isset($this->services[$host])) {
                    $provider = new \ReflectionClass($this->services[$host]);
                    $return[$u] = $provider->newInstance($u, $this->config, $this->oembed);
                    if (isset($this->customParams[$host])) {
                        $return[$u]->appendParams($this->customParams[$host]);
                    }
                }
            } catch (\Exception $e) {
                //echo $e->getMessage() . PHP_EOL;
            }
        }
        return $return;
    }