Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

interface Microsoft.​Extensions.​FileProviders.​IFileProvider

Assembly: Microsoft.Extensions.FileProviders.Abstractions

A read-only file provider abstraction.

Methods

GetDirectoryContents​(string subpath)
Enumerates a directory at the given path, if any.
Returns The contents of the directory.
subpath The relative path that identifies the directory.
GetFileInfo​(string subpath)
Locates a file at the given path.
Returns The file information. Caller must check Exists property.
subpath The relative path that identifies the file.
Watch​(string filter)
Creates an <see cref="T:Microsoft.Extensions.Primitives.IChangeToken" /> for the specified <paramref name="filter" /> .
Returns An <see cref="T:Microsoft.Extensions.Primitives.IChangeToken" /> that is notified when a file matching <paramref name="filter" /> is added, modified, or deleted.
filter A filter string used to determine what files or folders to monitor. Examples: **/*.cs, *.*, subFolder/**/*.cshtml.