private function addPath($path)
    {
        $paths = $this->analyzer->analyze($path);

        $newPaths = [];

        foreach ($paths as $filePath) {
            $newPathInformation             = $filePath;
            $newPathInformation['original'] = $filePath['path'];

            if ($this->getCollectorValue($filePath['path']) !== null) {
                // If the value from the collector is not null, we need to process the path value
                // using the template renderer.
                $newPathInformation['path'] = $this->templateRenderer
                    ->renderString($this->getCollectorValue($filePath['path']));
            } else {
                // If the value IS null, we need to process the path value using the path parser.
                $newPathInformation['path'] = $this->parser->processPath($filePath['path']);
            }

            $newPaths[]    = $newPathInformation;
            $this->paths[] = $newPathInformation;

            // Add the new file path association to the collector.
            $this->addRawToCollector($filePath['path'], $newPathInformation['path']);
        }

        $this->templateRenderer->addPath($path);

        return $newPaths;
    }