Method GetFileInfoOrThrow
GetFileInfoOrThrow(IFileProvider, string)
Retrieves the file information from the specified file provider or throws an exception if the file is not found.
Declaration
public static IFileInfo GetFileInfoOrThrow(this IFileProvider fileProvider, string path)
Parameters
| Type | Name | Description |
|---|---|---|
| IFileProvider | fileProvider | The file provider to query. |
| string | path | The path to the file within the file provider. |
Returns
| Type | Description |
|---|---|
| IFileInfo | The file information of the requested file. |
Exceptions
| Type | Condition |
|---|---|
| FileNotFoundException | Thrown when the specified file cannot be found. |