Bind all of the application paths in the container.

@param array $otherPaths

@return void
172436
protected function bindPathsInContainer(array $otherPaths)
    {
        $defaultPaths = [
            'base'    => $this->basePath,
            'env'     => $this->basePath,
            'app'     => $this->basePath . DIRECTORY_SEPARATOR . 'app',
            'config'  => $this->basePath . DIRECTORY_SEPARATOR . 'config',
            'storage' => $this->basePath . DIRECTORY_SEPARATOR . 'storage',
            'logs'    => $this->basePath . DIRECTORY_SEPARATOR . 'storage' . DIRECTORY_SEPARATOR . 'logs',
        ];

        $paths = array_merge($defaultPaths, $otherPaths);
        $this->instance('path', rtrim(array_pull($paths, 'app'), '\/'));

        foreach ($paths as $key => $path) {
            $this->instance("path.{$key}", rtrim($path, '\/'));
        }
    }
895218
public function connect(\OtherCode\FController\Components\Services $services, \OtherCode\FController\Components\Registry $storage, \OtherCode\FController\Components\Messages $messages)
    {
        if (!isset($this->services)) {
            $this->services = $services;
        }

        if (!isset($this->storage)) {
            $this->storage = $storage;
        }

        if (!isset($this->messages)) {
            $this->messages = $messages;
        }
    }
498336
public function setPath(string $path)
    {
        $this->path = $path;
        
        // update path to templates and preload list of templates.
        $this->contentPath = $this->path . DIR_CONTENT_BASENAME;
        $this->templatesPath = $this->contentPath . DIR_TEMPLATES_BASENAME;
        
        $this->templates = File::listFilesRecursively($this->templatesPath, false, EXT_PART, EXT_PAGE);
    }
306256
public function setPaths($paths)
    {
        if (!is_array($paths) && !$paths instanceof Traversable) {
            throw new Exception\InvalidArgumentException(sprintf(
                'Invalid argument provided for $paths, expecting either an array or Traversable object, "%s" given',
                is_object($paths) ? get_class($paths) : gettype($paths)
            ));
        }

        $this->clearPaths();
        $this->addPaths($paths);
    }
953140
public function addFilesToRegistry($filePaths)
    {
        collect((array) $filePaths)->each(function ($filePath) {
            if (file_exists($filePath)) {
                AnnotationRegistry::registerFile($filePath);
            }
        });

        return $this;
    }
530670
public function addExcludePaths(array $paths) : void
    {
        $this->excludePaths = array_unique(array_merge($this->excludePaths, $paths));
    }
417665
public function bind()
    {
        parent::bind();

        // In environments that are not a skeleton app we use an Application
        // instance to hold the paths.
        if (!$this->app->bound(Application::class)) {
            $this->app->instance(Application::class, $this->createPlaceholderApp());
        }

        $this->assignPathsToApp($this->app->make(Application::class));

        $this->app->resolving(PathFinder::class, function ($paths) {
            $this->assignBaseAppPaths($paths);
        });

        $this->app->resolving(StringConverterChain::class, function ($chain) {
            $this->addStringConverters($chain);
        });

        $this->app->resolving(TextFormatter::class, function ($formatter, $app) {
            $formatter->setLocalizer($app('Ems\Contracts\Core\Localizer'));
        });

        $this->app->bind('ems::locale-config', function ($ioc) {

            /** @var Application $app */
            $app = $ioc(Application::class);
            $storage = new NestedFileStorage();
            $storage->setUrl($app->path('ems-resources')->append('lang'));
            $storage->setNestingLevel(1);

            $provider = new ArrayProvider();
            $provider->add($storage);

            return $provider;

        }, true);

        $this->app->bind(Matcher::class, function ($ioc) {
            return new Matcher($ioc(CheckerContract::class), $ioc(ExtractorContract::class));
        }, true);

        $this->app->resolving(Formatter::class, function (Formatter $formatter, $app) {
            $formatter->setFormats($app('ems::locale-config'));
        });

        $this->app->resolving(TextParserQueue::class, function ($queue, $app) {
            $queue->add($app(VariablesTextParser::class));
        });

        $this->app->resolving(AnythingProvider::class, function ($provider, $app) {
            $provider->createObjectsWith($app);
        });

        $this->app->resolving(SupportsCustomFactory::class, function ($object) {
            $object->createObjectsBy($this->app);
        });

        $this->app->resolving(HasInjectMethods::class, function (HasInjectMethods $object) {
            $this->autoInjectDependendies($object);
        });

        $this->app->resolving(ConnectionPoolContract::class, function (ConnectionPoolContract $pool) {
            /** @return void */
            $pool->extend('php', function (UrlContract $url) {
                if ($url->scheme == 'php' || $url->scheme == 'file') {
                    return new FilesystemConnection($url);
                }
                return null;
            });
        });
    }
