Skip to content

Commit 637124b

Browse files
Enhance FileViewFinder doc-blocks (#55183)
1 parent 46ac782 commit 637124b

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

src/Illuminate/View/FileViewFinder.php

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,21 @@ class FileViewFinder implements ViewFinderInterface
1717
/**
1818
* The array of active view paths.
1919
*
20-
* @var array
20+
* @var string[]
2121
*/
2222
protected $paths;
2323

2424
/**
2525
* The array of views that have been located.
2626
*
27-
* @var array
27+
* @var array<string, string>
2828
*/
2929
protected $views = [];
3030

3131
/**
3232
* The namespace to file path hints.
3333
*
34-
* @var array
34+
* @var array<string, array>
3535
*/
3636
protected $hints = [];
3737

@@ -46,8 +46,8 @@ class FileViewFinder implements ViewFinderInterface
4646
* Create a new file view loader instance.
4747
*
4848
* @param \Illuminate\Filesystem\Filesystem $files
49-
* @param array $paths
50-
* @param array|null $extensions
49+
* @param string[] $paths
50+
* @param string[]|null $extensions
5151
*/
5252
public function __construct(Filesystem $files, array $paths, ?array $extensions = null)
5353
{
@@ -95,7 +95,7 @@ protected function findNamespacedView($name)
9595
* Get the segments of a template with a named path.
9696
*
9797
* @param string $name
98-
* @return array
98+
* @return string[]
9999
*
100100
* @throws \InvalidArgumentException
101101
*/
@@ -118,7 +118,7 @@ protected function parseNamespaceSegments($name)
118118
* Find the given view in the list of paths.
119119
*
120120
* @param string $name
121-
* @param array $paths
121+
* @param string|string[] $paths
122122
* @return string
123123
*
124124
* @throws \InvalidArgumentException
@@ -142,7 +142,7 @@ protected function findInPaths($name, $paths)
142142
* Get an array of possible view files.
143143
*
144144
* @param string $name
145-
* @return array
145+
* @return string[]
146146
*/
147147
protected function getPossibleViewFiles($name)
148148
{
@@ -186,7 +186,7 @@ protected function resolvePath($path)
186186
* Add a namespace hint to the finder.
187187
*
188188
* @param string $namespace
189-
* @param string|array $hints
189+
* @param string|string[] $hints
190190
* @return void
191191
*/
192192
public function addNamespace($namespace, $hints)
@@ -204,7 +204,7 @@ public function addNamespace($namespace, $hints)
204204
* Prepend a namespace hint to the finder.
205205
*
206206
* @param string $namespace
207-
* @param string|array $hints
207+
* @param string|string[] $hints
208208
* @return void
209209
*/
210210
public function prependNamespace($namespace, $hints)
@@ -222,7 +222,7 @@ public function prependNamespace($namespace, $hints)
222222
* Replace the namespace hints for the given namespace.
223223
*
224224
* @param string $namespace
225-
* @param string|array $hints
225+
* @param string|string[] $hints
226226
* @return void
227227
*/
228228
public function replaceNamespace($namespace, $hints)
@@ -279,7 +279,7 @@ public function getFilesystem()
279279
/**
280280
* Set the active view paths.
281281
*
282-
* @param array $paths
282+
* @param string[] $paths
283283
* @return $this
284284
*/
285285
public function setPaths($paths)
@@ -292,7 +292,7 @@ public function setPaths($paths)
292292
/**
293293
* Get the active view paths.
294294
*
295-
* @return array
295+
* @return string[]
296296
*/
297297
public function getPaths()
298298
{
@@ -302,7 +302,7 @@ public function getPaths()
302302
/**
303303
* Get the views that have been located.
304304
*
305-
* @return array
305+
* @return array<string, string>
306306
*/
307307
public function getViews()
308308
{
@@ -312,7 +312,7 @@ public function getViews()
312312
/**
313313
* Get the namespace to file path hints.
314314
*
315-
* @return array
315+
* @return array<string, array>
316316
*/
317317
public function getHints()
318318
{
@@ -322,7 +322,7 @@ public function getHints()
322322
/**
323323
* Get registered extensions.
324324
*
325-
* @return array
325+
* @return string[]
326326
*/
327327
public function getExtensions()
328328
{

0 commit comments

Comments
 (0)