@param array $names

@return IConfigLoader
501238
public function addEnvironments(array $names) {
        foreach ($names as $name) {
            $this->getEnvironmentDetector()
                ->addEnvironmentRule($name, [$name]);
        }

        return $this;
    }
1359033
public function addIcons($icons){
		foreach ( $this->content as $index=>$item ) {
			if($item instanceof HtmlButton && isset($icons[$index]))
				$item->addIcon($icons[$index]);
		}
		return $this;
	}
1166879
protected function fixIconsArray(array $icons)
    {
        $array = [];
        foreach ($icons as $rel => $data) {
            foreach ((array) $data['sizes'] as $size) {
                $array[] = array_merge_recursive(
                    [
                        'rel'   => $rel,
                        'sizes' => "{$size}x{$size}",
                        'href'  => sprintf($data['pattern'], $size),
                    ],
                    (isset($data['attr']) ? $data['attr'] : [])
                );
            }
        }
        return $array;
    }
961737
public function findGroupsByNames(array $names)
    {
        $nameCount = count($names);
        $dql = '
            SELECT g FROM Claroline\CoreBundle\Entity\Group g
            WHERE g.name IN (:names)
        ';

        $query = $this->_em->createQuery($dql);
        $query->setParameter('names', $names);

        $result = $query->getResult();

        if (($groupCount = count($result)) !== $nameCount) {
            throw new MissingObjectException("{$groupCount} out of {$nameCount} groups were found");
        }

        return $result;
    }
767778
public function registerNamespaces($namespaces)
    {
        if (!is_array($namespaces) && !$namespaces instanceof Traversable) {

            throw new Zend_Loader_Exception_InvalidArgumentException('Namespace pairs must be either an array or Traversable');
        }

        foreach ($namespaces as $namespace => $directory) {
            $this->registerNamespace($namespace, $directory);
        }
        return $this;
    }
879799
public static function build($nameSingular, $namePlural, $color, $icon)
    {
        $group = new static;

        $group->name_singular = $nameSingular;
        $group->name_plural = $namePlural;
        $group->color = $color;
        $group->icon = $icon;

        $group->raise(new Created($group));

        return $group;
    }
428801
public static function createIcon(string $icon, array $arguments = null) {
		$element = Html::el("i");
		
		if($icon == "b" or $icon == "l" or $icon == "s" or $icon == "r") {
			// Markup of icon which use Font Awesome 5.
			$class = ["fa".$icon];
		} else {
			// Markup of icon which use Font Awesome 4.
			$class = ["fa fa-".$icon];
		}
		
		if(isset($arguments)) {
			foreach($arguments as $argument) {
				$class[] = "fa-".$argument;
			}
		}
		
		$element->addAttributes(["class" => $class, "aria-hidden" => "true"]);
		return $element;
	}
114372
protected static function setIconAttribute(array $properties)
    {
        $icon = array_get($properties, 'attributes.icon');
        if (!is_null($icon)) {
            $properties['icon'] = $icon;

            array_forget($properties, 'attributes.icon');

            return $properties;
        }

        return $properties;
    }
100039
public function addFilterColumn($names = null)
    {
        $this->menu->addItem(['Clear Filters'], new \atk4\ui\jsReload($this->table->reload, ['atk_clear_filter' => 1]));
        $this->table->setFilterColumn($names);

        return $this;
    }
698993
public function define($name, $parameters = [], $parent = null, $children = [])
    {
        if (is_array($parent)) {
            $children = $parent;
            $parent = null;
        }
        if ($parent) {
            if (!array_has($this->items, $parent))
                throw new InvalidArgumentException("{$parent} does not exist");

            $name = "{$parent}.children.{$name}";

            if (empty($parameters['icon'])) $parameters['icon'] = 'fa-circle-o';
        } else {
            if (empty($parameters['icon'])) $parameters['icon'] = '';
        }
        if (empty($parameters['sort'])) $parameters['sort'] = 10;

        array_set($this->items, $name, $parameters);

        foreach ($children as $childName => $child) {
            $this->define($childName, $child, $name);
        }
    }
902548
public function exports(array $names)
    {
        $url = self::$base_url.'/get?'.http_build_query(['names' => $names]);

        return self::$curl->get($url);
    }
180308
public static function setNames(array $names)
    {
        if(static::$isInited)
        {
            throw new \RuntimeException('addName failed, MemoryTableManager was inited');
        }
        foreach($names as $key => $value)
        {
            if(is_numeric($key))
            {
                static::$tables[$value] = 0;
            }
            else
            {
                static::$tables[$key] = $value;
            }
        }
    }
1337664
protected function findOrCreateRolesByName($names)
    {
        if (empty($names)) {
            return [];
        }

        $existing = static::whereIn('name', $names)->get()->keyBy('name');

        return (new Collection($names))
                ->diff($existing->pluck('name'))
                ->map(function ($name) {
                    return static::create(compact('name'));
                })
                ->merge($existing);
    }
577540
public function names($names)
    {
        // only the post type name is passed
        if (is_string($names)) {
            $names = ['name' => $names];
        }

        // set the names array
        $this->names = $names;

        // create names for the PostType
        $this->createNames();

        return $this;
    }
1359481
protected function getIconUnicode($name)
    {
        $icons = Config::inst()->get(__CLASS__, 'icons');
        
        if (isset($icons[$name])) {
            
            return $icons[$name];
            
        }
    }
41778
public function setColumnNames(array $names)
    {
        if ($this->featureCount !== 0 && count($names) !== $this->featureCount) {
            throw new InvalidArgumentException(sprintf('Length of the given array should be equal to feature count %s', $this->featureCount));
        }

        $this->columnNames = $names;

        return $this;
    }
403137
private function buildJobs(array $names)
    {
        $jobs = $this->container->getParameter('jobs');
        foreach ($names as $name) {
            if (!array_key_exists($name, $jobs)) {
                throw new BldrException(
                    sprintf(
                        "Job `%s` does not exist. Found: %s",
                        $name,
                        implode(', ', array_keys($jobs))
                    )
                );
            }

            $jobInfo     = $jobs[$name];
            $description = isset($jobInfo['description']) ? $jobInfo['description'] : "";
            $job         = new JobDefinition($name, $description);

            foreach ($jobInfo['tasks'] as $taskInfo) {
                $task = new TaskDefinition($taskInfo['type']);
                $task->setContinueOnError(isset($taskInfo['continueOnError']) ? $taskInfo['continueOnError'] : false);
                unset($taskInfo['type'], $taskInfo['continueOnError']);
                $task->setParameters($taskInfo);
                $job->addTask($task);
            }

            $this->registry->addJob($job);
        }
    }