File tree Expand file tree Collapse file tree 2 files changed +7
-31
lines changed Expand file tree Collapse file tree 2 files changed +7
-31
lines changed Original file line number Diff line number Diff line change @@ -240,35 +240,9 @@ public function getBundle($name, $first = true)
240
240
}
241
241
242
242
/**
243
- * Returns the file path for a given resource.
243
+ * {@inheritDoc}
244
244
*
245
- * A Resource can be a file or a directory.
246
- *
247
- * The resource name must follow the following pattern:
248
- *
249
- * @<BundleName>/path/to/a/file.something
250
- *
251
- * where BundleName is the name of the bundle
252
- * and the remaining part is the relative path in the bundle.
253
- *
254
- * If $dir is passed, and the first segment of the path is "Resources",
255
- * this method will look for a file named:
256
- *
257
- * $dir/<BundleName>/path/without/Resources
258
- *
259
- * before looking in the bundle resource folder.
260
- *
261
- * @param string $name A resource name to locate
262
- * @param string $dir A directory where to look for the resource first
263
- * @param bool $first Whether to return the first path or paths for all matching bundles
264
- *
265
- * @return string|array The absolute path of the resource or an array if $first is false
266
- *
267
- * @throws \InvalidArgumentException if the file cannot be found or the name is not valid
268
- * @throws \RuntimeException if the name contains invalid/unsafe
269
- * @throws \RuntimeException if a custom resource is hidden by a resource in a derived bundle
270
- *
271
- * @api
245
+ * @throws \RuntimeException if a custom resource is hidden by a resource in a derived bundle
272
246
*/
273
247
public function locateResource ($ name , $ dir = null , $ first = true )
274
248
{
Original file line number Diff line number Diff line change @@ -101,15 +101,17 @@ public function getBundle($name, $first = true);
101
101
*
102
102
* The resource name must follow the following pattern:
103
103
*
104
- * @BundleName/path/to/a/file.something
104
+ * " @BundleName/path/to/a/file.something"
105
105
*
106
106
* where BundleName is the name of the bundle
107
107
* and the remaining part is the relative path in the bundle.
108
108
*
109
- * If $dir is passed, and the first segment of the path is Resources,
109
+ * If $dir is passed, and the first segment of the path is " Resources" ,
110
110
* this method will look for a file named:
111
111
*
112
- * $dir/BundleName/path/without/Resources
112
+ * $dir/<BundleName>/path/without/Resources
113
+ *
114
+ * before looking in the bundle resource folder.
113
115
*
114
116
* @param string $name A resource name to locate
115
117
* @param string $dir A directory where to look for the resource first
You can’t perform that action at this time.
0 commit comments