AssetManager\Resolver\PrioritizedPathsResolver::addPaths PHP Method

addPaths() public method

Add many paths to the stack at once
public addPaths ( array | Traversabl\Traversable $paths ) : self
$paths array | Traversabl\Traversable
return self
    public function addPaths($paths)
    {
        foreach ($paths as $path) {
            $this->addPath($path);
        }
    }

Usage Example

 /**
  * {@inheritDoc}
  *
  * @return PrioritizedPathsResolver
  */
 public function createService(ServiceLocatorInterface $serviceLocator)
 {
     $config = $serviceLocator->get('config');
     $prioritizedPathsResolver = new PrioritizedPathsResolver();
     $paths = isset($config['asset_manager']['resolver_configs']['prioritized_paths']) ? $config['asset_manager']['resolver_configs']['prioritized_paths'] : array();
     $prioritizedPathsResolver->addPaths($paths);
     return $prioritizedPathsResolver;
 }
All Usage Examples Of AssetManager\Resolver\PrioritizedPathsResolver::addPaths