982085
public static function registerPath($path)
    {
        $path = realpath($path);
        if (!in_array($path, self::$paths)) {
            self::$paths[] = $path;
            self::$cache   = null;
        }
    }
603016
public function setPaths($paths)
    {
        $paths = (array)$paths;
        //Append framework's view path
        $paths[] = realpath(__DIR__ . '/../../views');

        $this->paths = $paths;
        return $this;
    }
11691
public function bindPaths(array $paths)
    {
        foreach($paths as $key => $val)
        {
            $paths[$key] = realpath($val);
        }

        return $paths;
    }
716099
public function setPathParameters(array $pathParameters)
    {
        foreach ($pathParameters as $name => $value) {
            $this->setPathParameter($name, $value);
        }
    }
957686
protected function setUpPaths(Application $app)
    {
        $pathRoot = $app->path;

        $pathRoot->register('root', $pathRoot); // recursive reference.

        $pathRoot->register('public', isset($params['path.public']) ? $params['path.public'] : $pathRoot->to('public'), true);

        $pathApp = $pathRoot->register('app', isset($params['path.app']) ? $params['path.app'] : $pathRoot->to('app'), true);

        $pathRoot->register('src', isset($params['path.src']) ? $params['path.src'] : $pathApp->to('src'), true);

        $pathRoot->register('routes', isset($params['path.routes']) ? $params['path.routes'] : $pathApp->to('routes'), true);

        $pathRoot->register('views', isset($params['path.views']) ? $params['path.views'] : $pathApp->to('views'), true);
    }
473527
function setAppsFolderPaths() {
    if (this.applicationType) return;
    this.appsFolderPaths = [];
    for (let i = 0; i < this.appsFolders.length; i++) {
        const path = this.destinationPath(this.directoryPath + this.appsFolders[i]);
        this.appsFolderPaths.push(path);
    }
}
364313
public function setPaths($paths, $namespace = self::DEFAULT_NAMESPACE)
    {
        if (! is_array($paths)) {
            $paths = [$paths];
        }
        $this->paths[$namespace] = [];
        foreach ($paths as $path) {
            $this->addPath($path, $namespace);
        }
    }
500941
public void setPaths(@Nonnull List<Path> paths) {
        ArgumentUtils.requireNonNull("paths", paths);
        this.paths = paths;
    }
871884
public function load(string $path, string ...$paths): void
    {
        array_unshift($paths, $path);
        foreach ($paths as $path) {
            if (!is_readable($path) || is_dir($path) || ($contents = parse_ini_file($path, false)) === false) {
                throw new InvalidArgumentException("{$path} is not a readable file.");
            }
            $this->populate($contents);
        }
    }
18076
protected function bindPathsInContainer()
    {
        // Core
        $this->instance('path', $this->path());
        // Base
        $this->instance('path.base', $this->basePath());
        // Content
        $this->instance('path.content', $this->contentPath());
        // Mu-plugins
        $this->instance('path.muplugins', $this->mupluginsPath());
        // Plugins
        $this->instance('path.plugins', $this->pluginsPath());
        // Themes
        $this->instance('path.themes', $this->themesPath());
        // Application
        $this->instance('path.application', $this->applicationPath());
        // Resources
        $this->instance('path.resources', $this->resourcePath());
        // Languages
        $this->instance('path.lang', $this->langPath());
        // Web root
        $this->instance('path.web', $this->webPath());
        // Root
        $this->instance('path.root', $this->rootPath());
        // Config
        $this->instance('path.config', $this->configPath());
        // Public
        $this->instance('path.public', $this->webPath());
        // Storage
        $this->instance('path.storage', $this->storagePath());
        // Database
        $this->instance('path.database', $this->databasePath());
        // Bootstrap
        $this->instance('path.bootstrap', $this->bootstrapPath());
        // WordPress
        $this->instance('path.wp', $this->wordpressPath());
    }