Get the path to the view file

@param $name
@return string
960943
protected function getViewPath($name)
    {
        $pieces = explode('/', $name);

        // dont plural if reserve word
        foreach ($pieces as $k => $value) {
            if (!in_array($value, config('generators.reserve_words'))) {
                $pieces[$k] = str_plural(snake_case($pieces[$k]));
            }
        }

        $name = implode('.', $pieces);

        //$name = implode('.', array_map('str_plural', explode('/', $name)));

        return strtolower(rtrim(ltrim($name, '.'), '.'));
    }
848372
protected function getPath($name)
    {
        $name = $this->getFileName();

        $withName = boolval($this->option('name'));

        $path = $this->settings['path'];
        if ($this->settingsDirectoryNamespace() === true) {
            $path .= $this->getArgumentPath($withName);
        }

        $path .= $name;

        return $path;
    }
561032
public function getViewPath(): string
    {
        if (is_file($this->tplDistPath)) {
            if ($this->disableTplCache) {
                $this->buildViewTemplate();
            }
        } else {
            $this->buildViewTemplate();
        }
        return $this->tplDistPath;
    }
386480
public function getConfFilePath($name)
    {
        ($this->apache_base_path != null) ? $apache_base_path = $this->getPath($this->apache_base_path) :
            $apache_base_path = $this->getPath("/etc/apache2/");

        $suffix = "";
        if ($this->apache_version === "24") {
            $suffix = '/conf-available/' . $name . '.conf';
        } else {
            $suffix = '/conf.d/' . $name . '.conf';
        }

        return $apache_base_path . $suffix;

    }
731836
public function find($name)
	{
		if (isset($this->views[$name])) return $this->views[$name];

		if (strpos($name, '::') !== false)
		{
			return $this->views[$name] = $this->findNamedPathView($name);
		}

		return $this->views[$name] = $this->findInPaths($name, $this->paths);
	}
1195120
public function generateView($name)
    {
        if (!$content = $this->getViewContent($name)) {
            return '';
        }

        $sectionSegments = $this->sectionSegments;

        if ($this->viewsDir) {
            array_unshift($sectionSegments, $this->viewsDir);
        }

        $path = base_path('resources/views/'.implode('/', $sectionSegments).'/'.$name.'.php');

        if (is_file($path)) {
            return '';
        }

        $this->createMissingDirs($path);

        return file_put_contents($path, $content) !== false ? $path : '';
    }
545892
protected function getPath($name)
    {
        $name = Str::replaceFirst($this->rootNamespace(), '', $name);

        return $this->plugin->app_path.'/'.str_replace('\\', '/', $name).'.php';
    }
88818
protected function getPath($name)
    {   
        $rootNamespace = $this->getLaravelRootNamespace();

        $name = str_replace_first($rootNamespace, '', $name);
        
        return $this->laravel['path'] . '/' . str_replace('\\', '/', $name) . '.php';
    }
576485
public function getPath($name)
    {
        $segments = explode('\\', $name);

        array_shift($segments);

        return app_path(implode('/', $segments)).'.php';
    }
56915
protected function getPath($file_name, $path='controller')
    {
        if($path == "controller")
        {
            return './app/Http/Controllers/' . $file_name . '.php';
        }
        elseif($path == "request")
        {
            return './app/Http/Requests/'.$file_name.'.php';
        }
        elseif($path == "observer")
        {
            return './app/Observers/'.$file_name.'.php';
        }
        elseif($path == "policy")
        {
            return './app/Policies/'.$file_name.'.php';
        }
        elseif($path == "factory")
        {
            return './database/factories/'.$file_name.'Factory.php';
        }
        elseif($path == "model")
        {
            return './app/Models/'.$file_name.'.php';
        }
        elseif($path == "model-trait")
        {
            return './app/Models/Traits/'.$file_name.'Operation.php';
        }
        elseif($path == "seed")
        {
            return './database/seeds/'.$file_name.'.php';
        }
        elseif($path == "view-index")
        {
            return './resources/views/'.$file_name.'/index.blade.php';
        }
        elseif($path == "view-edit")
        {
            return './resources/views/'.$file_name.'/edit.blade.php';
        }
        elseif($path == "view-show")
        {
            return './resources/views/'.$file_name.'/show.blade.php';
        }
        elseif($path == "view-create")
        {
            return './resources/views/'.$file_name.'/create.blade.php';
        }
        elseif($path == "localization"){
            return './resources/lang/'.$file_name.'.php';
        }
        elseif($path == "route"){
            return './routes/web.php';
        }
        elseif($path == "route_old"){
            return './app/Http/routes.php';
        }
    }
123605
public function getPath($name)
    {
        if ($this->callerNotSelfOrPathsProxy()) {
            Deprecated::method(3.3, 'Use Bolt\Filesystem (recommended) or PathResolver::resolve instead.');
        }

        return $this->getPathObject($name)->string();
    }
734842
public function getView($name)
    {
        if (!isset(self::$_controllers['view.'.$name])) {
            $view = $this->getController($name)->setView($name)->getView();
            self::$_controllers['view.'.$name] = $view;
        }

        return self::$_controllers['view.'.$name];
    }
452483
public function getView(string $name): SplFileInfo
    {
        $viewFactory = app(Factory::class);

        $pattern = str_replace('.', DIRECTORY_SEPARATOR, $name);
        $path = $viewFactory->getFinder()->find($name);

        $pos = strpos($path, $pattern);

        $directory = substr($path, 0, $pos);
        $filename = substr($path, $pos);

        return $this->createSplFileInfoInstance($directory, $filename);
    }
1310918
protected function getFileName($name) {
		
		// defaults
		$fileName = "";
		$dirSep   = DIRECTORY_SEPARATOR;
		
		// test to see what kind of path was supplied
		$posDash  = strpos($name,"-");
		$posSlash = strpos($name,$dirSep);
		
		if (($posSlash === false) && ($posDash !== false)) {
			$fileName = $this->baseDir.$dirSep.$this->patternUtil->getPatternFileName($name);
		} else {
			$fileName = $this->baseDir.$dirSep.$name;
		}
		
		if (substr($fileName, 0 - strlen($this->extension)) !== $this->extension) {
			$fileName .= $this->extension;
		}
		
		return $fileName;
		
	}
337100
protected function getPath($name) {
		$path = [];
		$matches = null;
		preg_match('/^([^\[]+)/', $name, $matches);
		$path[] = $matches[0];
		preg_match_all('/\[([^\]]*)\]/', $name, $matches);
		$path = array_merge($path, $matches[1]);

		return $path;
	}
678963
protected function findNamedPathView($name)
    {
        list($namespace, $view) = $this->getNamespaceSegments($name);

        $paths = $this->hints[$namespace];

        if (Str::endsWith($path = head($this->paths), DS .'Overrides')) {
            $path = $path .DS .'Packages' .DS .$namespace;

            if (! in_array($path, $paths) && $this->files->isDirectory($path)) {
                array_unshift($paths, $path);
            }
        }

        return $this->findInPaths($view, $paths);
    }
1047905
public function path($name = null)
    {
        if ($name !== null) {
            return $this->path().'/'.$name;
        } else {
            return $this->app->basePath().'/'.$this->app['config']->get('addon.path', 'addons');
        }
    }