Embedded​File​Provider Embedded​File​Provider Class

Definition

Looks up files using embedded resources in the specified assembly. This file provider is case sensitive.
public class EmbeddedFileProvider : IFileProviderPublic Class EmbeddedFileProvider
    Inherits IFileProvider
Inheritance
System.ObjectSystem.Object
EmbeddedFileProviderEmbeddedFileProvider

Constructors

EmbeddedFileProvider(Assembly) EmbeddedFileProvider(Assembly)

Initializes a new instance of the EmbeddedFileProvider class using the specified assembly and empty base namespace.
public EmbeddedFileProvider(Assembly assembly)Public Sub New(assembly As Assembly)
Parameters
assembly
Assembly Assembly

EmbeddedFileProvider(Assembly, String) EmbeddedFileProvider(Assembly, String)

Initializes a new instance of the EmbeddedFileProvider class using the specified assembly and base namespace.
public EmbeddedFileProvider(Assembly assembly, string baseNamespace)Public Sub New(assembly As Assembly, baseNamespace As String)
Parameters
assembly
Assembly Assembly
The assembly that contains the embedded resources.
baseNamespace
System.String System.String
The base namespace that contains the embedded resources.

Methods

GetDirectoryContents(String) GetDirectoryContents(String)

Enumerate a directory at the given path, if any. This file provider uses a flat directory structure. Everything under the base namespace is considered to be one directory.
public IDirectoryContents GetDirectoryContents(string subpath)Public Function GetDirectoryContents(subpath As String) As IDirectoryContents
Parameters
subpath
System.String System.String
The path that identifies the directory
Returns
IDirectoryContents IDirectoryContents
Contents of the directory. Caller must check Exists property.

GetFileInfo(String) GetFileInfo(String)

Locates a file at the given path.
public IFileInfo GetFileInfo(string subpath)Public Function GetFileInfo(subpath As String) As IFileInfo
Parameters
subpath
System.String System.String
The path that identifies the file.
Returns
IFileInfo IFileInfo
The file information. Caller must check Exists property.

Watch(String) Watch(String)

public IChangeToken Watch(string pattern)Public Function Watch(pattern As String) As IChangeToken
Parameters
pattern
System.String System.String
Returns
IChangeToken IChangeToken